home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The World of Computer Software
/
World_Of_Computer_Software-02-385-Vol-1of3.iso
/
g
/
gina15.zip
/
CHANGES-1.2
< prev
next >
Wrap
Text File
|
1992-02-27
|
5KB
|
137 lines
Changes to GINA++ since version 1.1
===================================
- A workaround for a possible type conflict with the type name Boolean
has been implemented. If a type clash occurs (for example with ONTOS),
programms must first include Gina/Gina.h and must then undefine the name
Boolean:
#include <Gina/Gina.h>
#undef Boolean
#include <Ontos.h>
The type Boolean has been renamed by a preprocessor macro to XBoolean.
- Form constraint resources now work with the GnScrolledText widget.
- GnRadioGroup and GnToggleGroup now support the withFrame and labelString
resources.
- GnWidget::create() now returns the created C++ widget. Programmers can now
write things like
w.create((new GnFrame)->create(parent, "frame"), "w");
which must formerly be written as
GnFrame *frame = new GnFrame;
frame->create(parent, "frame");
w.create(frame, "w");
- The missing implementation of GnSelection::add(int,Boolean,Boolean) was
added.
- width, height, x, y, and sensitive resources are now set for the
group_widget instead of the primary widget.
- A bug with wrong clipping regions for expose events in GnView had been
fixed.
- Functions for drawing strings aligned in rectangles have been added for
GnView. String could be aligned left, right, or centered and could be
drawn normal or reverse. These function are protected members and may only
be accessed by the view's draw() function.
protected: // glyphs & strings
void DrawGlyphs(GC gc, int x, int y, char* str, unsigned int length);
void DrawGlyphs(int x, int y, char* str, unsigned int length)
{ DrawGlyphs(default_text_gc, x, y, str, length); }
void DrawStringAligned(GC gc, char *string, unsigned int length,
int x, int y, Dimension width, Dimension height,
unsigned char alignment = XmALIGNMENT_CENTER,
Dimension offset = 0);
void DrawStringAligned(char *string, unsigned int length, int x, int y,
Dimension width, Dimension height,
unsigned char alignment = XmALIGNMENT_CENTER,
Dimension offset = 0)
{ DrawStringAligned(default_text_gc, string, length,
x, y, width, height,
alignment, offset); }
- The drawing functions for GnView now use the view's true foreground and
background colors instead of black & white. These colors are accessible
by the members foreground and background.
- The default font of GnView may be accessed by the members
protected: // Fonts
char *font_name;
Font font;
XFontStruct *font_info;
These members are undefined before the first expose event has been received.
They are always defined when GINA++ calls the view's draw() function.
- Two graphics contexts for string drawing operations were added for GnView.
protected: // graphics contexts
GC default_text_gc;
GC text_gc;
The default_text_gc is private to GINA++, The text_gc may be used by the
programmer.
These members are undefined before the first expose event has been received.
They are always defined when GINA++ calls the view's draw() function.
These gcs are preset so the programmer can call any string drawing function
of GnView without setting them.
The string drawing functions are overloaded to use either the
default_text_gc or they may be called with an explicit gc.
- The funtion GnWidget::IsManaged() has been added.
- The functions GnWidget::Realize(), GnWidget::Manage() and
GnWidget::Unmanage() were added.
They are a replacement for the the functions GnWidget::realize(),
GnWidget::manage() and GnWidget::unmanage(), which will become obsolete
in the future !
- Class GnSelection: The functions AllItems(), SelectedItems(),
UnselectedItems(), SensitiveItems(), and InsensitiveItems() have been
implemented. They now return lists of objects (GnObjectList *).
These lists are temporary and must be deleted by the programmer.
- The destructor for linked lists has been implemented.
- The function GnSelection::IsSelected() now works.
- One reason for application hangup when document read errors occur has been
fixed. However, applications may still hang after read errors.
- The class GnTopLevelToolDialogBox has been added. It is similar to the class
GnToolDialogBox, with the following exceptions:
+ It is separately iconifyable
+ Children can not be added directly, instead the expression
tool_dialog->GetForm() must be used for the 'parent' argument.
In subclasses, this form widget could also be accessed by this->main_form.
Because the menu bar is also a child of this form widget, further
children must be attached to the menu bar. Otherwise they might overlap
with the menu bar, possibly making it invisible. Example:
button->setR_topAttachment(XmATTACH_WIDGET);
button->setR_topWidget(tool_dialog->GetForm()); // or, for subclasses:
button->setR_topWidget(main_form);
+ It is a subclass of GnTopLevelShell, whereas GnToolDialogBox is a
subclass of GnDialogShell. Therefore, the GnTopLevelShell resources must
be used (e.g. setR_title() instead of setR_dialogTitle()).
A demo program can be found in ./sample/ibtestappl.C