cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

Print editor view font size

ashah
1-Newbie

Print editor view font size

Hi,

I have a query regarding printing in Arbortext Editor 5.3.

When I reduce text size to e.g. 84% and print, the tags are reduced in size but the text stays at 100%.

Is there any way to reduce the text size when printing?

Thanks.

5 REPLIES 5
bibach
1-Newbie
(To:ashah)

When you say "reduce text size", I'm guessing you mean you're using the menu
entries under View, Font Size. These only affect the appearance of text in
the editor, not in composed output. Generally, the style of printed output
must be controlled through Styler, or through a separately-developed FOSI,
XSL-FO, etc.

There is more than one way to invoke printing. Which method are you using?

-Brandon 🙂

Brandon Ibach
Developer, Single-Sourcing Solutions, Inc.


naglists
1-Newbie
(To:ashah)

I believe Ali is trying to print the Editor view ... not any sort of
composed print. We do this in one of our applications in order to be able to
see change tracking.

Try issuing the following command from the command line:
set editfontpercent=150

This worked for me. (Experiment with different values, of course, to find
the optimum size for your application. I don't know what the upper limit is,
but the lower is reported by help 9107 to be 40.)

I was surprised that increasing the font size via View => Font Size didn't
seem to affect Print Edit View output. Also, I tried changing the setting
from Tools => Preferences => Advanced => editfontpercent but saw some
strange behavior (docmap font size changed, but not edit window font size).

Had to set it from the command line to get it to take.


On Tue, Jun 30, 2009 at 9:55 AM, Brandon Ibach <
brandon.ibach@single-sourcing.com> wrote:

> When you say "reduce text size", I'm guessing you mean you're using the
> menu entries under View, Font Size. These only affect the appearance of
> text in the editor, not in composed output. Generally, the style of printed
> output must be controlled through Styler, or through a separately-developed
> FOSI, XSL-FO, etc.
>
> There is more than one way to invoke printing. Which method are you using?
>
> -Brandon 🙂
>
> Brandon Ibach
> Developer, Single-Sourcing Solutions, Inc.
>
>
>
jsulak
1-Newbie
(To:ashah)

Here's a function that we use to reduce the font size when printing the Editor view (we set our zoom to 100%, but you could adjust it to 84%). You can use the menu_change command to map this function to File > Print:

function modified_print()
{
#capture current selection
local o1, p1, o2, p2
o1 = selection_start(p1)
o2 = selection_end(p2)

# expand all collapsed elements
detail -all -full

# get current spelling, zoom, tagview, and docmapview settings
$fontpercent = option("editfontpercent")
$spelling = option("spellinteractive")
$docmap = option("docmapview")
$tagview = option("tagdisplay")
$tagprompt = option("showemptyelement")

# set print options
set editfontpercent=100
set spellinteractive=off
set docmapview=off
set tagdisplay=none
set showemptyelement=off

# restore selection
goto_oid(o1, p1)
mark begin
goto_oid(o2, p2)
mark end

#Open Print window
FilePrintEditor

# put settings back how they were before printing
set editfontpercent = $fontpercent
set spellinteractive = $spelling
set docmapview = $docmap
set tagdisplay = $tagview
set showemptyelement = $tagprompt
}


Hope this helps,

-James





bibach
1-Newbie
(To:ashah)

Hey, Paul...

I suspected a printout of editor view was the intent, thus my question about
the "method". You just skipped a step. 🙂

Interestingly, the Font Size menu items only change the "fontpercent" option
and, if you're in an edit window, the "tagfontpercent" option, but not
"editfontpercent". Nothing a few lines of ACL couldn't fix, of course.
<insert standard=" disclaimer=" about=" lightly-tested=" code=" here=">

function my_zoom_font(increase=1)
{
if (window_class() == 'edit') {
local ez = _zoom_font_pct(option("editfontpercent"), increase);
window_set(0, "editfontpercent", ez);
}
zoom_font(increase);
}
alias ZoomDown { my_zoom_font(0) }
alias ZoomUp { my_zoom_font(1) }

-Brandon 🙂

ashah
1-Newbie
(To:ashah)

Thank you to all of you for such a quick reply. I started with the simplest suggestion and it worked!

Inserting set editfontpercent=84 from the command line and then printing the text gave me a printout with reduced text size and reduced tag sizes. Not sure why reducing the text size using the small "A" on the menu did not work for printing.

This will go a small way to saving the rainforests with more text on the printed page 🙂

Announcements