Skip to content

Commit

Permalink
cleanup: address warnings
Browse files Browse the repository at this point in the history
Make clang happy.
  • Loading branch information
ThomasAdam committed Sep 28, 2022
1 parent 2860f59 commit 005dd9e
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 11 deletions.
1 change: 0 additions & 1 deletion fvwm/add_window.c
Original file line number Diff line number Diff line change
Expand Up @@ -2131,7 +2131,6 @@ FvwmWindow *AddWindow(
const exec_context_t *exc2;
exec_context_changes_t ecc;
struct monitor *mon;
extern Bool Restarting;

/****** init window structure ******/
setup_window_structure(&tmp, w, ReuseWin);
Expand Down
2 changes: 1 addition & 1 deletion fvwm/menuitem.c
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@ void menuitem_paint(
/*
* Hilight the item.
*/
if (FftSupport && ST_PSTDFONT(ms)->fftf.fftfont != NULL)
if (FftSupport)
{
xft_clear = True;
}
Expand Down
2 changes: 1 addition & 1 deletion modules/FvwmButtons/draw.c
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ void DrawTitle(button_info *b,Window win,GC gc, XEvent *pev)
XUnionRectWithRegion (&clip, region, region);
FwinString.flags.has_clip_region = True;
FwinString.clip_region = region;
if (0 && Ffont->fftf.fftfont != NULL)
if (0)
{
XClearArea(
Dpy, win,
Expand Down
4 changes: 1 addition & 3 deletions modules/FvwmForm/FvwmForm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1482,8 +1482,7 @@ void RedrawFrame(XEvent *pev)
item = root_item_ptr;
while(item != 0 && !clear)
{
if ((item->type == I_TEXT || item->type == I_CHOICE) &&
item->header.dt_ptr->dt_Ffont->fftf.fftfont != NULL)
if ((item->type == I_TEXT || item->type == I_CHOICE))
clear = True;
item = item->header.next;
}
Expand Down Expand Up @@ -1951,7 +1950,6 @@ void RedrawItem (Item *item, int click, XEvent *pev)
item->header.dt_ptr->dt_Fstr->len = item->button.len;
if (FftSupport)
{
if (item->header.dt_ptr->dt_Ffont->fftf.fftfont != NULL)
XClearArea(dpy, item->header.win,
inter.x, inter.y, inter.width, inter.height, False);
}
Expand Down
6 changes: 3 additions & 3 deletions modules/FvwmIdent/FvwmIdent.c
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ void list_config_info(unsigned long *body)
if (StrEquals(token, "Colorset") && colorset >= 0 &&
LoadColorset(tline) == colorset)
{
if (FftSupport && Ffont->fftf.fftfont != NULL)
if (FftSupport)
{
UsePixmapDrawing = True;
}
Expand Down Expand Up @@ -589,7 +589,7 @@ int ProcessXEvent(int x, int y)
ey2=max(ey2,
Event.xexpose.y + Event.xexpose.height);
}
if (FftSupport && Ffont->fftf.fftfont != NULL)
if (FftSupport)
{
XClearArea(
dpy, main_win,
Expand Down Expand Up @@ -754,7 +754,7 @@ void list_end(void)
}

/* chose the rendering methode */
if (FftSupport && Ffont->fftf.fftfont != NULL)
if (FftSupport)
{
UsePixmapDrawing = True;
}
Expand Down
4 changes: 2 additions & 2 deletions modules/FvwmPager/x_pager.c
Original file line number Diff line number Diff line change
Expand Up @@ -1788,7 +1788,7 @@ void DrawGrid(int desk, int erase, Window ew, XRectangle *r)
bound.height = label_h;
}

if (FftSupport && Ffont->fftf.fftfont != NULL)
if (FftSupport)
{
erase = True;
}
Expand Down Expand Up @@ -2841,7 +2841,7 @@ static void do_label_window(PagerWindow *t, Window w)
t->window_label = GetBalloonLabel(t, WindowLabelFormat);
if (w != None)
{
if (FftSupport && FwindowFont != NULL && FwindowFont->fftf.fftfont != NULL)
if (FftSupport)
XClearWindow(dpy, w);
FwinString->win = w;
FwinString->gc = Scr.NormalGC;
Expand Down

0 comments on commit 005dd9e

Please sign in to comment.