Kbase 17698: Apptivity: setting global properties for all new Forms
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/05/1998 |
|
Apptivity: setting global properties for all new Forms
How do you set global properties (i.e. font) on all new Forms?
You can do this by changing the "template" files (etc/*.abt)
In the [install-dir]/etc directory there are a number of abt
files:
ClientEvents.abt
ClientNotification.abt
Form.abt
Frame.abt
Globals.abt
Project.abt
QueryEvents.abt
ServerEvents.abt
These files are the raw material for all new Java files created
by Apptivity Developer. If you change the template file, then
you change all the new files created.
For example, if you:
a) backup Form.abt
b) edit Form.abt
c) look for the init method
public void init()
{
super.init();
setFont(new Font("DialogInput", Font.PLAIN, 14));
//$BEGIN_CREATE_OBJECTS
//$END_CREATE_OBJECTS
// Code to customize data-bound controls goes here
//$BEGIN_INIT_OBJECTS
//$END_INIT_OBJECTS
}
d) Change the setFont line to use 12 point font.
setFont(new Font("DialogInput", Font.PLAIN, 12));
e) Save the file
f) In Apptivity Designer, create a new form. It will have the new
setFont line.
NOTE:
This is an advanced feature. You should NEVER change the references
to anything inside a $ or //$. These are the pieces that will be
managed by Apptivity.
Progress Software Technical Support Note # 17698