Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.gui > #1255

Re: HTML table used in JT

From "btschumy" <btschumy@THRWHITE.remove-dii-this>
Subject Re: HTML table used in JT
Message-ID <1174486748.680453.84620@b75g2000hsg.googlegroups.com> (permalink)
Newsgroups comp.lang.java.gui
References <1174441294.980891.295360@l75g2000hse.googlegroups.com>
Date 2011-04-27 15:32 +0000
Organization TDS.net

Show all headers | View raw


  To: comp.lang.java.gui
On Mar 20, 8:41 pm, "Andrew Thompson" <andrewtho...@gmail.com> wrote:
> On Mar 21, 4:23 am, btsch...@gmail.com wrote:
>
> > In Java 1.6 on Windows, I'm trying to display an HTML table in a
> > JTextPane where cellspacing="0".  It should display the cell borders
> > as a single line but it is instead displaying it as if cellspacing was
> > "1".
>
> Interestingly,
> 1) cellspacing="20" makes a huge space, so it seems
> to be honouring that attribute at some level, in some
> form.  I suspect that there is some other spacing in
> there that the JEditorPane is (in its simplistic styling
> of HTML) expecting to see for a true 'no pad' cell.
>
> If I have any further insights into it, I
> will pop back by.
>
> Andrew T.

Andrew,

Yes, the cellspacing attribute is being handled, just not correctly.
I actually tried making it -1 and that does cause single pixel lines
to be drawn between cell, but the the border around all the cells is
still not drawn correctly.  I wouldn't want to use this hack in
production code, but it is interesting.

---
 * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet!
--- Synchronet 3.15a-Win32 NewsLink 1.92
Time Warp of the Future BBS - telnet://time.synchro.net:24

Back to comp.lang.java.gui | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

HTML table used in JTextP "btschumy" <btschumy@THRWHITE.remove-dii-this> - 2011-04-27 15:32 +0000
  Re: HTML table used in JT "Andrew Thompson" <andrew.thompson@THRWHITE.remove-dii-this> - 2011-04-27 15:32 +0000
    Re: HTML table used in JT "btschumy" <btschumy@THRWHITE.remove-dii-this> - 2011-04-27 15:32 +0000

csiph-web