Lines Matching defs:twm_win

59 	TwmWindow  *twm_win;
97 Icon *icon = owl->twm_win->icon;
106 TwmWindow *twm_win = owl->twm_win;
108 b.x = twm_win->frame_x;
109 b.y = twm_win->frame_y;
110 b.width = twm_win->frame_width;
111 b.height = twm_win->frame_height;
141 TwmWindow *twm_win = owl->twm_win;
143 return (((owl->type == IconWin) ? twm_win->iconified : twm_win->mapped)
144 && OCCUPY(twm_win, Scr->currentvs->wsw->currentwspc));
153 bool isGroupLeader(TwmWindow *twm_win)
155 return ((twm_win->group == 0)
156 || (twm_win->group == twm_win->w));
159 bool isGroupLeaderOf(TwmWindow *leader, TwmWindow *twm_win)
162 && !isGroupLeader(twm_win)
163 && (leader->group == twm_win->group));
185 ? owl->twm_win->icon->w : owl->twm_win->frame;
209 TwmWindow *twm_win;
231 twm_win = owl->twm_win;
234 assert(((owl->type == IconWin) && (owl == twm_win->icon->otp))
235 || ((owl->type == WinWin) && (owl == twm_win->otp)));
255 priority, owl->below->twm_win->name,
256 nextpri, owl->twm_win->name);
267 if(twm_win) {
269 twm_win->name,
270 (unsigned int)twm_win->occupation);
271 if(owl->twm_win->vs) {
273 twm_win->vs->x,
274 twm_win->vs->y);
279 if(owl->twm_win->parent_vs) {
281 twm_win->parent_vs->x,
282 twm_win->parent_vs->y);
297 if(twm_win->winbox) {
311 if(currentvs == twm_win->parent_vs) {
347 for(twm_win = Scr->FirstWindow; twm_win != NULL; twm_win = twm_win->next) {
380 while(owl != NULL && owl->twm_win->parent_vs != vs) {
399 while(owl != NULL && owl->twm_win->winbox != wb) {
421 owl->twm_win->parent_vs->x,
422 owl->twm_win->parent_vs->y);
427 owl->twm_win->parent_vs->x,
428 owl->twm_win->parent_vs->y);
452 WindowBox *winbox = owl->twm_win->winbox;
466 vs_owl = GetOwlAtOrBelowInVS(other_owl, owl->twm_win->parent_vs);
488 assert(owl->twm_win->parent_vs == vs_owl->twm_win->parent_vs);
513 && isSmallTransientOf(owl->twm_win, other_owl->twm_win));
645 && isTransientOf(other_owl->twm_win, owl->twm_win)) {
763 void OtpRaise(TwmWindow *twm_win, WinType wintype)
765 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
777 void OtpLower(TwmWindow *twm_win, WinType wintype)
779 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
791 void OtpRaiseLower(TwmWindow *twm_win, WinType wintype)
793 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
805 void OtpTinyRaise(TwmWindow *twm_win, WinType wintype)
807 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
819 void OtpTinyLower(TwmWindow *twm_win, WinType wintype)
821 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
877 void OtpHandleCirculateNotify(VirtualScreen *vs, TwmWindow *twm_win,
882 OtpRaise(twm_win, wintype);
885 OtpLower(twm_win, wintype);
894 void OtpSetPriority(TwmWindow *twm_win, WinType wintype, int new_pri, int where)
896 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
903 if(twm_win->winbox != NULL || twm_win->iswinbox) {
920 void OtpChangePriority(TwmWindow *twm_win, WinType wintype, int relpriority)
922 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
927 if(twm_win->winbox != NULL || twm_win->iswinbox) {
941 void OtpSwitchPriority(TwmWindow *twm_win, WinType wintype)
943 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
950 if(twm_win->winbox != NULL || twm_win->iswinbox) {
963 void OtpToggleSwitching(TwmWindow *twm_win, WinType wintype)
965 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
969 if(twm_win->winbox != NULL || twm_win->iswinbox) {
990 void OtpForcePlacement(TwmWindow *twm_win, int where, TwmWindow *other_win)
992 OtpWinList *owl = twm_win->otp;
995 assert(twm_win->otp != NULL);
1027 TwmWindow *twm_win = owl->twm_win;
1030 if(LookInList(prefs->switchingL, twm_win->name, &twm_win->class)) {
1037 twm_win->name, &twm_win->class)) {
1068 EwmhSet_NET_WM_STATE(owl->twm_win, EWMH_STATE_ABOVE);
1073 void OtpRecomputePrefs(TwmWindow *twm_win)
1075 assert(twm_win->otp != NULL);
1077 RecomputeOwlPrefs(Scr->OTP, twm_win->otp);
1078 if(twm_win->icon != NULL) {
1079 RecomputeOwlPrefs(Scr->IconOTP, twm_win->icon->otp);
1094 void OtpRemove(TwmWindow *twm_win, WinType wintype)
1097 owlp = (wintype == IconWin) ? &twm_win->icon->otp : &twm_win->otp;
1109 static OtpWinList *new_OtpWinList(TwmWindow *twm_win,
1118 owl->twm_win = twm_win;
1134 static OtpWinList *AddNewOwl(TwmWindow *twm_win, WinType wintype,
1141 owl = new_OtpWinList(twm_win, wintype,
1151 if(!(parent != NULL && twm_win->istransient)) {
1158 owl->pri_base = EwmhGetInitPriority(twm_win) + OTP_ZERO;
1189 if(twm_win->ewmhFlags & EWMH_STATE_FULLSCREEN) {
1196 if(twm_win->ewmhFlags & EWMH_STATE_ABOVE) {
1199 if(twm_win->ewmhFlags & EWMH_STATE_BELOW) {
1222 void OtpAdd(TwmWindow *twm_win, WinType wintype)
1227 owlp = (wintype == IconWin) ? &twm_win->icon->otp : &twm_win->otp;
1235 else if(twm_win->winbox) {
1237 parent = twm_win->winbox->twmwin->otp;
1242 else if(wintype == WinWin && (twm_win->istransient
1243 || !isGroupLeader(twm_win))) {
1246 && !isTransientOf(twm_win, other_win)
1247 && !isGroupLeaderOf(other_win, twm_win)) {
1256 *owlp = AddNewOwl(twm_win, wintype, parent);
1262 void OtpReassignIcon(TwmWindow *twm_win, Icon *old_icon)
1266 Icon *new_icon = twm_win->icon;
1274 OtpAdd(twm_win, IconWin);
1278 void OtpFreeIcon(TwmWindow *twm_win)
1281 Icon *cur_icon = twm_win->icon;
1283 OtpRemove(twm_win, IconWin);
1378 int ReparentWindow(Display *display, TwmWindow *twm_win, WinType wintype,
1382 OtpWinList *owl = (wintype == IconWin) ? twm_win->icon->otp : twm_win->otp;
1399 ReparentWindowAndIcon(Display *display, TwmWindow *twm_win,
1403 OtpWinList *win_owl = twm_win->otp;
1404 assert(twm_win->icon != NULL);
1405 OtpWinList *icon_owl = twm_win->icon->otp;
1411 DPRINTF((stderr, "ReparentWindowAndIcon %x\n", (unsigned int)twm_win->frame));
1412 XReparentWindow(display, twm_win->frame, parent, win_x, win_y);
1413 XReparentWindow(display, twm_win->icon->w, parent, icon_x, icon_y);
1443 return owl ? owl->twm_win : NULL;
1455 return top ? top->twm_win : NULL;
1458 TwmWindow *OtpNextWinUp(TwmWindow *twm_win)
1460 OtpWinList *owl = twm_win->otp->above;
1464 return owl ? owl->twm_win : NULL;
1467 TwmWindow *OtpNextWinDown(TwmWindow *twm_win)
1469 OtpWinList *owl = twm_win->otp->below;
1473 return owl ? owl->twm_win : NULL;
1491 OtpEffectivePriority(owl->twm_win),
1492 OtpEffectiveDisplayPriority(owl->twm_win),
1494 owl->twm_win->w, owl->twm_win->name);
1505 if(owl->twm_win->istransient) {
1506 const TwmWindow *parent = GetTwmWindow(owl->twm_win->transientfor);
1522 OtpSetAflagMask(TwmWindow *twm_win, unsigned mask, unsigned setto)
1524 assert(twm_win != NULL);
1525 assert(twm_win->otp != NULL);
1526 OwlSetAflagMask(twm_win->otp, mask, setto);
1541 OtpSetAflag(TwmWindow *twm_win, unsigned flag)
1543 assert(twm_win != NULL);
1544 assert(twm_win->otp != NULL);
1546 OwlSetAflag(twm_win->otp, flag);
1559 OtpClearAflag(TwmWindow *twm_win, unsigned flag)
1561 assert(twm_win != NULL);
1562 assert(twm_win->otp != NULL);
1564 OwlClearAflag(twm_win->otp, flag);
1585 OtpStashAflagsFirstTime(TwmWindow *twm_win)
1587 if(!twm_win->otp->stashed_aflags) {
1588 OwlStashAflags(twm_win->otp);
1602 XChangeProperty(dpy, owl->twm_win->w, XA_CTWM_OTP_AFLAGS, XA_INTEGER,
1624 ret = XGetWindowProperty(dpy, owl->twm_win->w, XA_CTWM_OTP_AFLAGS, 0, 1,
1648 OtpRestackWindow(TwmWindow *twm_win)
1650 OtpWinList *owl = twm_win->otp;
1675 OtpFocusWindowBE(TwmWindow *twm_win, int oldprio)
1677 OtpWinList *owl = twm_win->otp;
1716 && isTransientOf(trans->twm_win, twm_win)) {
1753 OtpUnfocusWindow(TwmWindow *twm_win)
1759 int oldprio = PRI(twm_win->otp);
1762 assert(Scr->Focus == twm_win);
1766 OtpFocusWindowBE(twm_win, oldprio);
1774 OtpFocusWindow(TwmWindow *twm_win)
1777 int oldprio = PRI(twm_win->otp);
1779 assert(Scr->Focus != twm_win);
1780 Scr->Focus = twm_win;
1782 OtpFocusWindowBE(twm_win, oldprio);
1794 OtpEffectiveDisplayPriority(TwmWindow *twm_win)
1796 assert(twm_win != NULL);
1797 assert(twm_win->otp != NULL);
1799 return(OwlEffectivePriority(twm_win->otp) - OTP_ZERO);
1803 OtpEffectivePriority(TwmWindow *twm_win)
1805 assert(twm_win != NULL);
1806 assert(twm_win->otp != NULL);
1808 return OwlEffectivePriority(twm_win->otp);
1835 EwmhWindowType ewt = owl->twm_win->ewmhWindowType;
1850 if(Scr->Focus == owl->twm_win) {
1854 else if(owl->twm_win->istransient) {
1861 TwmWindow *parent = GetTwmWindow(owl->twm_win->transientfor);
1883 OtpIsFocusDependent(TwmWindow *twm_win)
1885 assert(twm_win != NULL);
1886 assert(twm_win->otp != NULL);
1894 if(twm_win->otp->pri_aflags & OTP_AFLAG_FULLSCREEN) {