Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Horizontal lines in window backgrounds



On 1/29/05 7:30 AM, Jonny Taylor didst favor us with:

> Hi all,
> I wonder if anyone could give me some tips on something I noticed recently.
> Look for example at the top of a Finder window in OSX, in the strip
> containing the "back" and "view" buttons. The background to that area
> consists of faint horizontal stripes (certainly on some versions of OS X).
> Call me blind if you like, but to be honest on my LCD screen I had never
> actually noticed them. They show up far more prominently on some CRT
> displays.

The degree to which you can see them will vary depending on your display
profile. Open the Display pref pane in System Preferences. Click the Color
tab, and then the Calibrate button. Once you've calibrated your display, you
should see the theme patterns more clearly and you'll see why you really
need to address this issue. ;-)
> 
> I have a window whose main content is a User Pane control (which I
> understand to be the best way to provide custom control functionality under
> Carbon and still be back-compatible with OS9, which really *is* a
> requirement in my case). I guess I have been being a little inconsistent
> with whether I erase my backgrounds, paint them white, or do nothing. If I
> look at the screen at an acute angle my window looks really bad because some
> areas have this background and others don't.

Uh oh.
> 
> My current situation was that I was literally within a day of releasing the
> software when a beta tester pointed this out, so frankly at the moment I am
> looking for a quick fix initially. Is there a way of just turning off this
> behaviour in the window, which is kDocumentWindowClass with
> (kWindowStandardDocumentAttributes | kWindowStandardHandlerAttribute)?

No. No quickie, one-line solution.

> (I'm rather hampered by not knowing what the "official" term is for these
> stripes...).

It's a theme brush pattern.

> In the longer term people here may think I should be doing things
> differently. Can anyone point me to guidelines about what the intention of
> this background is and under what circumstances it should be retained?

*General* guideline: It should be used anywhere you don't have editable
text, textual data, or a list.

> The
> window has a layout a bit like a spreadsheet - so should I for example
> maintain the stripes in the blank space below the last row of data? It
> certainly looks really odd having the stripes "behind" the spreadsheet cells
> themselves.

Right. Use white for the background of the cells.

> Also, what is the best way of being consistent in the
> erasing/painting I do to make sure I don't end up like it is at the moment,
> where initially large parts of the window have the stripes, but because of
> the inconsistencies in my drawing code, after a few columns have been
> resized etc some areas have been turned white, without the stripes.

If you're using QuickDraw, you can set the theme background using
SetThemeBackground and erase. Definitely read through Appearance.h.

Larry

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden

References: 
 >Horizontal lines in window backgrounds (From: "Jonny Taylor" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.