Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > Re: large bulleted in a HTA

Reply
Thread Tools

Re: large bulleted in a HTA

 
 
Jukka K. Korpela
Guest
Posts: n/a
 
      03-06-2012
2012-03-06 11:39, Andrew Poulos wrote:

> <ul style="font-size:48pt;">
> <li>One</li>
> <li>Two</li>
> <li>Three</li>
> </ul>
> </body>
> </html>
>
> The trouble is that whereas, as a HTML page, IE 9 displays the page
> correctly, as a HTA the bullet displays at 12pt instead of 48pt. Is this
> some limitation of HTAs or is there a way to get bullets to behave in HTAs?


Browsers have traditionally rendered the bullets of bulleted lists
(<ul>) in a fixed size, so I'm not surprised. Some new versions of
browsers apply font-size settings to bullets, and this makes sense in
practice, though I think specifications are silent about this - do the
browser-generated bullets really constitute part of the _text_?

Anyway, the robust approach, which works on practically all browsers, is
to use actual bullet characters (written as such or using entity or
character references). Then they are surely part of the content and get
affected by font face, size, and color settings, can be positioned at
will, etc.

<ul style="list-style-type: none; font-size:48pt;">
<li>&bull; One</li>
<li>&bull; Two</li>
<li>&bull; Three</li>
</ul>

(Problem: When CSS is off, you get double bullets. Solution: don't use
<ul> and <li> markup, use a <div> containing <div> elements instead.)

--
Yucca, http://www.cs.tut.fi/~jkorpela/
 
Reply With Quote
 
 
 
 
dorayme
Guest
Posts: n/a
 
      03-06-2012
In article <jj4n2l$pv6$(E-Mail Removed)>,
"Jukka K. Korpela" <(E-Mail Removed)> wrote:

> Browsers have traditionally rendered the bullets of bulleted lists
> (<ul>) in a fixed size, so I'm not surprised. Some new versions of
> browsers apply font-size settings to bullets, and this makes sense in
> practice, though I think specifications are silent about this - do the
> browser-generated bullets really constitute part of the _text_?


On all Mac browsers that enlarge text only as distinct from the
zooming of all the display, the bullets, as far as I remember older
browsers, have gone up with user text size and adjustments. But I may
be wrong, the oldest browser I can test, that I have that still runs
on my normal working machine, is MacIE5 and that displays the bullets
in proportion to the text size.

--
dorayme
 
Reply With Quote
 
 
 
 
Jukka K. Korpela
Guest
Posts: n/a
 
      03-06-2012
2012-03-06 12:34, Andrew Poulos wrote:

>> <ul style="list-style-type: none; font-size:48pt;">
>> <li>&bull; One</li>
>> <li>&bull; Two</li>
>> <li>&bull; Three</li>
>> </ul>
>>
>> (Problem: When CSS is off, you get double bullets. Solution: don't use
>> <ul> and <li> markup, use a <div> containing <div> elements instead.)

>
> Doesn't it also mean that long lines won't wrap as expected


In both approaches mentioned above, lines wrap so that the bullets are
"inset", as if list-style-position: inside had been used when using an
otherwise unstyled <ul>.

If you prefer "outset" bullets, the safest approach is to use a table,
with bullets in one column:

<table>
<tr valign=top><td>&bull;<td>One
<tr valign=top><td>&bull;<td>Two
<tr valign=top><td>&bull;<td>Three
</table>

(Some people may suspect that someone has taken over the identity of
Yucca, the Semantic Structuralist. But it's really me, I have just
become a Pragmatist, or an HTML Anarchist, see
http://www.cs.tut.fi/~jkorpela/pragmatic-html.html8 )

--
Yucca, http://www.cs.tut.fi/~jkorpela/
 
Reply With Quote
 
dorayme
Guest
Posts: n/a
 
      03-06-2012
In article <(E-Mail Removed) >,
Andrew Poulos <(E-Mail Removed)> wrote:

> On 6/03/2012 8:57 PM, Jukka K. Korpela wrote:
> > 2012-03-06 11:39, Andrew Poulos wrote:
> >
> >> <ul style="font-size:48pt;">
> >> <li>One</li>
> >> <li>Two</li>
> >> <li>Three</li>
> >> </ul>
> >> </body>
> >> </html>
> >>
> >> The trouble is that whereas, as a HTML page, IE 9 displays the page
> >> correctly, as a HTA the bullet displays at 12pt instead of 48pt. Is this
> >> some limitation of HTAs or is there a way to get bullets to behave in
> >> HTAs?

> >
> > Browsers have traditionally rendered the bullets of bulleted lists
> > (<ul>) in a fixed size, so I'm not surprised. Some new versions of
> > browsers apply font-size settings to bullets, and this makes sense in
> > practice, though I think specifications are silent about this - do the
> > browser-generated bullets really constitute part of the _text_?
> >
> > Anyway, the robust approach, which works on practically all browsers, is
> > to use actual bullet characters (written as such or using entity or
> > character references). Then they are surely part of the content and get
> > affected by font face, size, and color settings, can be positioned at
> > will, etc.
> >
> > <ul style="list-style-type: none; font-size:48pt;">
> > <li>&bull; One</li>
> > <li>&bull; Two</li>
> > <li>&bull; Three</li>
> > </ul>
> >
> > (Problem: When CSS is off, you get double bullets. Solution: don't use
> > <ul> and <li> markup, use a <div> containing <div> elements instead.)

>
> Doesn't it also mean that long lines won't wrap as expected?
>



Depends what you expect. Perhaps you are requiring that the wrap,
using DIVS, not go under the bullets when CSS is off? You can use an
HTML table to fix this, the column with the bullets will stay
separately aligned.

--
dorayme
 
Reply With Quote
 
dorayme
Guest
Posts: n/a
 
      03-06-2012
In article <(E-Mail Removed) >,
Andrew Poulos <(E-Mail Removed)> wrote:

> On 6/03/2012 10:01 PM, dorayme wrote:

....
> > ... Perhaps you are requiring that the wrap,
> > using DIVS, not go under the bullets when CSS is off? You can use an
> > HTML table to fix this, the column with the bullets will stay
> > separately aligned.
> >

> Thanks for your help. Unfortunately I was looking for a way for the
> bullets in the UL to display at the "correct" size and not for a way to
> mimic the display.
>
> What's odd is that if I change the list type to a OL then, as a HTA, the
> list numbers display at the "correct" size.


Can't help with HTA, I know more about cheese. <g>

If you want a UL because you want to be as semantic as possible, then,
as I have many times argued, but won't go on about it in detail now, a
table is not a wholly inappropriate element to use in its stead if
there is any stylistic advantage. A table is a way of organising lists
anyway, a simple list done in a table is a limiting case and much
meaning is preserved.

If the OL works for you, you could try to see if

<ol style="list-style-type: disc;">
<li>...</li>
....
</ol>

fixes the sizing problem in HTA. Be interesting to see if this
triggered your HTA to size up the bullets appropriate to the text. I
expect not, but you never know!

And then there is the semantic problem which you may be worrying
about?

The other thought I have - worth an experiment perhaps? - is to try to
put in an explicit style about list-style-type on the UL. Does the
failure to size with the text happen no matter what you choose? For
example, "circle" instead of "disc"? What about, just to see, if you
put in "decimal" as style type on a UL?

--
dorayme
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: large bulleted in a HTA BootNic HTML 0 03-06-2012 01:54 PM
Bulleted List shapper ASP .Net 1 03-30-2007 02:11 PM
Bulleted List question nina297 ASP .Net 1 03-22-2007 08:49 PM
How do Bulleted list? Woody Splawn ASP .Net 2 05-19-2004 10:23 PM
need help with bulleted lists Eric Fields HTML 9 02-24-2004 12:29 PM



Advertisments