Article View: comp.sys.amiga.tech
Article #2829Re: Window Border Colors
From: Peter Cherna
Date: Fri, 19 Jan 1990 04:22
Date: Fri, 19 Jan 1990 04:22
35 lines
2099 bytes
2099 bytes
In article <42700023@m.cs.uiuc.edu> schwager@m.cs.uiuc.edu writes:
>
>I'd like to open up a standard Intuition window in a custom screen, and use
>any color I choose for the border. Is this possible? I tried using
>SetAPen and SetBPen and SetOlPen on the screen's RastPort, but none of
>these worked to make the entire border one nice lovely color. It always
>comes up using color register 1.
The NewWindow structure has a pair of fields called "DetailPen" and
"BlockPen". The block pen is used to render (among other things)
the window border and any proportional gadget autoknobs. The DetailPen
is used for the window title lettering and horizontal stripes in the
drag bar, and for the container of proportional gadgets. Set these
values to your desired colors and you'll be in business. If either
value is set to -1, the value will be taken from the DetailPen or
BlockPen value you can establish for your screen by setting those
fields of a NewScreen structure.
SetAPen(), SetBPen(), and SetOPen() affect many graphics.library
rendering commands. Rendering done through Intuition typically
gets its color values from structures like IntuiTexts, Borders,
NewWindows (well, really Windows by the time it's drawn), etc.
>I couldn't find this in the RKM's;
>perhaps I'm just dense... Thanks for any help...
It's in there, but hey, this is no small book :-)
>-Mike Schwager
Peter
--
Peter Cherna, Software Engineer, Commodore-Amiga, Inc.
{uunet|rutgers}!cbmvax!peter peter@cbmvax.cbm.commodore.com
My opinions do not necessarily represent the opinions of my employer.
Technical Details
Message-ID:
<9386@cbmvax.commodore.com>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!yale!think!zaphod.mps.ohio-state.edu!usc!apple!oliveb!amiga!cbmvax!peterReferences:
<42700023@m.cs.uiuc.edu>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!yale!think!zaphod.mps.ohio-state.edu!usc!apple!oliveb!amiga!cbmvax!peter From: peter@cbmvax.commodore.com (Peter Cherna) Newsgroups: comp.sys.amiga.tech Subject: Re: Window Border Colors Message-ID: <9386@cbmvax.commodore.com> Date: 19 Jan 90 04:22:10 GMT References: <42700023@m.cs.uiuc.edu> Reply-To: peter@cbmvax.commodore.com (Peter Cherna) Organization: Commodore, West Chester, PA Lines: 35