This topic contains 3 replies, has 0 voices, and was last updated by GAJ 8 years, 9 months ago.

  • Author
    Posts
  • #2981

    tgrimm

    I have come across this issue many times. In all of the tables in advanced PDF’s the default text-align is set to justify and so far I cannot find anyway of over riding this. Is it possible to prevent text justification in tables? It only seems to happen when a field has too many characters forcing a line break, well instead of simply breaking the line it justifies the first line making it look ridiculous. For example my client has an email address for one customer that is too long. So when it prints out on documents it shows up like this:

    E X A M P L E –

    email@email.com

    I have tried text-align via css as well as inline styling to no avail.
    This is a cached copy. Click here to see the original post.

  • #2982

    tgrimm

    Found the answer. Turns out there is an inherited p tag within each of the td elements. So for it to be set via css it would look like this:

    td p {

    text-align: left;

    }


    GAJ replied on 02/08/2016, 11:01 PM: Works like a charm. Many many thanks! Still I’m curious for a little deeper understanding.

    Is this how pdf handles the td element?

    And how did you figure this out?

    Again, very nice, and many thanks.

  • #2983

    wwinters

    Very nice!

    Thank you!

    This has been driving me crazy for a while.

    Wes

  • #2984

    GAJ

    Very nice! And thank you very much.

    Still, I’m curious… how did you figure this out?

    Again, thanks very much!

    All the best…

You must be logged in to reply to this topic.