1
0
Fork 0
mirror of git://git.code.sf.net/p/cdesktopenv/code synced 2025-02-15 04:32:24 +00:00

DtWidget: remove register keyword

This commit is contained in:
Jon Trulson 2018-06-27 15:15:59 -06:00
parent b5a3c00671
commit 3b1316112a
7 changed files with 64 additions and 64 deletions

View file

@ -507,7 +507,7 @@ InsertChild(
XmManagerWidgetClass mc = (XmManagerWidgetClass)xmManagerWidgetClass; XmManagerWidgetClass mc = (XmManagerWidgetClass)xmManagerWidgetClass;
Dimension s_t = M_ShadowThickness (w); Dimension s_t = M_ShadowThickness (w);
Arg al[20]; /* arg list */ Arg al[20]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
XtWidgetProc insert_child; XtWidgetProc insert_child;
_DtProcessLock(); _DtProcessLock();
@ -628,7 +628,7 @@ GetSize(
Widget work_area = M_WorkArea (mgr), Widget work_area = M_WorkArea (mgr),
separator = M_Separator (mgr); separator = M_Separator (mgr);
Widget * button = M_Button (mgr); Widget * button = M_Button (mgr);
register int button_count = M_ButtonCount (mgr), int button_count = M_ButtonCount (mgr),
i; i;
Boolean min_btns = M_MinimizeButtons (mgr); Boolean min_btns = M_MinimizeButtons (mgr);
Dimension sep_h = 0, Dimension sep_h = 0,
@ -717,7 +717,7 @@ CreateChildren(
char button_name[100]; char button_name[100];
Arg al[20]; /* arg list */ Arg al[20]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
/* Compute position factors. /* Compute position factors.
*/ */

View file

@ -84,9 +84,9 @@ static DtEditorErrorCode LoadFile(
*/ */
static int static int
strcasecmp(s1, s2) strcasecmp(s1, s2)
register char *s1, *s2; char *s1, *s2;
{ {
register int c1, c2; int c1, c2;
while (*s1 && *s2) { while (*s1 && *s2) {
c1 = isupper(*s1) ? tolower(*s1) : *s1; c1 = isupper(*s1) ? tolower(*s1) : *s1;
@ -1386,7 +1386,7 @@ CopySubstring(
char *buf, char *buf,
Boolean addNewlines) Boolean addNewlines)
{ {
register XmTextLineTable line_table = widget->text.line_table; XmTextLineTable line_table = widget->text.line_table;
int currLine, firstLine; int currLine, firstLine;
char *pString, *pCurrChar, *pLastChar; char *pString, *pCurrChar, *pLastChar;
int numToCopy; int numToCopy;

View file

@ -389,7 +389,7 @@ _DtEditorModifyVerifyCB(
caddr_t client_data, caddr_t client_data,
caddr_t call_data ) caddr_t call_data )
{ {
register XmTextVerifyCallbackStruct * cb = XmTextVerifyCallbackStruct * cb =
(XmTextVerifyCallbackStruct *) call_data; (XmTextVerifyCallbackStruct *) call_data;
DtEditorWidget editor = (DtEditorWidget) client_data; DtEditorWidget editor = (DtEditorWidget) client_data;

View file

@ -1607,7 +1607,7 @@ static Widget
CreateText( CreateText(
DtEditorWidget parent) DtEditorWidget parent)
{ {
register int ac; /* arg count */ int ac; /* arg count */
Arg al[21]; /* arg list */ Arg al[21]; /* arg list */
Widget text; Widget text;
@ -2102,7 +2102,7 @@ SetValues(
{ {
Boolean redisplay_flag = False; Boolean redisplay_flag = False;
Arg al[15]; /* arg list */ Arg al[15]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
Boolean resetSpellTitle = False, Boolean resetSpellTitle = False,
resetFormatTitle = False, resetFormatTitle = False,
@ -3726,8 +3726,8 @@ static unsigned int
GetModeSwitchModifier( GetModeSwitchModifier(
Display *dpy) Display *dpy)
{ {
register XModifierKeymap *pMap; XModifierKeymap *pMap;
register int mapIndex, keyCol, mapSize; int mapIndex, keyCol, mapSize;
KeySym keySym; KeySym keySym;
unsigned int modeSwitchModMask = 0; unsigned int modeSwitchModMask = 0;
pMap = XGetModifierMapping(dpy); pMap = XGetModifierMapping(dpy);
@ -4549,7 +4549,7 @@ UpdateOverstrikeIndicator(
Boolean overstrikeOn ) Boolean overstrikeOn )
{ {
Arg al[10]; Arg al[10];
register int ac; int ac;
DtEditorWidget ew = (DtEditorWidget) widget; DtEditorWidget ew = (DtEditorWidget) widget;
/* /*
@ -4639,7 +4639,7 @@ SetStatusLine(
Boolean statusLineOn) Boolean statusLineOn)
{ {
Arg al[10]; Arg al[10];
register int ac; int ac;
int currentLine; int currentLine;
XmTextPosition cursorPos; XmTextPosition cursorPos;
@ -5188,16 +5188,16 @@ extern int _nl_space_alt;
/* /*
* Forward declarations * Forward declarations
*/ */
static int DoLine (FormatData *data, register FILE *filep); static int DoLine (FormatData *data, FILE *filep);
static void Center (FormatData *data, static void Center (FormatData *data,
wint_t *in_line, register wint_t *inlinelim); wint_t *in_line, wint_t *inlinelim);
static void Fill (FormatData *data, wint_t *in_line, register wint_t *inlinelim); static void Fill (FormatData *data, wint_t *in_line, wint_t *inlinelim);
static void FillWord (FormatData *data); static void FillWord (FormatData *data);
static void Dump (FormatData *data, int endpara); static void Dump (FormatData *data, int endpara);
static void PrintIndent (FormatData *data, int indent); static void PrintIndent (FormatData *data, int indent);
static void PrintTag (FormatData *data, WORD *wordpast); static void PrintTag (FormatData *data, WORD *wordpast);
static void PrintWords (FormatData *data, WORD *wordpast); static void PrintWords (FormatData *data, WORD *wordpast);
static void Justify (FormatData *data, register int blanks, WORD *wordpast); static void Justify (FormatData *data, int blanks, WORD *wordpast);
static int CompareWords (const void *, const void *); static int CompareWords (const void *, const void *);
static int EkinBekinProc(FormatData *data, WORD **wordpast); static int EkinBekinProc(FormatData *data, WORD **wordpast);
static void postEkinBekinProc(FormatData *data, int *poutchars, WORD *wordpast); static void postEkinBekinProc(FormatData *data, int *poutchars, WORD *wordpast);
@ -5353,8 +5353,8 @@ fixLeftMarginAndNewlines(
int endPos) int endPos)
{ {
Widget widget = M_text(editor); Widget widget = M_text(editor);
register XmTextLineTable lineTable; XmTextLineTable lineTable;
register int i; int i;
int lineIndex, lineLen, nextLen, lineIndent, lastIndex, int lineIndex, lineLen, nextLen, lineIndent, lastIndex,
lineByteLen, total_lines; lineByteLen, total_lines;
Boolean newPara = True; Boolean newPara = True;
@ -5541,7 +5541,7 @@ FormatText (
{ {
long maxmargin; /* max allowed */ long maxmargin; /* max allowed */
register FILE *filep; /* file to read */ FILE *filep; /* file to read */
int retVal; int retVal;
FormatData data; FormatData data;
@ -5648,12 +5648,12 @@ CleanUp:
static int static int
DoLine (FormatData *data, DoLine (FormatData *data,
register FILE *filep) /* open file to read */ FILE *filep) /* open file to read */
{ {
wint_t in_line [LINESIZE]; /* after reading in */ wint_t in_line [LINESIZE]; /* after reading in */
register wint_t *incp = in_line; /* place in in_line */ wint_t *incp = in_line; /* place in in_line */
register wint_t *incplim = in_line + LINESIZE; /* limit of in_line */ wint_t *incplim = in_line + LINESIZE; /* limit of in_line */
register wint_t c; wint_t c;
/* /*
* READ LINE WITH BACKSPACE CRUNCHING: * READ LINE WITH BACKSPACE CRUNCHING:
@ -5713,17 +5713,17 @@ DoLine (FormatData *data,
static void static void
Center (FormatData *data, Center (FormatData *data,
wint_t *in_line, /* start of input line */ wint_t *in_line, /* start of input line */
register wint_t *inlinelim) /* end of line + 1 */ wint_t *inlinelim) /* end of line + 1 */
{ {
register wint_t *incp; /* pointer in in_line */ wint_t *incp; /* pointer in in_line */
wint_t outline [LINESIZE + MAXTABSIZE]; /* after generic work */ wint_t outline [LINESIZE + MAXTABSIZE]; /* after generic work */
register wint_t *outcp = outline; /* place in outline */ wint_t *outcp = outline; /* place in outline */
register wint_t *outlinelim = outline + LINESIZE; /* limit of outline*/ wint_t *outlinelim = outline + LINESIZE; /* limit of outline*/
int haveword = False; /* hit word in in_line? */ int haveword = False; /* hit word in in_line? */
register wint_t ch; /* current working char */ wint_t ch; /* current working char */
register int needsp; /* spaces need for tab */ int needsp; /* spaces need for tab */
register int indent = 0; /* size of indentation */ int indent = 0; /* size of indentation */
int textwidth; /* size of text part */ int textwidth; /* size of text part */
int extwidth = 0; /* additional width for MBCS */ int extwidth = 0; /* additional width for MBCS */
@ -5875,12 +5875,12 @@ Center (FormatData *data,
static void static void
Fill (FormatData *data, Fill (FormatData *data,
wint_t *in_line, /* start of input line */ wint_t *in_line, /* start of input line */
register wint_t *inlinelim) /* end of line + 1 */ wint_t *inlinelim) /* end of line + 1 */
{ {
register wint_t *incp; /* place in in_line */ wint_t *incp; /* place in in_line */
register wint_t ch; /* current working char */ wint_t ch; /* current working char */
int haveword = False; /* hit word in in_line? */ int haveword = False; /* hit word in in_line? */
register int inword = False; /* currently in a word? */ int inword = False; /* currently in a word? */
/* /*
* SCAN INPUT LINE: * SCAN INPUT LINE:
*/ */
@ -6017,7 +6017,7 @@ FillWord (FormatData *data)
{ {
int wordlen; /* length of word to fill */ int wordlen; /* length of word to fill */
int blanks = 1; /* trailing blanks needed */ int blanks = 1; /* trailing blanks needed */
register wint_t ch1, ch2, ch3; /* last chars of word */ wint_t ch1, ch2, ch3; /* last chars of word */
data->wordat->length = (data->incolumn - data->wordat->incolumn); data->wordat->length = (data->incolumn - data->wordat->incolumn);
wordlen = data->wordat->wclen; wordlen = data->wordat->wclen;
@ -6094,9 +6094,9 @@ Dump (FormatData *data,
int startpara; /* start of paragraph? */ int startpara; /* start of paragraph? */
int normal; /* non-tagged line? */ int normal; /* non-tagged line? */
WORD *wordpast = data->wordfirst; /* past last to dump */ WORD *wordpast = data->wordfirst; /* past last to dump */
register int wordlen; /* length of one word */ int wordlen; /* length of one word */
int indent; /* local value */ int indent; /* local value */
register int outneed; /* chars need to dump */ int outneed; /* chars need to dump */
int outchars; /* chars found to dump */ int outchars; /* chars found to dump */
/* /*
@ -6274,10 +6274,10 @@ static void
PrintTag (FormatData *data, PrintTag (FormatData *data,
WORD *wordpast) /* past last to print */ WORD *wordpast) /* past last to print */
{ {
register WORD *wordat = data->wordfirst; /* local value */ WORD *wordat = data->wordfirst; /* local value */
register int outcol = data->indent1 + 1; /* next column */ int outcol = data->indent1 + 1; /* next column */
int wordcol; /* desired column */ int wordcol; /* desired column */
register wint_t *wordcp; /* place in word */ wint_t *wordcp; /* place in word */
wint_t *wordcplim; /* limit of word */ wint_t *wordcplim; /* limit of word */
while (True) /* till break */ while (True) /* till break */
@ -6318,10 +6318,10 @@ static void
PrintWords (FormatData *data, PrintWords (FormatData *data,
WORD *wordpast) /* past last to print */ WORD *wordpast) /* past last to print */
{ {
register WORD *wordat = data->wordfirst; /* local value */ WORD *wordat = data->wordfirst; /* local value */
register wint_t *wordcp; /* place in word */ wint_t *wordcp; /* place in word */
wint_t *wordcplim; /* limit of word */ wint_t *wordcplim; /* limit of word */
register int blanks; /* after a word */ int blanks; /* after a word */
while (True) /* till break */ while (True) /* till break */
{ {
@ -6363,13 +6363,13 @@ PrintWords (FormatData *data,
static void static void
Justify (FormatData *data, Justify (FormatData *data,
register int blanks, /* blanks to insert */ int blanks, /* blanks to insert */
WORD *wordpast) /* past last to print */ WORD *wordpast) /* past last to print */
{ {
register WORD *wordat; /* local value */ WORD *wordat; /* local value */
register int sortat; /* place in sort[] */ int sortat; /* place in sort[] */
register int wordlen; /* size of this word */ int wordlen; /* size of this word */
register int nextlen; /* size of next word */ int nextlen; /* size of next word */
int level; /* current blanks level */ int level; /* current blanks level */
WORD *sort [WORDMAX]; /* sorted pointers */ WORD *sort [WORDMAX]; /* sorted pointers */
@ -7041,7 +7041,7 @@ ComputeRightMargin(
margin_width; margin_width;
int rightMargin; int rightMargin;
Arg al[5]; /* arg list */ Arg al[5]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
ac=0; ac=0;
XtSetArg(al[ac], XmNwidth, &text_width); ac++; XtSetArg(al[ac], XmNwidth, &text_width); ac++;
@ -7177,7 +7177,7 @@ CreateFormatDialog(
DtEditorWidget editor) DtEditorWidget editor)
{ {
Arg al[15]; /* arg list */ Arg al[15]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
Pixel textBackground, textForeground; Pixel textBackground, textForeground;
XmString tempString = (XmString)NULL; XmString tempString = (XmString)NULL;
@ -8072,7 +8072,7 @@ DtEditorGetSizeHints(
XSizeHints *pHints) /* Return */ XSizeHints *pHints) /* Return */
{ {
Arg al[10]; /* arg list */ Arg al[10]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
Dimension FormWidth, FormHeight, Dimension FormWidth, FormHeight,
Twidth, Theight, statusHeight, Twidth, Theight, statusHeight,
highlightThickness, shadowThickness, highlightThickness, shadowThickness,

View file

@ -2668,8 +2668,8 @@ SetValues(
static void static void
BorderHighlight( DtIconGadget g) BorderHighlight( DtIconGadget g)
{ {
register int width; int width;
register int height; int height;
CallCallbackProc call_callback; CallCallbackProc call_callback;
width = g->rectangle.width; width = g->rectangle.width;
@ -2699,9 +2699,9 @@ static void
BorderUnhighlight( DtIconGadget g) BorderUnhighlight( DtIconGadget g)
{ {
register int window_width; int window_width;
register int window_height; int window_height;
register int highlight_width; int highlight_width;
CallCallbackProc call_callback; CallCallbackProc call_callback;
window_width = g->rectangle.width; window_width = g->rectangle.width;

View file

@ -66,7 +66,7 @@ ManageFind(
DtEditorWidget pPriv) DtEditorWidget pPriv)
{ {
Arg al[10]; Arg al[10];
register int ac; int ac;
ac = 0; ac = 0;
XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++;
@ -83,7 +83,7 @@ UnmanageFind(
DtEditorWidget pPriv) DtEditorWidget pPriv)
{ {
Arg al[10]; Arg al[10];
register int ac; int ac;
XtUnmanageChild(M_search_findLbl(pPriv)); XtUnmanageChild(M_search_findLbl(pPriv));
XtUnmanageChild(M_findText(pPriv)); XtUnmanageChild(M_findText(pPriv));
@ -109,7 +109,7 @@ _DtEditorSearch(
Boolean createonly ) Boolean createonly )
{ {
Arg al[10]; /* arg list */ Arg al[10]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
/* create the dialog if it is the first time */ /* create the dialog if it is the first time */
if ( !M_search_dialog(pPriv) ) if ( !M_search_dialog(pPriv) )
@ -274,7 +274,7 @@ CreateSearchDialog(
DtEditorWidget pPriv) DtEditorWidget pPriv)
{ {
Arg al[10]; /* arg list */ Arg al[10]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
Pixel textBackground, textForeground; Pixel textBackground, textForeground;
XmString tmpStr1; XmString tmpStr1;

View file

@ -498,7 +498,7 @@ GetTitleString(
XtArgVal *value ) XtArgVal *value )
{ {
Arg al[10]; /* arg list */ Arg al[10]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
Widget title_area = M_TitleArea (manager); Widget title_area = M_TitleArea (manager);
XmString string = NULL; XmString string = NULL;
@ -558,7 +558,7 @@ Initialize(
DtTitleBoxWidget new ) DtTitleBoxWidget new )
{ {
Arg al[10]; /* arg list */ Arg al[10]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
Widget title = NULL; Widget title = NULL;
XmString title_string = NULL; XmString title_string = NULL;
@ -823,7 +823,7 @@ SetValues(
new_title = False, new_title = False,
new_font = False; new_font = False;
Arg al[10]; /* arg list */ Arg al[10]; /* arg list */
register int ac; /* arg count */ int ac; /* arg count */
/* Validate title position. /* Validate title position.
*/ */