summaryrefslogtreecommitdiffstats
path: root/generic/tkMenu.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tkMenu.c')
-rw-r--r--generic/tkMenu.c114
1 files changed, 57 insertions, 57 deletions
diff --git a/generic/tkMenu.c b/generic/tkMenu.c
index a8119d6..8da4cb7 100644
--- a/generic/tkMenu.c
+++ b/generic/tkMenu.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkMenu.c,v 1.57 2010/01/13 23:08:09 nijtmans Exp $
+ * RCS: @(#) $Id: tkMenu.c,v 1.58 2010/01/18 20:43:38 nijtmans Exp $
*/
/*
@@ -117,118 +117,118 @@ static const char *const compoundStrings[] = {
static const Tk_OptionSpec tkBasicMenuEntryConfigSpecs[] = {
{TK_OPTION_BORDER, "-activebackground", NULL, NULL,
DEF_MENU_ENTRY_ACTIVE_BG, Tk_Offset(TkMenuEntry, activeBorderPtr), -1,
- TK_OPTION_NULL_OK},
+ TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_COLOR, "-activeforeground", NULL, NULL,
DEF_MENU_ENTRY_ACTIVE_FG,
- Tk_Offset(TkMenuEntry, activeFgPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, activeFgPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-accelerator", NULL, NULL,
DEF_MENU_ENTRY_ACCELERATOR,
- Tk_Offset(TkMenuEntry, accelPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, accelPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_BORDER, "-background", NULL, NULL,
DEF_MENU_ENTRY_BG,
- Tk_Offset(TkMenuEntry, borderPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, borderPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_BITMAP, "-bitmap", NULL, NULL,
DEF_MENU_ENTRY_BITMAP,
- Tk_Offset(TkMenuEntry, bitmapPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, bitmapPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_BOOLEAN, "-columnbreak", NULL, NULL,
DEF_MENU_ENTRY_COLUMN_BREAK,
- -1, Tk_Offset(TkMenuEntry, columnBreak)},
+ -1, Tk_Offset(TkMenuEntry, columnBreak), 0, NULL, 0},
{TK_OPTION_STRING, "-command", NULL, NULL,
DEF_MENU_ENTRY_COMMAND,
- Tk_Offset(TkMenuEntry, commandPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, commandPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING_TABLE, "-compound", "compound", "Compound",
DEF_MENU_ENTRY_COMPOUND, -1, Tk_Offset(TkMenuEntry, compound), 0,
(ClientData) compoundStrings, 0},
{TK_OPTION_FONT, "-font", NULL, NULL,
DEF_MENU_ENTRY_FONT,
- Tk_Offset(TkMenuEntry, fontPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, fontPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_COLOR, "-foreground", NULL, NULL,
DEF_MENU_ENTRY_FG,
- Tk_Offset(TkMenuEntry, fgPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, fgPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_BOOLEAN, "-hidemargin", NULL, NULL,
DEF_MENU_ENTRY_HIDE_MARGIN,
- -1, Tk_Offset(TkMenuEntry, hideMargin)},
+ -1, Tk_Offset(TkMenuEntry, hideMargin), 0, NULL, 0},
{TK_OPTION_STRING, "-image", NULL, NULL,
DEF_MENU_ENTRY_IMAGE,
- Tk_Offset(TkMenuEntry, imagePtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, imagePtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-label", NULL, NULL,
DEF_MENU_ENTRY_LABEL,
- Tk_Offset(TkMenuEntry, labelPtr), -1, 0},
+ Tk_Offset(TkMenuEntry, labelPtr), -1, 0, NULL, 0},
{TK_OPTION_STRING_TABLE, "-state", NULL, NULL,
DEF_MENU_ENTRY_STATE,
-1, Tk_Offset(TkMenuEntry, state), 0,
- (ClientData) menuStateStrings},
+ (ClientData) menuStateStrings, 0},
{TK_OPTION_INT, "-underline", NULL, NULL,
- DEF_MENU_ENTRY_UNDERLINE, -1, Tk_Offset(TkMenuEntry, underline)},
- {TK_OPTION_END}
+ DEF_MENU_ENTRY_UNDERLINE, -1, Tk_Offset(TkMenuEntry, underline), 0, NULL, 0},
+ {TK_OPTION_END, NULL, NULL, NULL, 0, 0, 0, 0, NULL, 0}
};
static const Tk_OptionSpec tkSeparatorEntryConfigSpecs[] = {
{TK_OPTION_BORDER, "-background", NULL, NULL,
DEF_MENU_ENTRY_BG,
- Tk_Offset(TkMenuEntry, borderPtr), -1, TK_OPTION_NULL_OK},
- {TK_OPTION_END}
+ Tk_Offset(TkMenuEntry, borderPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
+ {TK_OPTION_END, NULL, NULL, NULL, 0, 0, 0, 0, NULL, 0}
};
static const Tk_OptionSpec tkCheckButtonEntryConfigSpecs[] = {
{TK_OPTION_BOOLEAN, "-indicatoron", NULL, NULL,
DEF_MENU_ENTRY_INDICATOR,
- -1, Tk_Offset(TkMenuEntry, indicatorOn)},
+ -1, Tk_Offset(TkMenuEntry, indicatorOn), 0, NULL, 0},
{TK_OPTION_STRING, "-offvalue", NULL, NULL,
DEF_MENU_ENTRY_OFF_VALUE,
- Tk_Offset(TkMenuEntry, offValuePtr), -1},
+ Tk_Offset(TkMenuEntry, offValuePtr), -1, 0, NULL, 0},
{TK_OPTION_STRING, "-onvalue", NULL, NULL,
DEF_MENU_ENTRY_ON_VALUE,
- Tk_Offset(TkMenuEntry, onValuePtr), -1},
+ Tk_Offset(TkMenuEntry, onValuePtr), -1, 0, NULL, 0},
{TK_OPTION_COLOR, "-selectcolor", NULL, NULL,
DEF_MENU_ENTRY_SELECT,
- Tk_Offset(TkMenuEntry, indicatorFgPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, indicatorFgPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-selectimage", NULL, NULL,
DEF_MENU_ENTRY_SELECT_IMAGE,
- Tk_Offset(TkMenuEntry, selectImagePtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, selectImagePtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-variable", NULL, NULL,
DEF_MENU_ENTRY_CHECK_VARIABLE,
- Tk_Offset(TkMenuEntry, namePtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, namePtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_END, NULL, NULL, NULL,
- NULL, 0, -1, 0, (ClientData) tkBasicMenuEntryConfigSpecs}
+ NULL, 0, -1, 0, (ClientData) tkBasicMenuEntryConfigSpecs, 0}
};
static const Tk_OptionSpec tkRadioButtonEntryConfigSpecs[] = {
{TK_OPTION_BOOLEAN, "-indicatoron", NULL, NULL,
DEF_MENU_ENTRY_INDICATOR,
- -1, Tk_Offset(TkMenuEntry, indicatorOn)},
+ -1, Tk_Offset(TkMenuEntry, indicatorOn), 0, NULL, 0},
{TK_OPTION_COLOR, "-selectcolor", NULL, NULL,
DEF_MENU_ENTRY_SELECT,
- Tk_Offset(TkMenuEntry, indicatorFgPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, indicatorFgPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-selectimage", NULL, NULL,
DEF_MENU_ENTRY_SELECT_IMAGE,
- Tk_Offset(TkMenuEntry, selectImagePtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, selectImagePtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-value", NULL, NULL,
DEF_MENU_ENTRY_VALUE,
- Tk_Offset(TkMenuEntry, onValuePtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, onValuePtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-variable", NULL, NULL,
DEF_MENU_ENTRY_RADIO_VARIABLE,
- Tk_Offset(TkMenuEntry, namePtr), -1, 0},
+ Tk_Offset(TkMenuEntry, namePtr), -1, 0, NULL, 0},
{TK_OPTION_END, NULL, NULL, NULL,
- NULL, 0, -1, 0, (ClientData) tkBasicMenuEntryConfigSpecs}
+ NULL, 0, -1, 0, (ClientData) tkBasicMenuEntryConfigSpecs, 0}
};
static const Tk_OptionSpec tkCascadeEntryConfigSpecs[] = {
{TK_OPTION_STRING, "-menu", NULL, NULL,
DEF_MENU_ENTRY_MENU,
- Tk_Offset(TkMenuEntry, namePtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, namePtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_END, NULL, NULL, NULL,
- NULL, 0, -1, 0, (ClientData) tkBasicMenuEntryConfigSpecs}
+ NULL, 0, -1, 0, (ClientData) tkBasicMenuEntryConfigSpecs, 0}
};
static const Tk_OptionSpec tkTearoffEntryConfigSpecs[] = {
{TK_OPTION_BORDER, "-background", NULL, NULL,
DEF_MENU_ENTRY_BG,
- Tk_Offset(TkMenuEntry, borderPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenuEntry, borderPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING_TABLE, "-state", NULL, NULL,
DEF_MENU_ENTRY_STATE, -1, Tk_Offset(TkMenuEntry, state), 0,
- (ClientData) menuStateStrings},
- {TK_OPTION_END}
+ (ClientData) menuStateStrings, 0},
+ {TK_OPTION_END, NULL, NULL, NULL, 0, 0, 0, 0, NULL, 0}
};
static const Tk_OptionSpec *specsArray[] = {
@@ -249,60 +249,60 @@ static const Tk_OptionSpec tkMenuConfigSpecs[] = {
{TK_OPTION_BORDER, "-activebackground", "activeBackground",
"Foreground", DEF_MENU_ACTIVE_BG_COLOR,
Tk_Offset(TkMenu, activeBorderPtr), -1, 0,
- (ClientData) DEF_MENU_ACTIVE_BG_MONO},
+ (ClientData) DEF_MENU_ACTIVE_BG_MONO, 0},
{TK_OPTION_PIXELS, "-activeborderwidth", "activeBorderWidth",
"BorderWidth", DEF_MENU_ACTIVE_BORDER_WIDTH,
- Tk_Offset(TkMenu, activeBorderWidthPtr), -1},
+ Tk_Offset(TkMenu, activeBorderWidthPtr), -1, 0, NULL, 0},
{TK_OPTION_COLOR, "-activeforeground", "activeForeground",
"Background", DEF_MENU_ACTIVE_FG_COLOR,
Tk_Offset(TkMenu, activeFgPtr), -1, 0,
- (ClientData) DEF_MENU_ACTIVE_FG_MONO},
+ (ClientData) DEF_MENU_ACTIVE_FG_MONO, 0},
{TK_OPTION_BORDER, "-background", "background", "Background",
DEF_MENU_BG_COLOR, Tk_Offset(TkMenu, borderPtr), -1, 0,
- (ClientData) DEF_MENU_BG_MONO},
+ (ClientData) DEF_MENU_BG_MONO, 0},
{TK_OPTION_SYNONYM, "-bd", NULL, NULL,
- NULL, 0, -1, 0, (ClientData) "-borderwidth"},
+ NULL, 0, -1, 0, (ClientData) "-borderwidth", 0},
{TK_OPTION_SYNONYM, "-bg", NULL, NULL,
- NULL, 0, -1, 0, (ClientData) "-background"},
+ NULL, 0, -1, 0, (ClientData) "-background", 0},
{TK_OPTION_PIXELS, "-borderwidth", "borderWidth", "BorderWidth",
DEF_MENU_BORDER_WIDTH,
- Tk_Offset(TkMenu, borderWidthPtr), -1, 0},
+ Tk_Offset(TkMenu, borderWidthPtr), -1, 0, NULL, 0},
{TK_OPTION_CURSOR, "-cursor", "cursor", "Cursor",
DEF_MENU_CURSOR,
- Tk_Offset(TkMenu, cursorPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenu, cursorPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_COLOR, "-disabledforeground", "disabledForeground",
"DisabledForeground", DEF_MENU_DISABLED_FG_COLOR,
Tk_Offset(TkMenu, disabledFgPtr), -1, TK_OPTION_NULL_OK,
- (ClientData) DEF_MENU_DISABLED_FG_MONO},
+ (ClientData) DEF_MENU_DISABLED_FG_MONO, 0},
{TK_OPTION_SYNONYM, "-fg", NULL, NULL,
- NULL, 0, -1, 0, (ClientData) "-foreground"},
+ NULL, 0, -1, 0, (ClientData) "-foreground", 0},
{TK_OPTION_FONT, "-font", "font", "Font",
- DEF_MENU_FONT, Tk_Offset(TkMenu, fontPtr), -1},
+ DEF_MENU_FONT, Tk_Offset(TkMenu, fontPtr), -1, 0, NULL, 0},
{TK_OPTION_COLOR, "-foreground", "foreground", "Foreground",
- DEF_MENU_FG, Tk_Offset(TkMenu, fgPtr), -1},
+ DEF_MENU_FG, Tk_Offset(TkMenu, fgPtr), -1, 0, NULL, 0},
{TK_OPTION_STRING, "-postcommand", "postCommand", "Command",
DEF_MENU_POST_COMMAND,
- Tk_Offset(TkMenu, postCommandPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenu, postCommandPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_RELIEF, "-relief", "relief", "Relief",
- DEF_MENU_RELIEF, Tk_Offset(TkMenu, reliefPtr), -1},
+ DEF_MENU_RELIEF, Tk_Offset(TkMenu, reliefPtr), -1, 0, NULL, 0},
{TK_OPTION_COLOR, "-selectcolor", "selectColor", "Background",
DEF_MENU_SELECT_COLOR, Tk_Offset(TkMenu, indicatorFgPtr), -1, 0,
- (ClientData) DEF_MENU_SELECT_MONO},
+ (ClientData) DEF_MENU_SELECT_MONO, 0},
{TK_OPTION_STRING, "-takefocus", "takeFocus", "TakeFocus",
DEF_MENU_TAKE_FOCUS,
- Tk_Offset(TkMenu, takeFocusPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenu, takeFocusPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_BOOLEAN, "-tearoff", "tearOff", "TearOff",
- DEF_MENU_TEAROFF, -1, Tk_Offset(TkMenu, tearoff)},
+ DEF_MENU_TEAROFF, -1, Tk_Offset(TkMenu, tearoff), 0, NULL, 0},
{TK_OPTION_STRING, "-tearoffcommand", "tearOffCommand",
"TearOffCommand", DEF_MENU_TEAROFF_CMD,
- Tk_Offset(TkMenu, tearoffCommandPtr), -1, TK_OPTION_NULL_OK},
+ Tk_Offset(TkMenu, tearoffCommandPtr), -1, TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING, "-title", "title", "Title",
DEF_MENU_TITLE, Tk_Offset(TkMenu, titlePtr), -1,
- TK_OPTION_NULL_OK},
+ TK_OPTION_NULL_OK, NULL, 0},
{TK_OPTION_STRING_TABLE, "-type", "type", "Type",
DEF_MENU_TYPE, Tk_Offset(TkMenu, menuTypePtr), -1, TK_OPTION_NULL_OK,
- (ClientData) menuTypeStrings},
- {TK_OPTION_END}
+ (ClientData) menuTypeStrings, 0},
+ {TK_OPTION_END, NULL, NULL, NULL, 0, 0, 0, 0, NULL, 0}
};
/*