Background Color

General development discussion.

Moderators: Susan Smith, admin, Gabriel

Post Reply
mluchterhand
Posts: 52
Joined: Mon Jun 08, 2009 7:28 pm
Location: Des Moines, IA
Contact:

Background Color

Post by mluchterhand »

For the most part, the user interface of my programs are very boring (all Windows default). After seeing some of the much better looking programs at the conference, I decided to try to spice some of mine up a bit. I started by trying to add some color. In the brconfig.sys Wiki page I located the example:

ATTRIBUTE [lime_black]/#00FF00:#000000
ATTRIBUTE [orange_white]/#FFA500:#FFFFFF
ATTRIBUTE [XX]UH/RGB:W font=arial:slant:max
SCREEN N [lime_black], U [orange_white], R [XX]

I applied the example and the menus are much more readable. However, the only places the attributes are applied are on the specific areas where PRINT FIELDS and RINPUT FIELDS exist. I guess my question is how do I make the rest of the screen a solid color instead of the Windows default. Sorry for the rookie question but I've been tinkering with this for over an hour and have had no luck so figured it would be quicker to get some input from the experts.
Thanks - Matt Luchterhand
Susan Smith
Posts: 717
Joined: Sun Aug 10, 2008 4:24 am
Location: Southern California

Post by Susan Smith »

Matt,

You can set the color of the screen when you open the window with the N=/foreground:background parameter where foreground and background can be a color number

00010 OPEN #1: "SROW=1,erow=10,scol=1,cols=30,n=/#FF0000:#DEE3E7",DISPLAY,OUTPUT
00020 PRINT #1: NEWPAGE
00030 PRINT #1,FIELDS "5,5,c": "TESTING"
00040 PAUSE

You don't HAVE to use both a foreground and background color. If you wanted the windows default of black type but wanted to specify the light-blue/gray screen background, you can just leave the foreground parameter empty:

00010 OPEN #1: "SROW=1,erow=10,scol=1,cols=30,n=/:#DEE3E7",DISPLAY,OUTPUT

Does that help?

-- Susan

P.S. If you want a couple of cool color picker tools (that I have shared with the group in the past) to fine-tune your color tinkering, read on:

This first one lets you hover over places on your screen with your cursor and you will see the 6-digit hex color number of what your cursor is pointing to. You can plug that into BR. It's a small exe file called colorpix.exe that is available from many download places. If you can't find it (virus check it first if you do!), let me know and I'll Email it to you. It's free.

The second one is a color blender where you can enter two color numbers and create many shades in between - and get the color number of those midpoints. I often use this one to lighten or darken colors by blending with white (FFFFFF) or black (000000). http://meyerweb.com/eric/tools/color-blend/[/img]
mluchterhand
Posts: 52
Joined: Mon Jun 08, 2009 7:28 pm
Location: Des Moines, IA
Contact:

Post by mluchterhand »

Figured it out. Thanks much Susan!!! :D
Thanks - Matt Luchterhand
Susan Smith
Posts: 717
Joined: Sun Aug 10, 2008 4:24 am
Location: Southern California

Post by Susan Smith »

Great! Good luck Matt. I think that the choice of background color on a screen can really make it look new and updated (or just dated) so it's good that this gets a little attention in our programming.

-- Susan
Post Reply