Recent posts

#1
Text and Typography / Re: Right-aligned tabs
Last post by a.l.e - May 29, 2023, 04:52:58 PM
i have created a ticket in the bug tracker for this:

https://bugs.scribus.net/view.php?id=16949
#2
Text and Typography / Re: Right-aligned tabs
Last post by PatJr - May 29, 2023, 04:16:10 PM
don't think you can align text to the frame like that
when I tried it the frame had to be just slightly bigger then the what the tab stop was set to, about 1/2 mm or the paragraph would wrap to the next line


#3
Beginner Talk / Re: Word Count function
Last post by qwazix - May 29, 2023, 03:45:40 PM
Updated to ignore leading and trailing whitespaces

#!/usr/bin/env python
# File: count_words.py - Counts all words in a document
# also lists image files with pathnames
# 2006.03.04 Gregory Pittman
# 2008.02.28 Petr Vanek - fileDialog replaces valueDialog
# 2023.05.29 Michalis Demetriou - modify in order to just count all words
# this version 2023.05.29
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.

import scribus
import re

def countWords():
    page = 1
    pagenum = scribus.pageCount()
    T = []
    content = []
    while (page <= pagenum):
        scribus.gotoPage(page)
        d = scribus.getPageItems()
        for item in d:
            if (item[1] == 4):
                contents = scribus.getAllText(item[0])
                if (contents in content):
                    contents = ''
                T.append(contents)
                content.append(contents)
        page += 1
    text = " ".join(T)
    text = re.sub('^ ','',re.sub(' $','',re.sub(' +', ' ', text)))
    count = len(text.split(" "))
    print(count)
    endmessage =  str(count) + ' words'
    scribus.messageBox("Finished", endmessage,scribus.ICON_INFORMATION, scribus.BUTTON_OK)


if scribus.haveDoc():
    try:
        countWords()
    except (Exception, e):
        print(e)

else:
    scribus.messageBox('Export Error', 'You need a Document open, and a frame selected.', \
                       icon=0, button1=1)

#4
Beginner Talk / Re: Word Count function
Last post by qwazix - May 29, 2023, 01:16:14 PM
I modified the "export all text" script to count all words in a document (and work with python3)

#!/usr/bin/env python
# File: count_words.py - Counts all words in a document
# also lists image files with pathnames
# 2006.03.04 Gregory Pittman
# 2008.02.28 Petr Vanek - fileDialog replaces valueDialog
# 2023.05.29 Michalis Demetriou - modify in order to just count all words
# this version 2023.05.29
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.

import scribus
import re

def countWords():
    page = 1
    pagenum = scribus.pageCount()
    T = []
    content = []
    while (page <= pagenum):
        scribus.gotoPage(page)
        d = scribus.getPageItems()
        for item in d:
            if (item[1] == 4):
                contents = scribus.getAllText(item[0])
                if (contents in content):
                    contents = ''
                T.append(contents)
                content.append(contents)
        page += 1
#        T.append('')
    text = " ".join(T)
    text = re.sub(' +', ' ', text)
    count = len(text.split(" "))
    print(count)
    endmessage =  str(count) + ' words'
    scribus.messageBox("Finished", endmessage,scribus.ICON_INFORMATION, scribus.BUTTON_OK)


if scribus.haveDoc():
    try:
        countWords()
    except (Exception, e):
        print(e)

else:
    scribus.messageBox('Export Error', 'You need a Document open, and a frame selected.', \
                       icon=0, button1=1)

#5
Text and Typography / Right-aligned tabs
Last post by Southern-X-87 - May 29, 2023, 04:09:25 AM
Hi all. I am new to Scribus, but reasonably familiar with InDesign and QuarkXPress. Using Scribus 1.5.8 on macOS Ventura 13.0.1.

I am having trouble with using a right-aligned tab stop in Scribus. The context is a CV/résumé where I'd like the position and company worked on the left, and the dates worked on the right. The text box in question is 150mm wide. This is the *effect* I'd like, mocked up using text boxes:

1-Effect.png

I can easily do this in InDesign using a right-aligned tab stop (set at 150mm for a 150mm-wide text box):

2-InD-example.JPG

I can't work out how to do the same in Scribus. I set up the text like this:

3-Scribus-tab.png

Then set the tab stop in paragraph styles like this:

4-Scribus-tab.png

And this is the result:

5-Scribus-tab.png

I can reduce the position of the tab stop, e.g. to 140mm, but can't work out how to achieve the effect I'd like - a date aligned to the right edge of the text box.

Any advice gratefully received.
#6
General Discussion / Re: Donate to Scribus
Last post by MrB - May 28, 2023, 02:02:08 PM
The amount of money I have spent on persona lhardware that has almost 100% gone to supporting Scribus over the years is huge. We get donations for website etc hosting but giving money to that entity would help support server maintenance. Sure, a single euro won't go far, but it would add up over time.
#7
PDF Generation / Re: formatting PDF fields not ...
Last post by Nermander - May 28, 2023, 11:23:42 AM
Quote from: garydale on May 24, 2023, 05:56:37 PMI don't think so. The Adobe site suggests that a font can be any that is available "on your computer". The font chosen is embedded in the PDF file so any character should be able to be input.

Maybe an embedded font is considered available "on your computer".

And in any case I don't think it is Scribus that decides what fonts are available for a form, it is most likely the PDF viewer.
#8
General Discussion / Re: Donate to Scribus
Last post by Nermander - May 28, 2023, 11:20:20 AM
What would you expect the donation to do?

As far as I understand there are currently just a few developers working on Scribus in their free time. That means it's not really money that is missing, it is time.

As long as you do not donate enough for them to leave their jobs and work full time on Scribus, I doubt a donation will do a lot to change this :)

In the past there has been specific development projects that could be sponsored (there have been several Google Summer of Code projects as far as I remember).
#9
Beginner Talk / Re: where to put .icc file on ...
Last post by drking - May 27, 2023, 11:02:44 AM
Thank you. My worry about following online instructions for adding profiles to Windows has been that I'm adding a profile for Scribus, not for Windows which might start adjusting my monitor colour profiles for all I know. It turns out you can also right-click the icc file and Windows will 'install' it, whatever that means.

What I've actually done is to simply copy the .icc file into
C:/Windows/system32/spool/drivers/color

and Scribus has found it. I guess Win10 might offer it as an option if I ever try to adjust my monitor colours, but I'm hoping that otherwise it is harmless.

Thanks for your help
#10
Beginner Talk / Re: where to put .icc file on ...
Last post by AdmFubar - May 26, 2023, 11:20:35 PM
On Windows Vista or 7, go to the Windows Control panel > Color management > All Profiles > Add

This  should be the same on win 10..

check here and see if this resolves the issue
https://www.howtogeek.com/318723/how-to-find-and-install-a-color-profile-on-windows-for-a-more-accurate-monitor/