Mercurial > hg > xemacs-beta
comparison src/EmacsShell-sub.c @ 4521:383ab474a241
Fix docstring typo.
author | Stephen J. Turnbull <stephen@xemacs.org> |
---|---|
date | Tue, 28 Oct 2008 10:38:26 +0900 |
parents | 6830a3f39553 |
children | fc7067b7f407 |
comparison
equal
deleted
inserted
replaced
4520:279cadceaa13 | 4521:383ab474a241 |
---|---|
87 #include <X11/Shell.h> | 87 #include <X11/Shell.h> |
88 #include <X11/ShellP.h> | 88 #include <X11/ShellP.h> |
89 #include <X11/Vendor.h> | 89 #include <X11/Vendor.h> |
90 #include <X11/VendorP.h> | 90 #include <X11/VendorP.h> |
91 #include "EmacsShellP.h" | 91 #include "EmacsShellP.h" |
92 #include "../lwlib/xt-wrappers.h" | |
92 | 93 |
93 #define ABORT abort | 94 #define ABORT abort |
94 | 95 |
95 #if defined (DEFINE_TOP_LEVEL_EMACS_SHELL) | 96 #if defined (DEFINE_TOP_LEVEL_EMACS_SHELL) |
96 #define EMACS_SHELL_WIDGET TopLevelEmacsShellWidget | 97 #define EMACS_SHELL_WIDGET TopLevelEmacsShellWidget |
132 #define BIGSIZE ((Dimension)32767) | 133 #define BIGSIZE ((Dimension)32767) |
133 | 134 |
134 static XtResource resources[] = { | 135 static XtResource resources[] = { |
135 #define offset(field) XtOffset(EMACS_SHELL_WIDGET, emacs_shell.field) | 136 #define offset(field) XtOffset(EMACS_SHELL_WIDGET, emacs_shell.field) |
136 #define coreoffset(field) XtOffset(EMACS_SHELL_WIDGET, core.field) | 137 #define coreoffset(field) XtOffset(EMACS_SHELL_WIDGET, core.field) |
138 #define res(name,_class,member,size) \ | |
139 { (String) name, (String) _class, XtRInt, sizeof (int), \ | |
140 offset (member), XtRImmediate, (XtPointer)0 } | |
141 #define motifres(name,member) \ | |
142 { (String) name, XtCPosition, XtRPosition, sizeof (Position), \ | |
143 coreoffset (member), XtRImmediate, (XtPointer)BIGSIZE } | |
137 #ifdef LWLIB_USES_MOTIF | 144 #ifdef LWLIB_USES_MOTIF |
138 /* *** BOGOSITY^10! *** The Motif VendorShell fucks around with | 145 /* *** BOGOSITY^10! *** The Motif VendorShell fucks around with |
139 the default values for X and Y, for no obvious reason. This | 146 the default values for X and Y, for no obvious reason. This |
140 causes Shell to indicate that the defaults of (0,0) were | 147 causes Shell to indicate that the defaults of (0,0) were |
141 program-specified, instead of letting the WM do what it wants. */ | 148 program-specified, instead of letting the WM do what it wants. */ |
142 { XtNx, XtCPosition, | 149 motifres (XtNx, x), |
143 XtRPosition, sizeof (Position), | 150 motifres (XtNy, y), |
144 coreoffset (x), XtRImmediate, (XtPointer)BIGSIZE }, | 151 #endif |
145 { XtNy, XtCPosition, | 152 res (XtNwidthCells, XtCWidthCells, width_cells, 0), |
146 XtRPosition, sizeof (Position), | 153 res (XtNheightCells, XtCHeightCells, height_cells, 0), |
147 coreoffset (y), XtRImmediate, (XtPointer)BIGSIZE }, | 154 res (XtNminWidthCells, XtCMinWidthCells, min_width_cells, 0), |
148 #endif | 155 res (XtNminHeightCells, XtCMinHeightCells, min_height_cells, 0), |
149 { XtNwidthCells, XtCWidthCells, | 156 #undef offset |
150 XtRInt, sizeof (int), | 157 #undef coreoffset |
151 offset (width_cells), XtRImmediate, (XtPointer)0 }, | 158 #undef res |
152 { XtNheightCells, XtCHeightCells, | 159 #undef motifres |
153 XtRInt, sizeof (int), | |
154 offset (height_cells), XtRImmediate, (XtPointer)0 }, | |
155 { XtNminWidthCells, XtCMinWidthCells, | |
156 XtRInt, sizeof (int), | |
157 offset (min_width_cells), XtRImmediate, (XtPointer)0 }, | |
158 { XtNminHeightCells, XtCMinHeightCells, | |
159 XtRInt, sizeof (int), | |
160 offset (min_height_cells), XtRImmediate, (XtPointer)0 }, | |
161 }; | 160 }; |
162 | 161 |
163 static CompositeClassExtensionRec compositeClassExtRec = { | 162 static CompositeClassExtensionRec compositeClassExtRec = { |
164 NULL, | 163 NULL, |
165 NULLQUARK, | 164 NULLQUARK, |
257 printf (" text area size in cells: %d %d\n", w->emacs_shell.width_cells, | 256 printf (" text area size in cells: %d %d\n", w->emacs_shell.width_cells, |
258 w->emacs_shell.height_cells); | 257 w->emacs_shell.height_cells); |
259 printf (" base size set to: %d %d\n", base_width, base_height); | 258 printf (" base size set to: %d %d\n", base_width, base_height); |
260 fflush (stdout); | 259 fflush (stdout); |
261 #endif | 260 #endif |
262 XtSetArg(al [0], XtNbaseWidth, base_width); | 261 Xt_SET_ARG(al [0], XtNbaseWidth, base_width); |
263 XtSetArg(al [1], XtNbaseHeight, base_height); | 262 Xt_SET_ARG(al [1], XtNbaseHeight, base_height); |
264 XtSetArg(al [2], XtNminWidth, base_width + | 263 Xt_SET_ARG(al [2], XtNminWidth, base_width + |
265 cell_width * w->emacs_shell.min_width_cells); | 264 cell_width * w->emacs_shell.min_width_cells); |
266 XtSetArg(al [3], XtNminHeight, base_height + | 265 Xt_SET_ARG(al [3], XtNminHeight, base_height + |
267 cell_height * w->emacs_shell.min_height_cells); | 266 cell_height * w->emacs_shell.min_height_cells); |
268 XtSetValues ((Widget) w, al, 4); | 267 XtSetValues ((Widget) w, al, 4); |
269 } | 268 } |
270 | 269 |
271 static XtGeometryResult | 270 static XtGeometryResult |
272 SuperClassRootGeometryManager (Widget gw, | 271 SuperClassRootGeometryManager (Widget gw, |