Hard Return Suppression

210 views
Skip to first unread message

Mark

unread,
Oct 9, 2008, 12:03:33 PM10/9/08
to XMPie Interest Group
In the 4.0.3 version of uCreate I have an address block (name,
address1, address2, city-state-zip, country) that I want to enable
vertical centering within the text object. This particular text object
has specified line leading values - no automatic leading.

How do I cause this to happen? It appears the records with the country
field being empty still generate the hard return for the line and
therefore defeat the centering of a address. This seems pretty basic
so I must be doing something wrong.

-Mark

George Marsh

unread,
Oct 9, 2008, 12:27:39 PM10/9/08
to xmpie...@googlegroups.com
> How do I cause this to happen? It appears the records with the country
> field being empty still generate the hard return for the line and
> therefore defeat the centering of a address. This seems pretty basic
> so I must be doing something wrong.

Mark:

Right click on the text box and select Dynamic Story Properties >
Suppress trailing spaces on empty content

Or, program your new lines at the end of the object and test if it is
blank first

Hope this helps

George

Mark

unread,
Oct 9, 2008, 2:17:11 PM10/9/08
to XMPie Interest Group
Thanks for the right click pointer that mostly works. However, in my
example the City-State-Zip line has a value and therefore generates a
return but the country is blank. So the vertical space generator has
in one extra line. But my guess is there is no easy way around that.

Also I did not understand your last point

> Or, program your new lines at the end of the object and test if it is
> blank first

Are you saying to use an expression in the logic component that
generates a return as needed (in the InDesign document all the ADORs
would be on one line and expanded to multiple line by the evaluation
of the ADOR)?

-Mark

George Marsh

unread,
Oct 9, 2008, 3:28:12 PM10/9/08
to xmpie...@googlegroups.com
> Thanks for the right click pointer that mostly works. However, in my
> example the City-State-Zip line has a value and therefore generates a
> return but the country is blank. So the vertical space generator has
> in one extra line. But my guess is there is no easy way around that.

I'm not convinced the country is totally blank - you could apply a
trim to the field and then test it is empty before printing the value.
Assume you are using uDirect in InDesign rather than uPlan? Give me a
shout if you need some guidance on how to do this.

> Also I did not understand your last point
>
>> Or, program your new lines at the end of the object and test if it is
>> blank first
>
> Are you saying to use an expression in the logic component that
> generates a return as needed (in the InDesign document all the ADORs
> would be on one line and expanded to multiple line by the evaluation
> of the ADOR)?

Yes, but only in sections that are dynamic and you need to have easy
suppression. The downside of the Suppress Trailing Spaces ... option
is that if you have different paragraph styles they get mixed up when
you suppress the paragraphs. So if you want to have a bullet appear at
the end of a bulleted-styled list you insert the ADOR before the last
paragraph mark, program a \r at the start of the bullet and this
activates a new para in InDesign and gives it a bullet. If you tried
the normal way of inserting it as a paragraph-styled bullet and then
hide the ADOR via Suppress Trailing Spaces then the next paragraph
*after* the bullet you'd suppressed would pick up the style, and keep
it even when the ADOR reappears.

So the only method I have now is to use only character styles with one
para style/leading, and put them all in one line, programming hard
line returns (very old school). Not the easiest to work with, or
explain to a client when the proof set is off but it works. You can
use nested composition in tagged text files but this is very slow.

Let me know if you have any issues and I'll try to knock up an example file.

Cheers
George.

Mark Kuehn

unread,
Oct 9, 2008, 4:12:47 PM10/9/08
to xmpie...@googlegroups.com
I know the Country is blank, but the problem is the trailing return on the
last ADOR that has a value.

If all the ADORs have a value, the centering spans five lines
Name<CR>
Addr1<CR>
Addr2<CR>
CSZ<CR>
Country#

If all the Addr2 and Country are empty, the centering spans four lines
Name<CR>
Addr1<CR>
CSZ<CR>
#

Ideally I would want uCreate to "float" the end of input "#" up and replace
the last hard return. This would center three lines in the vertical space
not four like it is doing now. I can make it happen by putting all the ADORs
on one line and have program logic to trigger the inclusion of the returns,
but it is A LOT of extra work.

In a previous life, I worked with Creo's Darwin product and it would handle
this like I described.

-Mark


Adam Luther

unread,
Oct 9, 2008, 5:46:33 PM10/9/08
to xmpie...@googlegroups.com
Assuming I'm understanding your wish correctly, you should be able to do this with a combination of XMPie and InDesign tools. You want to center things in a vertical space?

1) Turn on XMPie's "Suppress Trailing Spaces"
2) Select your text frame and enable "Vertical Justification" in the Test Frame Options (in the Object menu).

Which would give you:
-- Frame Edge --
[space]
Name<CR>
Addr1<CR>
CSZ#
[space]
-- Frame Edge --

In this particular situation, copyfitting will not engage unless you force each individual ADOR to "No Break" (in the Character palette fly-out menu). I'd recommend that, actually, if you're talking about an address block (since you want to keep CSZ on the same line, regardless of length).


--
Adam Luther | Senior VDP Developer

| | |
Modern Postcard
1675 Faraday Avenue, Carlsbad, CA 92008
tel: 800 959-8365 x1610 | fax: 760 268-1773
http://www.modernpostcard.com

Mark Kuehn

unread,
Oct 10, 2008, 9:48:24 AM10/10/08
to xmpie...@googlegroups.com
No, that will not work because there will be a hard return after the CSZ
line. The Country ADOR will be suppressed, but the end of input "#" will not
be in the same line as the CSZ, therefore the centering will visually appear
to be off by one line.

-Mark

George Marsh

unread,
Oct 10, 2008, 4:46:03 PM10/10/08
to xmpie...@googlegroups.com
> Country#

What about

if(|->[Country]="") { "" } else { "\n" & |->[Country] }

Then put Country on the same line as CSZ?

You don't need to do every line ... and if you have uPlan you can
easily write a function to do this for addresses. Or make your address
box have no padding and just add a line return before the first line
to show when no Country ... unfortunately this software doesn't always
work the way you expect it to and being flexible is more productive
than getting annoyed in my experience. Wait till you need to add bleed
to a spread ...

Reply all
Reply to author
Forward
0 new messages