Formating text

Discussion in 'HTML' started by Stuck, Jul 7, 2007.

  1. Stuck

    Stuck Guest

    Is it possible to set some CSS property so that text get formated just
    like in a book. I mean so that the spacing between word is dynamic and
    the last letter of each word on each line always ends at the same
    place? Are you with me? .. :)
     
    Stuck, Jul 7, 2007
    #1
    1. Advertising

  2. Stuck

    dorayme Guest

    In article
    <>,
    Stuck <> wrote:

    > Is it possible to set some CSS property so that text get formated just
    > like in a book. I mean so that the spacing between word is dynamic and
    > the last letter of each word on each line always ends at the same
    > place? Are you with me? .. :)


    You mean justified text?

    div {text-align: justify;}

    --
    dorayme
     
    dorayme, Jul 7, 2007
    #2
    1. Advertising

  3. Stuck

    dorayme Guest

    In article
    <>,
    dorayme <> wrote:

    > In article
    > <>,
    > Stuck <> wrote:
    >
    > > Is it possible to set some CSS property so that text get formated just
    > > like in a book. I mean so that the spacing between word is dynamic and
    > > the last letter of each word on each line always ends at the same
    > > place? Are you with me? .. :)

    >
    > You mean justified text?
    >
    > div {text-align: justify;}


    Come to think of it, it used to look terrible when I tried it but
    I just was reminded to have a go again just now and with Safari,
    it looks pretty good. Perhaps it is my beautiful writing style
    with simple short English words or something?

    http://tinyurl.com/25vztl

    --
    dorayme
     
    dorayme, Jul 7, 2007
    #3
  4. Scripsit dorayme:

    >> You mean justified text?
    >>
    >> div {text-align: justify;}

    >
    > Come to think of it, it used to look terrible when I tried it


    It mostly looks terrible or very terrible. My old dusty page on
    justification,
    http://www.cs.tut.fi/~jkorpela/www/justify.html
    is probably _a little_ too pessimistic, since many browser bugs have been
    fixed. However, the basic problems still remain:

    1) The results depend on the line length (column width), font size, and
    other factors. If authors try to "fix" this by setting those parameters to
    fixed values, they create further problems.

    2) Browsers (normally) achieve the justification by increasing word spacing,
    whereas in book typography, character spacing within words may get adjusted,
    too. This may result in awfully large gaps between words.

    3) Browsers normally don't split a word across lines, and they have no
    automatic word division (as typesetting software and even word processors
    have). Helping them with &shy; is almost safe these days but very clumsy and
    does not help on Firefox. This creates serious problems especially when the
    document contains long words (which are common in many languages).

    > but I just was reminded to have a go again just now and with Safari,
    > it looks pretty good. Perhaps it is my beautiful writing style
    > with simple short English words or something?
    >
    > http://tinyurl.com/25vztl


    It's not that bad on IE or Firefox either. But it's largely because the line
    length is relatively large, as compared with the use of mostly short words.

    Yet, if you look e.g. at the start of the 3rd paragraph ("He asked the camel
    hire..."), you'll notice that word spacing is disturbingly larger than on
    the page as a whole. This would not happen in good book typography.

    Besides, if you wish to imitate print typography by using justification, the
    effect is odd when you let browsers use "engineering paragraphs" (with empty
    lines between paragraphs) instead of "literary paragraphs" (first-line
    indents, with no vertical spacing between paragraphs) and you have "computer
    quotes" (Ascii quotation marks) instead of proper quotation marks. And Arial
    is really a simplistic modern font rather than a typographically stylistic
    font.

    What I mean is that you have a mix of "engineering style" and "literary
    style". Many people are used to seeing and reading both of them, but not as
    mixtures.

    --
    Jukka K. Korpela ("Yucca")
    http://www.cs.tut.fi/~jkorpela/
     
    Jukka K. Korpela, Jul 7, 2007
    #4
  5. Stuck

    rf Guest

    "dorayme" <> wrote in message
    news:...
    > In article
    > <>,
    > dorayme <> wrote:
    >
    >> In article
    >> <>,
    >> Stuck <> wrote:
    >>
    >> > Is it possible to set some CSS property so that text get formated just
    >> > like in a book. I mean so that the spacing between word is dynamic and
    >> > the last letter of each word on each line always ends at the same
    >> > place? Are you with me? .. :)

    >>
    >> You mean justified text?
    >>
    >> div {text-align: justify;}

    >
    > Come to think of it, it used to look terrible when I tried it but
    > I just was reminded to have a go again just now and with Safari,
    > it looks pretty good. Perhaps it is my beautiful writing style
    > with simple short English words or something?


    The long words give you trouble? :)

    --
    Richard.
     
    rf, Jul 7, 2007
    #5
  6. Stuck

    dorayme Guest

    In article <hVLji.187987$>,
    "Jukka K. Korpela" <> wrote:

    > Scripsit dorayme:
    >
    > >> You mean justified text?
    > >>
    > >> div {text-align: justify;}

    > >
    > > Come to think of it, it used to look terrible when I tried it

    >
    > It mostly looks terrible or very terrible. My old dusty page on
    > justification,
    > http://www.cs.tut.fi/~jkorpela/www/justify.html
    > is probably _a little_ too pessimistic, since many browser bugs have been
    > fixed. However, the basic problems still remain:
    >

    ....
    > >
    > > http://tinyurl.com/25vztl

    >
    > It's not that bad on IE or Firefox either. But it's largely because the line
    > length is relatively large, as compared with the use of mostly short words.
    >
    > Yet, if you look e.g. at the start of the 3rd paragraph ("He asked the camel
    > hire..."), you'll notice that word spacing is disturbingly larger than on
    > the page as a whole. This would not happen in good book typography.
    >


    You are right. It is barely passable even in good circumstances
    and is not to be recommended generally. I was just a little
    surprised that browser justification had improved from the last
    time I looked years back.

    Must be a hard technical problem to write code for a browser that
    uses more than brutal word spacing? But there are quite some
    inherently difficult requirements to satisfy in a general
    algorithmic way. In the url I provide above, if the window is
    narrowed a lot, the text that runs down the side of the picture
    could be better done.

    Frankly, I find it hard to fan any slight desire for justified
    text.

    The only circumstance I can think of for now would be trick texts
    that the reader is required to read both from left to right and
    from right to left on alternate lines.

    --
    dorayme
     
    dorayme, Jul 8, 2007
    #6
  7. Stuck

    dorayme Guest

    In article <iYLji.4321$>,
    "rf" <> wrote:

    > > it looks pretty good. Perhaps it is my beautiful writing style
    > > with simple short English words or something?

    >
    > The long words give you trouble? :)


    As it happens, these stories come from my very important
    historical work on ancient texts, my publisher requires that my
    translations are kept very simple. For a sample of the deep
    scholarly work I do:

    http://tinyurl.com/ym2slq

    --
    dorayme
     
    dorayme, Jul 8, 2007
    #7
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Dmitri Manushin

    Formating text

    Dmitri Manushin, Aug 14, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    398
    Dmitri Manushin
    Aug 14, 2003
  2. djc
    Replies:
    2
    Views:
    439
    William F. Robertson, Jr.
    Dec 10, 2004
  3. Newbie
    Replies:
    5
    Views:
    493
    andreas
    Oct 4, 2004
  4. Dips

    formating of text file

    Dips, May 19, 2005, in forum: Java
    Replies:
    2
    Views:
    399
    Matt Humphrey
    May 19, 2005
  5. Greg Smith

    Label text formating

    Greg Smith, Nov 2, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    303
    james
    Nov 2, 2006
Loading...

Share This Page