Lines Matching defs:win
51 __sync(WINDOW *win)
53 if (__predict_false(win == NULL))
56 if (win->flags & __IMMEDOK)
57 wrefresh(win);
58 if (win->flags & __SYNCOK)
59 wsyncup(win);
67 is_linetouched(WINDOW *win, int line)
69 if (__predict_false(win == NULL))
72 if (line > win->maxy)
76 win, line, (win->alines[line]->flags & __ISDIRTY));
77 return (win->alines[line]->flags & __ISDIRTY) != 0;
86 touchline(WINDOW *win, int start, int count)
88 __CTRACE(__CTRACE_LINE, "touchline: (%p, %d, %d)\n", win, start, count);
89 return wtouchln(win, start, count, 1);
97 int wredrawln(WINDOW *win, int start, int count)
99 __CTRACE(__CTRACE_LINE, "wredrawln: (%p, %d, %d)\n", win, start, count);
100 return wtouchln(win, start, count, 1);
108 is_wintouched(WINDOW *win)
112 __CTRACE(__CTRACE_LINE, "is_wintouched: (%p, maxy %d)\n", win,
113 win->maxy);
114 if (__predict_false(win == NULL))
117 maxy = win->maxy;
119 if (is_linetouched(win, y) == TRUE)
131 touchwin(WINDOW *win)
133 __CTRACE(__CTRACE_LINE, "touchwin: (%p)\n", win);
134 return wtouchln(win, 0, win->maxy, 1);
142 redrawwin(WINDOW *win)
144 __CTRACE(__CTRACE_LINE, "redrawwin: (%p)\n", win);
145 return wtouchln(win, 0, win->maxy, 1);
153 untouchwin(WINDOW *win)
155 __CTRACE(__CTRACE_LINE, "untouchwin: (%p)\n", win);
156 return wtouchln(win, 0, win->maxy, 0);
165 wtouchln(WINDOW *win, int line, int n, int changed)
171 win, line, n, changed);
172 if (__predict_false(win == NULL))
175 if (line < 0 || win->maxy <= line)
179 if (n > win->maxy - line)
180 n = win->maxy - line;
184 _cursesi_touchline_force(win, y, 0,
185 (int) win->maxx - 1, 1);
187 wlp = win->alines[y];
188 if (*wlp->firstchp >= win->ch_off &&
189 *wlp->firstchp < win->maxx + win->ch_off)
190 *wlp->firstchp = win->maxx + win->ch_off;
191 if (*wlp->lastchp >= win->ch_off &&
192 *wlp->lastchp < win->maxx + win->ch_off)
193 *wlp->lastchp = win->ch_off;
206 __touchwin(WINDOW *win, int force)
210 __CTRACE(__CTRACE_LINE, "__touchwin: (%p)\n", win);
211 maxy = win->maxy;
213 _cursesi_touchline_force(win, y, 0, (int) win->maxx - 1,
219 __touchline(WINDOW *win, int y, int sx, int ex)
222 return _cursesi_touchline_force(win, y, sx, ex, 0);
226 * Touch line y on window win starting from column sx and ending at
233 _cursesi_touchline_force(WINDOW *win, int y, int sx, int ex, int force)
237 win, y, sx, ex, force);
239 *win->alines[y]->firstchp, *win->alines[y]->lastchp);
240 sx += win->ch_off;
241 ex += win->ch_off;
242 win->alines[y]->flags |= __ISDIRTY;
244 win->alines[y]->flags |= __ISFORCED;
246 if (*win->alines[y]->firstchp > sx)
247 *win->alines[y]->firstchp = sx;
248 if (*win->alines[y]->lastchp < ex)
249 *win->alines[y]->lastchp = ex;
251 *win->alines[y]->firstchp, *win->alines[y]->lastchp);
256 wsyncup(WINDOW *win)
259 if (__predict_false(win == NULL))
263 __touchwin(win, 0);
264 win = win->orig;
265 } while (win);
269 wsyncdown(WINDOW *win)
271 if (__predict_false(win == NULL))
274 WINDOW *w = win->orig;
278 __touchwin(win, 0);