Back to index

plt-scheme  4.2.1
Defines | Functions | Variables
xwLabel.c File Reference
#include <X11/IntrinsicP.h>
#include <X11/StringDefs.h>
#include <stdio.h>
#include <xwTabString.h>
#include <./xwLabelP.h>

Go to the source code of this file.

Defines

#define draw_line(dpy, win, from, to, reg)

Functions

static void _resolve_inheritance ()
static void set_label ()
static Boolean set_values ()
static void initialize ()
static void destroy ()
static void realize ()
static void _expose ()
static void make_gc ()
static void make_graygc ()
static void count_lines ()
static void make_gc (Widget self)
static void make_graygc (Widget self)
static void count_lines (Widget self)
static void _resolve_inheritance (WidgetClass class)
static void set_label (Widget self, String newlabel)
static Boolean set_values (Widget old, Widget request, Widget self, ArgList args, Cardinal *num_args)
static void initialize (Widget request, Widget self, ArgList args, Cardinal *num_args)
static void destroy (Widget self)
static void realize (Widget self, XtValueMask *mask, XSetWindowAttributes *attributes)
static void _expose (Widget self, XEvent *event, Region region)

Variables

static XtResource resources []
XfwfLabelClassRec xfwfLabelClassRec
WidgetClass xfwfLabelWidgetClass = (WidgetClass) &xfwfLabelClassRec

Define Documentation

#define draw_line (   dpy,
  win,
  from,
  to,
  reg 
)
Value:
do {\
       w1 = XfwfTextWidth(dpy, ((XfwfLabelWidget)self)->xfwfLabel.font, (wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont, ((XfwfLabelWidget)self)->xfwfLabel.label + from, to - from, ((XfwfLabelWidget)self)->xfwfLabel.tabs);\
       if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfLeft)\
           x = rect.x;\
       else if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfRight)\
           x = rect.x + rect.width - w1;\
       else\
           x = rect.x + (rect.width - w1)/2;\
       if (w1) {\
         int grayed;\
         grayed = ((!((XfwfLabelWidget)self)->core.sensitive || ((XfwfLabelWidget)self)->xfwfLabel.drawgray) && wx_enough_colors(XtScreen(self)));\
         XfwfDrawImageString(dpy, win, \
                           (((XfwfLabelWidget)self)->xfwfLabel.xfont\
                            ? ((XfwfLabelWidget)self)->xfwfLabel.gc\
                            : (grayed\
                              ? ((XfwfLabelWidget)self)->xfwfLabel.graygc \
                              : ((XfwfLabelWidget)self)->xfwfLabel.gc)), \
                           x, y, ((XfwfLabelWidget)self)->xfwfLabel.label + from,\
                           to - from, ((XfwfLabelWidget)self)->xfwfLabel.tabs, ((XfwfLabelWidget)self)->xfwfLabel.font,\
                           (wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont, !grayed, reg);\
       }\
    }while (0 )

Definition at line 397 of file xwLabel.c.


Function Documentation

static void _expose ( ) [static]
static void _expose ( Widget  self,
XEvent *  event,
Region  region 
) [static]

Definition at line 425 of file xwLabel.c.

{
    Region reg;
    XRectangle rect;
    int baseline;
    int w1;
    int x, y, i, j;

    if (! XtIsRealized(self)) return;

    if (!((XfwfLabelWidget)self)->core.sensitive || ((XfwfLabelWidget)self)->xfwfLabel.drawgray)
      if (!((XfwfLabelWidget)self)->xfwfLabel.graygc) make_graygc(self);

    xfwfBoardClassRec.xfwfCommon_class._expose(self, event, region);
    reg = NULL;
    if (((XfwfLabelWidget)self)->xfwfLabel.label != NULL || ((XfwfLabelWidget)self)->xfwfLabel.pixmap != 0) {
       int w, h;
       ((XfwfLabelWidgetClass)self->core.widget_class)->xfwfCommon_class.compute_inside(self, &rect.x, &rect.y, &w, &h);
       rect.x += ((XfwfLabelWidget)self)->xfwfLabel.leftMargin;  w -= ((XfwfLabelWidget)self)->xfwfLabel.leftMargin + ((XfwfLabelWidget)self)->xfwfLabel.rightMargin;
       rect.y += ((XfwfLabelWidget)self)->xfwfLabel.topMargin;  h -= ((XfwfLabelWidget)self)->xfwfLabel.topMargin + ((XfwfLabelWidget)self)->xfwfLabel.bottomMargin;
       rect.width = max(0, w);
       rect.height = max(0, h);
       reg = XCreateRegion();
       XUnionRectWithRegion(&rect, reg, reg);
       if (region != NULL) XIntersectRegion(region, reg, reg);
       XSetRegion(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.gc, reg);
    }
    if (((XfwfLabelWidget)self)->xfwfLabel.label != NULL) {
        int ascent;
       ascent = wx_ASCENT(((XfwfLabelWidget)self)->xfwfLabel.font, ((wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont));
       baseline = ascent + wx_DESCENT(((XfwfLabelWidget)self)->xfwfLabel.font, ((wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont));
       if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfTop)
           y = rect.y + ascent;
       else if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfBottom)
           y = rect.y + rect.height - ((XfwfLabelWidget)self)->xfwfLabel.nlines * baseline + ascent;
       else
           y = rect.y + (rect.height - ((XfwfLabelWidget)self)->xfwfLabel.nlines * baseline)/2 + ascent;
       for (i = 0, j = 0; ((XfwfLabelWidget)self)->xfwfLabel.label[i]; i++) {
           if (((XfwfLabelWidget)self)->xfwfLabel.label[i] == '\n') {
              draw_line(XtDisplay(self), XtWindow(self), j, i, reg);
              j = i + 1;
              y += baseline;
           }
       }
       draw_line(XtDisplay(self), XtWindow(self), j, i, reg);

       /* Gray out if not sensitive */
       if (! ((XfwfLabelWidget)self)->core.sensitive || ((XfwfLabelWidget)self)->xfwfLabel.drawgray) {
         if (!wx_enough_colors(XtScreen(self))) {
           XSetRegion(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.graygc, reg);
           XFillRectangle(XtDisplay(self), XtWindow(self), ((XfwfLabelWidget)self)->xfwfLabel.graygc, rect.x,
                        rect.y, rect.width, rect.height);
           XSetClipMask(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.graygc, None);
         }
       }
    } else if (((XfwfLabelWidget)self)->xfwfLabel.pixmap != 0) {
       Dimension width = ((XfwfLabelWidget)self)->xfwfLabel.label_width - ((XfwfLabelWidget)self)->xfwfLabel.leftMargin - ((XfwfLabelWidget)self)->xfwfLabel.rightMargin;
       Dimension height = ((XfwfLabelWidget)self)->xfwfLabel.label_height - ((XfwfLabelWidget)self)->xfwfLabel.topMargin - ((XfwfLabelWidget)self)->xfwfLabel.bottomMargin;
       if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfTop)
           y = rect.y;
       else if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfBottom)
           y = rect.y + rect.height - height;
       else
           y = rect.y + (rect.height - height)/2;
       if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfLeft)
           x = rect.x;
       else if (((XfwfLabelWidget)self)->xfwfLabel.alignment & XfwfRight)
           x = rect.x + rect.width - width;
       else
           x = rect.x + (rect.width - width)/2;

       wxDrawBitmapLabel(XtDisplay(self), 
                       ((XfwfLabelWidget)self)->xfwfLabel.pixmap, ((XfwfLabelWidget)self)->xfwfLabel.maskmap, 
                       XtWindow(self), ((XfwfLabelWidget)self)->xfwfLabel.gc,
                       x, y, width, height, 
                       ((XfwfLabelWidget)self)->xfwfLabel.label_depth, ((XfwfLabelWidget)self)->xfwfLabel.mask_depth,
                       reg, 
                       (! ((XfwfLabelWidget)self)->core.sensitive || ((XfwfLabelWidget)self)->xfwfLabel.drawgray) ? ((XfwfLabelWidget)self)->xfwfLabel.graygc : 0,
                       ((XfwfLabelWidget)self)->core.background_pixel);
    }

    if (((XfwfLabelWidget)self)->xfwfLabel.label != NULL || ((XfwfLabelWidget)self)->xfwfLabel.pixmap != 0) {
      XSetClipMask(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.gc, None);
    }
    if (reg) XDestroyRegion(reg);
}

Here is the call graph for this function:

static void _resolve_inheritance ( ) [static]
static void _resolve_inheritance ( WidgetClass  class) [static]

Definition at line 253 of file xwLabel.c.

{
  XfwfLabelWidgetClass c = (XfwfLabelWidgetClass) class;
  XfwfLabelWidgetClass super;
  static CompositeClassExtensionRec extension_rec = {
    NULL, NULLQUARK, XtCompositeExtensionVersion,
    sizeof(CompositeClassExtensionRec), True};
  CompositeClassExtensionRec *ext;
  ext = (XtPointer)XtMalloc(sizeof(*ext));
  *ext = extension_rec;
  ext->next_extension = c->composite_class.extension;
  c->composite_class.extension = ext;
  if (class == xfwfLabelWidgetClass) return;
  super = (XfwfLabelWidgetClass)class->core_class.superclass;
  if (c->xfwfLabel_class.set_label == XtInherit_set_label)
    c->xfwfLabel_class.set_label = super->xfwfLabel_class.set_label;
}

Here is the call graph for this function:

static void count_lines ( ) [static]

Here is the caller graph for this function:

static void count_lines ( Widget  self) [static]

Definition at line 123 of file xwLabel.c.

{
    String p, s;
    int w;

    ((XfwfLabelWidget)self)->xfwfLabel.nlines = 0;
    ((XfwfLabelWidget)self)->xfwfLabel.label_width = 0; ((XfwfLabelWidget)self)->xfwfLabel.label_height = 0; ((XfwfLabelWidget)self)->xfwfLabel.label_depth = 0;
    if (((XfwfLabelWidget)self)->xfwfLabel.label) {
       for (p = ((XfwfLabelWidget)self)->xfwfLabel.label, ((XfwfLabelWidget)self)->xfwfLabel.nlines = 1, s = ((XfwfLabelWidget)self)->xfwfLabel.label; *s; s++) {
           if (*s == '\n') {
              ((XfwfLabelWidget)self)->xfwfLabel.nlines++;
              w = XfwfTextWidth(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.font, (wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont, p, s - p, ((XfwfLabelWidget)self)->xfwfLabel.tabs);
              p = s + 1;
              if (w > ((XfwfLabelWidget)self)->xfwfLabel.label_width) ((XfwfLabelWidget)self)->xfwfLabel.label_width = w;
           }
       }
       w = XfwfTextWidth(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.font, (wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont, p, s - p, ((XfwfLabelWidget)self)->xfwfLabel.tabs);
       if (w > ((XfwfLabelWidget)self)->xfwfLabel.label_width) ((XfwfLabelWidget)self)->xfwfLabel.label_width = w;
       ((XfwfLabelWidget)self)->xfwfLabel.label_height = ((XfwfLabelWidget)self)->xfwfLabel.nlines * (wx_ASCENT(((XfwfLabelWidget)self)->xfwfLabel.font, ((wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont)) + wx_DESCENT(((XfwfLabelWidget)self)->xfwfLabel.font, ((wxExtFont)((XfwfLabelWidget)self)->xfwfLabel.xfont)));
    } else if (((XfwfLabelWidget)self)->xfwfLabel.pixmap) {
       Window        root;
       int           x, y;
       unsigned int  width, height, bw, depth;
       XGetGeometry(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.pixmap, &root,
                    &x, &y, &width, &height, &bw, &depth);
       ((XfwfLabelWidget)self)->xfwfLabel.label_width  = (Dimension)width;
       ((XfwfLabelWidget)self)->xfwfLabel.label_height = (Dimension)height;
       ((XfwfLabelWidget)self)->xfwfLabel.label_depth  = depth;
       if (((XfwfLabelWidget)self)->xfwfLabel.maskmap) {
         XGetGeometry(XtDisplay(self), ((XfwfLabelWidget)self)->xfwfLabel.maskmap, &root,
                     &x, &y, &width, &height, &bw, &depth);
         ((XfwfLabelWidget)self)->xfwfLabel.mask_depth  = depth;
       }
    }
    /* add border */
    ((XfwfLabelWidget)self)->xfwfLabel.label_width += ((XfwfLabelWidget)self)->xfwfLabel.leftMargin + ((XfwfLabelWidget)self)->xfwfLabel.rightMargin;
    ((XfwfLabelWidget)self)->xfwfLabel.label_height += ((XfwfLabelWidget)self)->xfwfLabel.topMargin + ((XfwfLabelWidget)self)->xfwfLabel.bottomMargin;
}

Here is the call graph for this function:

static void destroy ( ) [static]
static void destroy ( Widget  self) [static]

Definition at line 380 of file xwLabel.c.

{
  if (((XfwfLabelWidget)self)->xfwfLabel.gc) XtReleaseGC(self, ((XfwfLabelWidget)self)->xfwfLabel.gc); ((XfwfLabelWidget)self)->xfwfLabel.gc = NULL;
  if (((XfwfLabelWidget)self)->xfwfLabel.graygc) XtReleaseGC(self, ((XfwfLabelWidget)self)->xfwfLabel.graygc); ((XfwfLabelWidget)self)->xfwfLabel.graygc = NULL;
}
static void initialize ( ) [static]
static void initialize ( Widget  request,
Widget  self,
ArgList  args,
Cardinal *  num_args 
) [static]

Definition at line 356 of file xwLabel.c.

{
    Position x, y;
    int w, h, wd, ht;

    if (((XfwfLabelWidget)self)->xfwfLabel.label) ((XfwfLabelWidget)self)->xfwfLabel.label = XtNewString(((XfwfLabelWidget)self)->xfwfLabel.label);
    count_lines(self);
    ((XfwfLabelWidget)self)->xfwfLabel.gc = NULL;
    ((XfwfLabelWidget)self)->xfwfLabel.graygc = NULL;
    ((XfwfLabelWidget)self)->xfwfLabel.tabs = XfwfTablist2Tabs(((XfwfLabelWidget)self)->xfwfLabel.tablist);
    if (!((XfwfLabelWidget)self)->xfwfLabel.text_bg)
      ((XfwfLabelWidget)self)->xfwfLabel.text_bg = ((XfwfLabelWidget)self)->core.background_pixel;
    if (((XfwfLabelWidget)self)->xfwfLabel.shrinkToFit) {
       ((XfwfLabelWidgetClass)self->core.widget_class)->xfwfCommon_class.compute_inside(self, &x, &y, &w, &h);
       wd = ((XfwfLabelWidget)self)->xfwfLabel.label_width + ((XfwfLabelWidget)self)->core.width - w;
       ht = ((XfwfLabelWidget)self)->xfwfLabel.label_height + ((XfwfLabelWidget)self)->core.height - h;
       ((XfwfLabelWidgetClass)self->core.widget_class)->xfwfBoard_class.set_abs_location(self, CWWidth | CWHeight, 0, 0, max(1, wd), max(1, ht));
    }
}

Here is the call graph for this function:

static void make_gc ( ) [static]

Here is the caller graph for this function:

static void make_gc ( Widget  self) [static]

Definition at line 63 of file xwLabel.c.

{
    XtGCMask mask, fnt = 0;
    XGCValues values;

    if (((XfwfLabelWidget)self)->xfwfLabel.gc != NULL) XtReleaseGC(self, ((XfwfLabelWidget)self)->xfwfLabel.gc);
    values.background = ((XfwfLabelWidget)self)->xfwfLabel.text_bg;
    if (!((XfwfLabelWidget)self)->xfwfLabel.xfont) {
      values.foreground = ((XfwfLabelWidget)self)->xfwfLabel.foreground;
      if (((XfwfLabelWidget)self)->xfwfLabel.font) {
        values.font = ((XfwfLabelWidget)self)->xfwfLabel.font->fid;
        fnt = GCFont;
      }
    } else {
      if (((XfwfLabelWidget)self)->xfwfLabel.pixmap)
       values.foreground = ((XfwfLabelWidget)self)->xfwfLabel.foreground;
      else
       values.foreground = values.background;
    }
    mask = fnt | GCBackground | GCForeground;
    ((XfwfLabelWidget)self)->xfwfLabel.gc = XtGetGC(self, mask, &values);
}
static void make_graygc ( ) [static]
static void make_graygc ( Widget  self) [static]

Definition at line 90 of file xwLabel.c.

{
    XtGCMask mask;
    XGCValues values;

    if (((XfwfLabelWidget)self)->xfwfLabel.graygc != NULL) XtReleaseGC(self, ((XfwfLabelWidget)self)->xfwfLabel.graygc);

    if ((((XfwfLabelWidget)self)->xfwfLabel.pixmap != 0) || !wx_enough_colors(XtScreen(self))) {
      /* A GC to draw over bitmaps/text: */
      values.foreground = ((XfwfLabelWidget)self)->xfwfLabel.text_bg;
      values.stipple = GetGray(self);
      values.fill_style = FillStippled;
      mask = GCForeground | GCStipple | GCFillStyle;
    } else {
      /* A GC for drawing gray text: */
      static Pixel color;
      values.background = ((XfwfLabelWidget)self)->xfwfLabel.text_bg;
      ((XfwfLabelWidgetClass)self->core.widget_class)->xfwfCommon_class.darker_color(self, ((XfwfLabelWidget)self)->xfwfLabel.text_bg, &color);
      values.foreground = color;
      mask = GCBackground | GCForeground;
      if (((XfwfLabelWidget)self)->xfwfLabel.font) {
       values.font = ((XfwfLabelWidget)self)->xfwfLabel.font->fid;
       mask |= GCFont;
      }
    }
 
    ((XfwfLabelWidget)self)->xfwfLabel.graygc = XtGetGC(self, mask, &values);
}

Here is the call graph for this function:

static void realize ( ) [static]
static void realize ( Widget  self,
XtValueMask *  mask,
XSetWindowAttributes *  attributes 
) [static]

Definition at line 390 of file xwLabel.c.

{
  xfwfBoardClassRec.core_class.realize(self, mask, attributes);
  make_gc(self);
  /* make_graygc($); - now on demand */
}

Here is the call graph for this function:

static void set_label ( ) [static]

Here is the caller graph for this function:

static void set_label ( Widget  self,
String  newlabel 
) [static]

Definition at line 275 of file xwLabel.c.

{
    Position x, y;
    int w, h;

    XtFree(((XfwfLabelWidget)self)->xfwfLabel.label);
    ((XfwfLabelWidget)self)->xfwfLabel.label = XtNewString(newlabel);
    count_lines(self);
    if (XtIsRealized(self)) {
       ((XfwfLabelWidgetClass)self->core.widget_class)->xfwfCommon_class.compute_inside(self, &x, &y, &w, &h);
       XClearArea(XtDisplay(self), XtWindow(self), x, y, max(w, 0), max(h, 0), True);
       /* $_expose($, NULL, NULL); */
    }
}

Here is the call graph for this function:

static Boolean set_values ( ) [static]
static Boolean set_values ( Widget  old,
Widget  request,
Widget  self,
ArgList  args,
Cardinal *  num_args 
) [static]

Definition at line 294 of file xwLabel.c.

{
    Boolean need_redisplay = False, need_count = False;
    Position x, y;

    if (((XfwfLabelWidget)self)->core.background_pixel != ((XfwfLabelWidget)old)->core.background_pixel)
       if (((XfwfLabelWidget)self)->xfwfLabel.graygc) make_graygc(self);

    if (((XfwfLabelWidget)self)->xfwfLabel.tablist != ((XfwfLabelWidget)old)->xfwfLabel.tablist) {
       XtFree((String) ((XfwfLabelWidget)old)->xfwfLabel.tabs);
       ((XfwfLabelWidget)self)->xfwfLabel.tabs = XfwfTablist2Tabs(((XfwfLabelWidget)self)->xfwfLabel.tablist);
       if (((XfwfLabelWidget)self)->xfwfLabel.label != NULL) need_count = True;
    }

    if ((((XfwfLabelWidget)self)->xfwfLabel.font != ((XfwfLabelWidget)old)->xfwfLabel.font)
       || (((XfwfLabelWidget)self)->xfwfLabel.xfont != ((XfwfLabelWidget)old)->xfwfLabel.xfont)) {
       make_gc(self);
       if (((XfwfLabelWidget)self)->xfwfLabel.label != NULL) need_count = True;
    }
    if (((XfwfLabelWidget)self)->xfwfLabel.foreground != ((XfwfLabelWidget)old)->xfwfLabel.foreground
       || ((XfwfLabelWidget)self)->core.background_pixel != ((XfwfLabelWidget)old)->core.background_pixel) {
       make_gc(self);
       if (((XfwfLabelWidget)self)->xfwfLabel.label != NULL || ((XfwfLabelWidget)self)->xfwfLabel.pixmap != 0) need_redisplay = True;
    }
    if (((XfwfLabelWidget)self)->xfwfLabel.topMargin != ((XfwfLabelWidget)old)->xfwfLabel.topMargin
       || ((XfwfLabelWidget)self)->xfwfLabel.bottomMargin != ((XfwfLabelWidget)old)->xfwfLabel.bottomMargin
       || ((XfwfLabelWidget)self)->xfwfLabel.leftMargin != ((XfwfLabelWidget)old)->xfwfLabel.leftMargin
       || ((XfwfLabelWidget)self)->xfwfLabel.rightMargin != ((XfwfLabelWidget)old)->xfwfLabel.rightMargin
       || ((XfwfLabelWidget)self)->xfwfLabel.alignment != ((XfwfLabelWidget)old)->xfwfLabel.alignment)
       need_count = True;

    if ((((XfwfLabelWidget)self)->core.sensitive != ((XfwfLabelWidget)old)->core.sensitive)
        || (((XfwfLabelWidget)self)->xfwfLabel.drawgray != ((XfwfLabelWidget)old)->xfwfLabel.drawgray))
       if (((XfwfLabelWidget)self)->xfwfLabel.label != NULL || ((XfwfLabelWidget)self)->xfwfLabel.pixmap != 0) need_redisplay = True;

    if (((XfwfLabelWidget)self)->xfwfLabel.label != ((XfwfLabelWidget)old)->xfwfLabel.label || ((XfwfLabelWidget)self)->xfwfLabel.pixmap != ((XfwfLabelWidget)old)->xfwfLabel.pixmap) {
       XtFree(((XfwfLabelWidget)old)->xfwfLabel.label);
       ((XfwfLabelWidget)self)->xfwfLabel.label = XtNewString(((XfwfLabelWidget)self)->xfwfLabel.label);
       need_count = True;
    }
    if (need_count) {
       count_lines(self);
       need_redisplay = True;
    }
    if (need_count && ((XfwfLabelWidget)self)->xfwfLabel.shrinkToFit) {
        int w, h, wd, ht;
       ((XfwfLabelWidgetClass)self->core.widget_class)->xfwfCommon_class.compute_inside(self, &x, &y, &w, &h);
       wd = ((XfwfLabelWidget)self)->xfwfLabel.label_width + ((XfwfLabelWidget)self)->core.width - w;
       ht = ((XfwfLabelWidget)self)->xfwfLabel.label_height + ((XfwfLabelWidget)self)->core.height - h;
       if (wd != ((XfwfLabelWidget)self)->core.width || ht != ((XfwfLabelWidget)self)->core.height) {
           ((XfwfLabelWidgetClass)self->core.widget_class)->xfwfBoard_class.set_abs_location(self, CWWidth | CWHeight, 0, 0, max(1, wd), max(1, ht));
           need_redisplay = True;
       }
    }

    return need_redisplay;
}

Here is the call graph for this function:


Variable Documentation

XtResource resources[] [static]
Initial value:
 {
{XtNlabel,XtCLabel,XtRString,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.label),XtOffsetOf(XfwfLabelRec,xfwfLabel.label),XtRImmediate,(XtPointer)NULL },
{XtNtablist,XtCTablist,XtRString,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.tablist),XtOffsetOf(XfwfLabelRec,xfwfLabel.tablist),XtRImmediate,(XtPointer)NULL },
{XtNfont,XtCFont,XtRFontStruct,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.font),XtOffsetOf(XfwfLabelRec,xfwfLabel.font),XtRString,(XtPointer)XtDefaultFont },
{XtNxfont,XtCXFont,XtRvoid,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.xfont),XtOffsetOf(XfwfLabelRec,xfwfLabel.xfont),XtRPointer,(XtPointer)NULL },
{XtNpixmap,XtCPixmap,XtRPixmap,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.pixmap),XtOffsetOf(XfwfLabelRec,xfwfLabel.pixmap),XtRImmediate,(XtPointer)0 },
{XtNmaskmap,XtCMaskmap,XtRPixmap,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.maskmap),XtOffsetOf(XfwfLabelRec,xfwfLabel.maskmap),XtRImmediate,(XtPointer)0 },
{XtNforeground,XtCForeground,XtRPixel,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.foreground),XtOffsetOf(XfwfLabelRec,xfwfLabel.foreground),XtRString,(XtPointer)XtDefaultForeground },
{XtNtext_bg,XtCText_bg,XtRPixel,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.text_bg),XtOffsetOf(XfwfLabelRec,xfwfLabel.text_bg),XtRPointer,(XtPointer)NULL },
{XtNalignment,XtCAlignment,XtRAlignment,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.alignment),XtOffsetOf(XfwfLabelRec,xfwfLabel.alignment),XtRImmediate,(XtPointer)0 },
{XtNtopMargin,XtCTopMargin,XtRDimension,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.topMargin),XtOffsetOf(XfwfLabelRec,xfwfLabel.topMargin),XtRImmediate,(XtPointer)2 },
{XtNbottomMargin,XtCBottomMargin,XtRDimension,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.bottomMargin),XtOffsetOf(XfwfLabelRec,xfwfLabel.bottomMargin),XtRImmediate,(XtPointer)2 },
{XtNleftMargin,XtCLeftMargin,XtRDimension,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.leftMargin),XtOffsetOf(XfwfLabelRec,xfwfLabel.leftMargin),XtRImmediate,(XtPointer)2 },
{XtNrightMargin,XtCRightMargin,XtRDimension,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.rightMargin),XtOffsetOf(XfwfLabelRec,xfwfLabel.rightMargin),XtRImmediate,(XtPointer)2 },
{XtNshrinkToFit,XtCShrinkToFit,XtRBoolean,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.shrinkToFit),XtOffsetOf(XfwfLabelRec,xfwfLabel.shrinkToFit),XtRImmediate,(XtPointer)False },
{XtNrvStart,XtCRvStart,XtRInt,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.rvStart),XtOffsetOf(XfwfLabelRec,xfwfLabel.rvStart),XtRImmediate,(XtPointer)0 },
{XtNrvLength,XtCRvLength,XtRInt,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.rvLength),XtOffsetOf(XfwfLabelRec,xfwfLabel.rvLength),XtRImmediate,(XtPointer)0 },
{XtNtraversalOn,XtCTraversalOn,XtRBoolean,sizeof(((XfwfLabelRec*)NULL)->xfwfCommon.traversalOn),XtOffsetOf(XfwfLabelRec,xfwfCommon.traversalOn),XtRImmediate,(XtPointer)False },
{XtNdrawgray,XtCDrawgray,XtRBoolean,sizeof(((XfwfLabelRec*)NULL)->xfwfLabel.drawgray),XtOffsetOf(XfwfLabelRec,xfwfLabel.drawgray),XtRImmediate,(XtPointer)FALSE },
}

Definition at line 163 of file xwLabel.c.

Definition at line 184 of file xwLabel.c.

WidgetClass xfwfLabelWidgetClass = (WidgetClass) &xfwfLabelClassRec

Definition at line 252 of file xwLabel.c.