Results 1 to 2 of 2
  1. #1
    barney75 is offline Member
    Join Date
    Mar 2009
    Posts
    2
    Rep Power
    0

    Default Indentation - plain text

    Hi Guys,

    I have a problem with indentation in a plain text email.

    Problem is that the text is dynamic and character widths vary depending on the font (fine with Monospacing fonts, but the likes of gmail and hotmail don't pick that up). So if i use something like StringUtils.rightPad(... still does not guarantee correct indentation.

    For example, both of these lines are the same length before the "|" (text before | is dynamic):

    Model: |CDE-120
    Manufacturer's Serial Number: |1277011

    Is there any solution to this other than formatting using html and css? That would mean rewriting a lot of code...
    Last edited by barney75; 03-23-2009 at 05:55 PM.

  2. #2
    barney75 is offline Member
    Join Date
    Mar 2009
    Posts
    2
    Rep Power
    0

    Default

    btw... the spaces i talked about before the "|" have been stripped out by this post... both strings were 50 characters in length.

Similar Threads

  1. Replies: 2
    Last Post: 01-23-2009, 04:09 PM
  2. Indentation Size Reset While Coding JavaFX
    By JDCAce in forum NetBeans
    Replies: 0
    Last Post: 10-06-2008, 09:28 PM
  3. String Code Indentation
    By andysh in forum New To Java
    Replies: 1
    Last Post: 12-22-2007, 02:45 AM
  4. how to set indentation to a text
    By elizabeth in forum New To Java
    Replies: 1
    Last Post: 08-06-2007, 06:42 PM
  5. convert html to plain text
    By vissu007 in forum New To Java
    Replies: 3
    Last Post: 07-07-2007, 02:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •