- * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc. *
+ * Copyright 2020 Thomas E. Dickey *
+ * Copyright 1998-2012,2014 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
16, /* Nr. of chars high */
1, /* Nr. of chars wide */
16, /* Nr. of items high */
16, /* Nr. of chars high */
1, /* Nr. of chars wide */
16, /* Nr. of items high */
0, /* length of widest description */
1, /* length of mark */
1, /* length of one item */
0, /* length of widest description */
1, /* length of mark */
1, /* length of one item */
1, /* Spacing for columns */
1, /* Spacing for rows */
(char *)0, /* buffer used to store match chars */
1, /* Spacing for columns */
1, /* Spacing for rows */
(char *)0, /* buffer used to store match chars */
0, /* Top row of menu */
(chtype)A_REVERSE, /* Attribute for selection */
(chtype)A_NORMAL, /* Attribute for nonselection */
0, /* Top row of menu */
(chtype)A_REVERSE, /* Attribute for selection */
(chtype)A_NORMAL, /* Attribute for nonselection */
' ', /* Pad character */
(Menu_Hook)0, /* Menu init */
(Menu_Hook)0, /* Menu term */
' ', /* Pad character */
(Menu_Hook)0, /* Menu init */
(Menu_Hook)0, /* Menu term */
{ (char *)0, 0 }, /* name */
{ (char *)0, 0 }, /* description */
(MENU *)0, /* Pointer to parent menu */
{ (char *)0, 0 }, /* name */
{ (char *)0, 0 }, /* description */
(MENU *)0, /* Pointer to parent menu */
| Description : Calculates the maximum name and description lengths
| of the items connected to the menu
|
| Description : Calculates the maximum name and description lengths
| of the items connected to the menu
|
T(("ComputeMaximum_NameDesc_Lengths %d,%d", menu->namelen, menu->desclen));
}
/*---------------------------------------------------------------------------
T(("ComputeMaximum_NameDesc_Lengths %d,%d", menu->namelen, menu->desclen));
}
/*---------------------------------------------------------------------------
| Function : bool _nc_Connect_Items(MENU *menu, ITEM **items)
|
| Description : Connect the items in the item array to the menu.
| Function : bool _nc_Connect_Items(MENU *menu, ITEM **items)
|
| Description : Connect the items in the item array to the menu.
| Return Values : TRUE - successful connection
| FALSE - connection failed
+--------------------------------------------------------------------------*/
| Return Values : TRUE - successful connection
| FALSE - connection failed
+--------------------------------------------------------------------------*/
ComputeMaximum_NameDesc_Lengths(menu);
if ((menu->pattern = typeMalloc(char, (unsigned)(1 + menu->namelen))))
{
ComputeMaximum_NameDesc_Lengths(menu);
if ((menu->pattern = typeMalloc(char, (unsigned)(1 + menu->namelen))))
{
and inform about a reject connection */
ResetConnectionInfo(menu, items);
return (FALSE);
}
/*---------------------------------------------------------------------------
and inform about a reject connection */
ResetConnectionInfo(menu, items);
return (FALSE);
}
/*---------------------------------------------------------------------------
| Description : Disconnect the menus item array from the menu
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Disconnect the menus item array from the menu
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Calculate the number of columns for a TEXT.
|
| Return Values : the width
+--------------------------------------------------------------------------*/
| Description : Calculate the number of columns for a TEXT.
|
| Return Values : the width
+--------------------------------------------------------------------------*/
| Description : Calculate the length of an item and the width of the
| whole menu.
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Calculate the length of an item and the width of the
| whole menu.
|
| Return Values : -
+--------------------------------------------------------------------------*/
T(("_nc_CalculateItem_Length_and_Width columns %d, item %d, width %d",
menu->cols,
T(("_nc_CalculateItem_Length_and_Width columns %d, item %d, width %d",
menu->cols,
| Description : Statically calculate for every item its four neighbors.
| This depends on the orientation of the menu. This
| static approach simplifies navigation in the menu a lot.
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Statically calculate for every item its four neighbors.
| This depends on the orientation of the menu. This
| static approach simplifies navigation in the menu a lot.
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Update the window that is associated with the menu
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Update the window that is associated with the menu
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Redisplay the menu so that the given row becomes the
| top row and the given item becomes the new current
| item.
|
| Return Values : -
+--------------------------------------------------------------------------*/
| Description : Redisplay the menu so that the given row becomes the
| top row and the given item becomes the new current
| item.
|
| Return Values : -
+--------------------------------------------------------------------------*/