artistic-2063_1280So this is how the ‘New Features in Oracle Forms 12c‘ presentation mentions the new Customizable ColorSchemes in Forms 12c.  Thanks to Michael Ferrante, Oracle Forms Product Manager for the updates.  As ever, the devil is in the detail.

forms 12c new features

Many years ago I was recommending an ERP system to a small company. We compared various vendors all with very similar features and prices. The winner was Netsuite, purely for its ability to use the colour scheme of the local soccer club! Green and Yellow became the standard for their ERP system. Colour is important but do get someone who knows about colour to configure the colour scheme. Amateurs, like myself, can look at colour and think a scheme would work when it clearly would not to most people. At worst look at a colour wheel and see how things work together. Anyway, once you have an idea of the colour scheme you need to do some file editing.

Look into the registry.dat file found in under the $DOMAIN_HOME in somewhere similar  to  C:\Oracle\Middleware\fr_home\user_projects\domains\pitss_domain\config\fmwconfig\servers\WLS_FORMS\applications\formsapp_12.2.1\config\oracle\forms\registry

This file has a section with color mappings for the client side java applet within which the Oracle Form will be run. I have renamed this schema to be sample_orig.

# Sample custom color scheme
colorScheme.sample_orig.description=sample_orig custom color scheme
colorScheme.sample_orig.lightest=0xFFFF33
colorScheme.sample_orig.lighter=0xFFCC33
colorScheme.sample_orig.light=0xCC3333
colorScheme.sample_orig.dark=0x993333
colorScheme.sample_orig.darker=0x660033
colorScheme.sample_orig.darkest=0x003333
colorScheme.sample_orig.selection=0x4169E1
colorScheme.sample_orig.pinstripe1=0xEE82EE
colorScheme.sample_orig.pinstripe2=0xF5DEB3

To set the Applet to use this schema you will need to edit the formsweb.cfg file, typically found in C:\Oracle\Middleware\fr_home\user_projects\domains\pitss_domain\config\fmwconfig\servers\WLS_FORMS\applications\formsapp_12.2.1\config

Within this file set the following:-

# Forms applet parameter to configure custom color scheme
customColorScheme=sample_orig

This will override the

#colorScheme=swan
colorScheme=swan

BUT any settings made within the Oracle Form, such as by using Visual ATtributes will override the settings made in eth Registry.dat file.

The sample_orig colour scheme set above results in the following:-

sample_orig

Nice! No idea who dreamt up this colour scheme, but probably not one anyone would use. This does raise the question why would you change colours at this global level. The answer is to extract the colour setting outside of the programming environment, which is a good thing. It also enables different levels of development to have different colour schemes without editing any application code. i.e. you might want one colour for development testing, one for QA and perhaps another for the production system. Anyone accidently done testing updates on the live production system??

To determine which of the colour parameters set for the java applet maps to Oracle Forms items I experimented with some settings. Using the following colour settings I could determine the mapping. If you know of a mapping file please let us all know! :-

colorScheme.sample.lightest=0xFF0000
#red FIELD BACKGROUND + MENU ITEM FOREGROUND

colorScheme.sample.lighter=0x800000
#Maroon TOOLBAR BACKGROUND

colorScheme.sample.light=0xFFFF00
#Yellow SCROLLBAR BACKGROUND, WINDOW HEADER BACKGROUND

colorScheme.sample.dark=0x808000
#Olive MAIN WINDOW BACKGROUND

colorScheme.sample.darker=0x00ff00
#Lime CANVAS BORDER

colorScheme.sample.darkest=0xFFFFFF
#White LABELS and FIELD content

colorScheme.sample.selection=0x0000FF
#Blue HIGHLIGHTING of Current FIELD cursor is in

colorScheme.sample.pinstripe1=0x000080
#Navy

colorScheme.sample.pinstripe2=0xFF00FF
# Fuchsia

forms_varity_cols

I have not figured out yet what the pinstripe1 and pinstripe2 set, I am sure somebody will let us know..

Lastly, my attempt at a football team – Manchester Unuited

colorScheme.manutd.description=manutd custom color scheme
colorScheme.manutd.lightest=0xFFFFFF
colorScheme.manutd.lighter=0xFF0000
colorScheme.manutd.light=0xFFFFFF
colorScheme.manutd.dark=0x000000
colorScheme.manutd.darker=0xFFFFFF
colorScheme.manutd.darkest=0xFF0000
colorScheme.manutd.selection=0x0000FF
colorScheme.manutd.pinstripe1=0xFFFFFF
colorScheme.manutd.pinstripe2=0xFF00FF

which results in:-

manu_color_fmb

Just a bit of fun but hopefully you will find this useful. If your Forms have colour settings within them and you want a fast and easy way of deleting theses settings across your complete Forms application let me know. I have a solution.