X-Git-Url: http://ncurses.scripts.mit.edu/?a=blobdiff_plain;f=menu%2Fm_pad.c;h=6c87992a59a32741bbf32183ffea7d098331192f;hb=04d942c3d98cf0a929c6afb17be8c10d4ae39af0;hp=79659aa233fbd82c3f4ce8e8ee974f49e8be57c4;hpb=fc79b49bd8a9c5e4db287514cdac46e1691cf48a;p=ncurses.git diff --git a/menu/m_pad.c b/menu/m_pad.c index 79659aa2..6c87992a 100644 --- a/menu/m_pad.c +++ b/menu/m_pad.c @@ -1,5 +1,6 @@ /**************************************************************************** - * Copyright (c) 1998-2003,2004 Free Software Foundation, Inc. * + * Copyright 2020 Thomas E. Dickey * + * Copyright 1998-2010,2012 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 * @@ -37,7 +38,7 @@ #include "menu.priv.h" -MODULE_ID("$Id: m_pad.c,v 1.11 2009/02/07 23:11:44 tom Exp $") +MODULE_ID("$Id: m_pad.c,v 1.15 2020/05/24 01:40:20 anonymous.maarten Exp $") /* Macro to redraw menu if it is posted and changed */ #define Refresh_Menu(menu) \ @@ -58,18 +59,18 @@ MODULE_ID("$Id: m_pad.c,v 1.11 2009/02/07 23:11:44 tom Exp $") | Return Values : E_OK - success | E_BAD_ARGUMENT - an invalid value has been passed +--------------------------------------------------------------------------*/ -NCURSES_EXPORT(int) +MENU_EXPORT(int) set_menu_pad(MENU * menu, int pad) { bool do_refresh = (menu != (MENU *) 0); - T((T_CALLED("set_menu_pad(%p,%d)"), menu, pad)); + T((T_CALLED("set_menu_pad(%p,%d)"), (void *)menu, pad)); if (!isprint(UChar(pad))) RETURN(E_BAD_ARGUMENT); Normalize_Menu(menu); - menu->pad = pad; + menu->pad = (unsigned char)pad; if (do_refresh) Refresh_Menu(menu); @@ -85,10 +86,10 @@ set_menu_pad(MENU * menu, int pad) | | Return Values : The pad character +--------------------------------------------------------------------------*/ -NCURSES_EXPORT(int) +MENU_EXPORT(int) menu_pad(const MENU * menu) { - T((T_CALLED("menu_pad(%p)"), menu)); + T((T_CALLED("menu_pad(%p)"), (const void *)menu)); returnCode(Normalize_Menu(menu)->pad); }