OT: Background image position and <pre>/<code> tag question



Schraalhans Keukenmeester wrote:

Carolyn Marenger wrote:
Schraalhans Keukenmeester wrote:


I am building a default *** for my linux-related pages.
Since many linux users still rely on/prefer viewing textmode and
unstyled content I try to stick to the correct html tags to pertain good
readibility on browsers w/o css-support.


Do we? I use linux, and I occasionally check my pages in one of the text
browsers, but I normally use konqueror and sometimes firefox. Do you
know
what the stats are for text only usage? I would like to know. Thanks!

Hmm, I may have exaggerated here. And I have no stats either. I was just
thinking of 'all' those poor people out there working on *nix boxes with
no X support installed. Or projecting my own experience onto an
imaginary crowd. So rephrase: It is possible my page will be viewed
using browsers that don't support css styling, or by people who have
style turned off. And judging from my own experience and prejudice, such
users -if any- are more likely to be found amongst *nix users than MS
slaves. As for the stats, I intend to find out.

Anyways, adhering to (widely accepted) standards/recommendations never
hurt anyone.

To the best of my knowledge, this is an accurate statement. However, here
is a twist on it... Can you name one software company who by breaking
standards and reinventing their own twist on them, has made billions and
hurt thousands?

I do like to adhere to standards, and I hate the amount of time it takes to
create a standards compliant page, only to have to hack it so that it also
works in various versions of M$IE.



For important notes, warnings etc I use the <pre> tag, which shows in a
neat bordered box when viewed with css, and depending on its class a
clarifying background-image is shown.

I would stick to using <pre> for preformatted text, like formulae and
poetry. Keep it to its intended use for clarity.

Precisely my point! I've seen the weirdest and highly unorthodox (ab)use
of tags and constructs. All hidden quite nicely in popular browsers, but
close to unusable in others, at times.

I used to do a lot of that back when I coded in 3.2. I can remember hours
of sorting through levels of tables, to get that one item moved from the
third position of the fourth column to the 2nd position of the first
column. Just thinking back to those days scares me. I don't understand
why people still do it. CSS is so much easier to maintain.



I would like the background image to 'break out' of the surrounding
border, so it shows as overlapping the bordered text edge.

I tried using a negative background-position but that makes the image
disappear under the border. z-index no help here, as it relates to all
of the <pre> tag.

In text only mode, this is obviously pointless. This would be for the
graphically enabled. :)

Correct. The text-only/no-css browsing blahblah above only served as a
motivation/defense for my intent to comply with standards.

In that case let me back you up. I go with the philosophy of design for
text, accentuate with graphics. Anyone can get the content, graphical
browsers can see pretty versions of it. Auditory ones can hear it. And I
also like to reformat it for printers, to hide the erroneous menus and crap
that is useless in a printed document.



FIRST QUESTION: Any idea how I can have the images shown overlapping
both the underlying page and the styled content without resorting to
complicating separate tags and/or absolute positioning?

I don't think so, but I wouldn't ask me if I was trying to do this.
There may indeed be a way with javascript or something similar.

I am trying a new construction with a wrapper div and relative placement
of the bg image outside the <pre> tag. Not ideal, but it works okay
sofar (only I am scared to try my handiwork in IE now... I may need
counseling later on).

If you need counselling later on, then I will let you lie on my cybercouch
and tell me all about it. I will be taking numerous notes in my
cybernotebook which to any but a trained eye, will look like cyberdoodles.

Then I have code samples on my pages, and I would prefer to use the
<code> tags surrounding these. Unfortunately this doesn't keep the
formatting like <pre> does, including spaces, returns etc. So I am
tempted to use pre tags instead with a class 'code' added, but this
isn't correct use of the available tags in html.

I would use the code tag, and specify a monospace font within the style
definition. Courier is an obvious but ugly choice. I might pick another
font as the primary option, and downgrade back to courier for those who
don't have the other fonts.

Courier is _indeed_ ugly. recognizable though, and immediately
associated by many with coding. Any font in particular you'd go for in
the monospaced department? Most I've ran into have as much as or less
appeal than courier. While we're at it, which regular font strikes your
fancy?

On my own system, I use Century Schoolbook Mono for a mono spaced font. I
don't remember where I first got my hands on it - must have been some 'doze
software, before I made the switch to Linux.

On a day to day basis, I use a little font called Classical Garamond. I
have done a bunch of work with people with learning disabilities, including
dyslexia. There is a specific font, somewhat expensive last time I looked,
available for dyslexics. It is easier for dyslexics to read, and seems to
reduce eye strain for most other people, myself included. Classical
Garamond is a very close match to the other.

<snip>

Cheers, and welcome. It did help, or at least refuel inspiration.
And made me laugh indirectly (I checked out your domain in my browser.
Never before read a whole site's content in under 10 secs.)

You are one of the first to view the site and not tell me about the single
type that exists and hasn't been corrected for the last year. I did
however know if it's existence. :) I am glad it gave you a laugh!

Carolyn
--
Carolyn Marenger

.


Loading