I would like to create some pages using a monospaced font, like Monaco or Courier, where there are multiple columns of text, aligned horizontally using spaces. I’ve done this in GoLive with no problems. It’s called preformatted text.
Pages I’ve created in Freeway look OK in page view, but in Preview or Preview in a browser the multiple spaces are eliminated, destroying the column alignment.
Yes, I could use tables, but I would like to leave the page as plain text.
I would like to create some pages using a monospaced font, like
Monaco or Courier, where there are multiple columns of text, aligned
horizontally using spaces. I’ve done this in GoLive with no
problems. It’s called preformatted text.
Not here it’s not
Pages I’ve created in Freeway look OK in page view, but in Preview
or Preview in a browser the multiple spaces are eliminated,
destroying the column alignment.
HTML doesn’t recognise multiple spaces. GoLive must have been
‘helping’ you there. You could try putting in option-spaces (hard
spaces) that will be recognised.
Yes, I could use tables, but I would like to leave the page as plain
text.
A table would be MUCH better than this. There’s no shame in using
tables for tabular information.
On Jun 23, 2008, at 1:56 PM, Paul Bradforth wrote:
I’ve done this in GoLive with no
problems. It’s called preformatted text.
Not here it’s not
Actually, he’s right. It is called preformatted text, and the tag for
it is < pre >.
<pre>
this is some text inside
the pre tag and spaces
are legal characters here
so you can make dramatic pauses
if you so desire
</pre>
Freeway will be no help to you here. It’s apparently not possible to
style text as PRE in Freeway. I could probably write an Action that
would do this for you, but I just got back from vacation and I have a
lot of mail to go through first…
Would that it were that simple. Any code that Freeway generates
within those tags will be rendered as code, not as plain text. If you
really want to make a PRE block that contains nothing but text, you
will need to do something icky like this:
txt = txt.replace(/<.+?>/gi,'');
to the guts of the element.
Walter
On Jun 23, 2008, at 6:04 PM, Keith Martin wrote:
Sometime around 23/6/08 (at 14:14 -0400) Walter Lee Davis said:
Freeway will be no help to you here. It’s apparently not possible to
style text as PRE in Freeway.
Top of the head thought here: how about using a couple of markup
items? Place one containing “
” at the beginning of the text and
one containing “
Before people go jumping through flaming hoops, please let me say that
not only is the PRE tag available in Freeway Pro 5, it was also
available in Freeway 4.
Yes, I saw that and am still trying to figure out why it happened.
It’s an interesting trick, making a tag-only style containing no
styling information, and then applying that to the text. The only
down-side I can see to it is that you end up with a PRE around each
“paragraph” of text, rather than a single block-level container that
may contain a number of related lines of text.
Thinking more about my action-driven solution, I’m not sure how to
get around the line-break issue there either. You needed to insert
manual line-breaks in your example, using a Shift-Return. Inside a
real PRE, there would only be line-feeds to indicate any line breaks,
and each line-feed would only count for a single new line, rather
than the enforced double-spacing of a paragraph break.
I need to experiment with the new HTML preview format possible in
Actions. That, coupled with an Action-specified monospace font-style
and a regular expression to replace all paragraph breaks with
newlines, could be the ticket.
It seems the p tags were just replaced with pre tags.
Getting Freeway to apply such a style is the only difficult part…
there has to be some definition to it or else Freeway just doesn’t
seem to notice a style has been applied.
As for the line breaks, without them the text would extend in one
line. This is a function of the PRE tag, as if there are no line
returns it ignores the concept of wrapping inside the container.
This basic process works for other tags as well, here’s my Freeway 4
file with many of the tags I normally used. Obviously it was
underlooked even way back then http://www.thebigerns.com/freeway/mybasicstyles/
Walter Lee Davis wrote:
Yes, I saw that and am still trying to figure out why it happened.
It’s an interesting trick, making a tag-only style containing no
styling information, and then applying that to the text. The only
down-side I can see to it is that you end up with a PRE around each
“paragraph” of text, rather than a single block-level container that
may contain a number of related lines of text.
Thinking more about my action-driven solution, I’m not sure how to
get around the line-break issue there either. You needed to insert
manual line-breaks in your example, using a Shift-Return. Inside a
real PRE, there would only be line-feeds to indicate any line breaks,
and each line-feed would only count for a single new line, rather
than the enforced double-spacing of a paragraph break.
I need to experiment with the new HTML preview format possible in
Actions. That, coupled with an Action-specified monospace font-style
and a regular expression to replace all paragraph breaks with
newlines, could be the ticket.
I believe it’s helpful to remember that mono-spaced fonts were created for use in software… entities that dictated how, what and where text would appear. Skip over to browsers and multiple operating systems and the whole world goes to hell. Differing monitor resolution, user preferences, browser rendering algorithms, and so on play havoc with the designer’s choices.
But then, I’m boring. I stick with Georgia and Verdana for most everything. Tried a whole lot of alternatives and always ended up back with these two.