|
CTWM
|
#include <ctype.h>#include <stdio.h>Go to the source code of this file.
Macros | |
| #define | MAX(x, y) |
| #define | MIN(x, y) |
| #define | ABS(x) |
| #define | Isascii(c) |
| #define | Isdigit(c) |
| #define | Islower(c) |
| #define | Isupper(c) |
| #define | Tolower(c) |
| #define | Toupper(c) |
Functions | |
| static int | max (int a, int b) |
| static int | min (int a, int b) |
| char * | ExpandFilename (const char *name) |
| char * | ExpandFilePath (char *path) |
| void | GetColor (int kind, Pixel *what, const char *name) |
| Get info from the server about a given color. | |
| void | GetShadeColors (ColorPair *cp) |
| Try and create a 'shaded' version of a color for prettier UI. | |
| bool | UpdateFont (MyFont *font, int height) |
| Try adjusting a font's height. | |
| void | CreateFonts (ScreenInfo *scr) |
| Load up our various defined fonts. | |
| void | RescueWindows (void) |
| Backend for f.rescuewindows. | |
| void | DebugTrace (char *file) |
| Backend for f.trace. | |
| void | safe_strncpy (char *dest, const char *src, size_t size) |
Variables | |
| FILE * | tracefile |
| #define ABS | ( | x | ) |
Definition at line 42 of file util.h.
Referenced by OtpScrPriorityL(), OtpScrSetZero(), and OtpSetPriority().
| #define Isascii | ( | c | ) |
Definition at line 51 of file util.h.
Referenced by CheckWarpScreenArg().
| #define Isdigit | ( | c | ) |
Definition at line 52 of file util.h.
Referenced by ChangeSize(), and CheckWarpScreenArg().
| #define Islower | ( | c | ) |
Definition at line 53 of file util.h.
Referenced by HandleKeyPress().
| #define Isupper | ( | c | ) |
Definition at line 54 of file util.h.
Referenced by HandleKeyPress().
Definition at line 36 of file util.h.
Referenced by _tryToPack(), CreateOccupyWindow(), FindConstraint(), MakeMenu(), OwlEffectivePriority(), RaiseLowerOwl(), ResizeOccupyWindow(), ZoomInWindow(), and ZoomOutWindow().
Definition at line 39 of file util.h.
Referenced by _tryToPack(), FindConstraint(), OwlEffectivePriority(), and SetupOccupation().
| #define Tolower | ( | c | ) |
Definition at line 55 of file util.h.
Referenced by HandleKeyPress().
| void CreateFonts | ( | ScreenInfo * | scr | ) |
Load up our various defined fonts.
Definition at line 383 of file util.c.
References ScreenInfo::HaveFonts, and LOADFONT.
Referenced by AddToMenu(), and ctwm_main().
| void DebugTrace | ( | char * | file | ) |
Backend for f.trace.
Definition at line 553 of file util.c.
References tracefile.
Referenced by f_trace_impl().
| char * ExpandFilename | ( | const char * | name | ) |
| char * ExpandFilePath | ( | char * | path | ) |
| void GetColor | ( | int | kind, |
| Pixel * | what, | ||
| const char * | name ) |
Get info from the server about a given color.
Definition at line 154 of file util.c.
References dpy, StdCmap::maps, StdCmap::next, StdCmap::nmaps, ProgramName, and Scr.
Referenced by AddToMenu(), AddWorkSpace(), assign_var_savecolor(), CreateOccupyWindow(), ctwm_main(), do_color_keyword(), do_colorlist_keyword(), GetColorFromList(), GetRoot(), GetShadeColors(), MakeMenu(), WMapCreateCurrentBackGround(), and WMapCreateDefaultBackGround().
| void GetShadeColors | ( | ColorPair * | cp | ) |
Try and create a 'shaded' version of a color for prettier UI.
Definition at line 245 of file util.c.
References ColorPair::back, dpy, GetColor(), Scr, ColorPair::shadc, and ColorPair::shadd.
Referenced by AddIconManager(), AddToMenu(), AddWindow(), AddWorkSpace(), apply_window_name(), CreateIconWindow(), CreateOccupyWindow(), CreateWorkSpaceManager(), ctwm_main(), MakeMenu(), and WMapAddWindowToWorkspace().
|
inlinestatic |
Definition at line 25 of file util.h.
Referenced by EwmhRecalculateStrut(), RAreaHorizontalUnion(), RAreaIntersect(), RAreaVerticalUnion(), RLayoutFullHoriz1(), and RLayoutFullVert1().
|
inlinestatic |
Definition at line 30 of file util.h.
Referenced by ConstrainSize(), RAreaHorizontalUnion(), RAreaIntersect(), RAreaVerticalUnion(), RLayoutFullHoriz1(), and RLayoutFullVert1().
| void RescueWindows | ( | void | ) |
Backend for f.rescuewindows.
Definition at line 471 of file util.c.
References dpy, TwmWindow::frame_bw, TwmWindow::frame_height, TwmWindow::frame_width, TwmWindow::frame_x, TwmWindow::frame_y, VirtualScreen::h, TwmWindow::icon, MARGIN, TwmWindow::next, Scr, SetupWindow(), TwmWindow::vs, Icon::w, VirtualScreen::w, Icon::w_height, Icon::w_width, Icon::w_x, Icon::w_y, x, and y.
Referenced by f_rescuewindows_impl().
| void safe_strncpy | ( | char * | dest, |
| const char * | src, | ||
| size_t | size ) |
Definition at line 586 of file util.c.
Referenced by GetMaskFromProperty(), RedirectToCaptive(), and SetupOccupation().
| bool UpdateFont | ( | MyFont * | font, |
| int | height ) |
Try adjusting a font's height.
Used in drawing the icon manager.
Definition at line 292 of file util.c.
References MyFont::avg_count, MyFont::avg_fheight, and MyFont::avg_height.
Referenced by DrawIconManagerIconName().
|
extern |
Definition at line 59 of file util.c.
Referenced by DebugTrace(), dumpevent(), TryToAnimate(), and WMapRestack().