|
![](/i/fill.gif) |
I think I remember hearing about someone who made a patch which allowed
you to align the text object.(left, right, center, etc) Does anyone else
know about this?
I have just done a patch which adds the keywords align_left,
align_right, and align_center. I could post the source if anyone is
interested.(all it required was the three tokens in PARSE.H and
TOKENIZE.C, and a short bit of code in PARSE.C)
Oh, and I do know about min_extent and max_extent. :-) They can be used
to do the same thing, but I think it is nice to have this kind of thing
built into the text object.
Post a reply to this message
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
I just found some information about that other text alignment patch. It
was written by Jamis Buck and Noel Bundy, and is included in the
Smellenbergh Unofficial version(which is Mac only).
Their syntax uses the keyword position followed by a number:
0 - default (left justified)
1 - centered
2 - right justified
So you would add "position 1" to center the object.
I personally like my syntax better, but there are probably people
already using their patch. The syntax for my latest version:
align_left FLOAT_PAGE_WIDTH
align_center FLOAT_PAGE_WIDTH
align_right FLOAT_PAGE_WIDTH
FLOAT_PAGE_WIDTH is optional, and specifies the width of the "page" that
the text object is
aligned to. The page is actually just a boundary along the x-axis to
align the text object against. The patch does not protect against having
the text object run off the edge of the page
.
With align_center, FLOAT_PAGE_WIDTH does nothing, the text object is
centered on the x-axis.
With align_left, the left edge of the text object is aligned with the
left edge of the page. If the page width is unspecified, the right edge
of the object is aligned with x=0.
With align_right, the right edge of the text object is aligned with the
right edge of the page. If the page width is unspecified, the left edge
of the object is aligned with x=0.
Post a reply to this message
|
![](/i/fill.gif) |