|
ROOT 6.16/01 Reference Guide |
#include <X11/Xlib.h>#include <X11/Xutil.h>#include <X11/Xatom.h>#include <stdio.h>#include <string.h>#include <stdlib.h>#include "TMath.h"Macros | |
| #define | _XVERTEXT_INCLUDED_ |
| #define | BCENTRE 8 |
| #define | BLEFT 7 |
| #define | BRIGHT 9 |
| #define | CACHE_BITMAPS |
| #define | CACHE_SIZE_LIMIT 0 |
| #define | DEBUG_PRINT1(a) if (gRotatedDebug) printf (a) |
| #define | DEBUG_PRINT2(a, b) if (gRotatedDebug) printf (a, b) |
| #define | DEBUG_PRINT3(a, b, c) if (gRotatedDebug) printf (a, b, c) |
| #define | DEBUG_PRINT4(a, b, c, d) if (gRotatedDebug) printf (a, b, c, d) |
| #define | DEBUG_PRINT5(a, b, c, d, e) if (gRotatedDebug) printf (a, b, c, d, e) |
| #define | M_PI 3.14159265358979323846 |
| #define | MCENTRE 5 |
| #define | MLEFT 4 |
| #define | MRIGHT 6 |
| #define | NONE 0 |
| #define | TCENTRE 2 |
| #define | TLEFT 1 |
| #define | TRIGHT 3 |
| #define | XV_COPYRIGHT "xvertext routines Copyright (c) 1993 Alan Richardson" |
| #define | XV_VERSION 5.0 |
Typedefs | |
| typedef struct RotatedTextItemTemplate_t | RotatedTextItem_t |
Functions | |
| static XImage * | MakeXImage (Display *dpy, int w, int h) |
| Create an XImage structure and allocate memory for it. More... | |
| static char * | my_strdup (char *str) |
| Routine to mimic ‘strdup()’ (some machines don't have it) More... | |
| static char * | my_strtok (char *str1, char *str2) |
| Routine to replace ‘strtok’ : this one returns a zero length string if it encounters two consecutive delimiters. More... | |
| static void | XRotAddToLinkedList (Display *dpy, RotatedTextItem_t *item) |
| Adds a text item to the end of the cache, removing as many items from the front as required to keep cache size below limit. More... | |
| static RotatedTextItem_t * | XRotCreateTextItem (Display *dpy, XFontStruct *font, float angle, char *text, int align) |
| Create a rotated text item. More... | |
| int | XRotDrawAlignedImageString (Display *dpy, XFontStruct *font, float angle, Drawable drawable, GC gc, int x, int y, char *text, int align) |
| A front end to XRotPaintAlignedString: -does alignment, paints background. More... | |
| int | XRotDrawAlignedString (Display *dpy, XFontStruct *font, float angle, Drawable drawable, GC gc, int x, int y, char *text, int align) |
| A front end to XRotPaintAlignedString: -does alignment, no background. More... | |
| static int | XRotDrawHorizontalString (Display *dpy, XFontStruct *font, Drawable drawable, GC gc, int x, int y, char *text, int align, int bg) |
| Draw a horizontal string in a quick fashion. More... | |
| int | XRotDrawImageString (Display *dpy, XFontStruct *font, float angle, Drawable drawable, GC gc, int x, int y, char *str) |
| A front end to XRotPaintAlignedString: -no alignment, paints background. More... | |
| int | XRotDrawString (Display *dpy, XFontStruct *font, float angle, Drawable drawable, GC gc, int x, int y, char *str) |
| A front end to XRotPaintAlignedString: -no alignment, no background. More... | |
| static void | XRotFreeTextItem (Display *dpy, RotatedTextItem_t *item) |
| Free the resources used by a text item. More... | |
| static XImage * | XRotMagnifyImage (Display *dpy, XImage *ximage) |
| Magnify an XImage using bilinear interpolation. More... | |
| static int | XRotPaintAlignedString (Display *dpy, XFontStruct *font, float angle, Drawable drawable, GC gc, int x, int y, char *text, int align, int bg) |
| Aligns and paints a rotated string. More... | |
| static RotatedTextItem_t * | XRotRetrieveFromCache (Display *dpy, XFontStruct *font, float angle, char *text, int align) |
| Query cache for a match with this font/text/angle/alignment request, otherwise arrange for its creation. More... | |
| void | XRotSetBoundingBoxPad (int p) |
| Set the padding used when calculating bounding boxes. More... | |
| void | XRotSetMagnification (float m) |
| Set the font magnification factor for all subsequent operations. More... | |
| XPoint * | XRotTextExtents (Display *, XFontStruct *font, float angle, int x, int y, char *text, int align) |
| Calculate the bounding box some text will have when painted. More... | |
| float | XRotVersion (char *str, int n) |
| Return version/copyright information. More... | |
Variables | |
| static RotatedTextItem_t * | gFirstTextItem =0 |
| static int | gRotatedDebug =0 |
| static struct StyleTemplate_t | gRotStyle |
| #define _XVERTEXT_INCLUDED_ |
Definition at line 5 of file Rotated.cxx.
| #define BCENTRE 8 |
Definition at line 60 of file Rotated.cxx.
| #define BLEFT 7 |
Definition at line 59 of file Rotated.cxx.
| #define BRIGHT 9 |
Definition at line 61 of file Rotated.cxx.
| #define CACHE_BITMAPS |
Definition at line 82 of file Rotated.cxx.
| #define CACHE_SIZE_LIMIT 0 |
Definition at line 75 of file Rotated.cxx.
| #define DEBUG_PRINT1 | ( | a | ) | if (gRotatedDebug) printf (a) |
Definition at line 96 of file Rotated.cxx.
| #define DEBUG_PRINT2 | ( | a, | |
| b | |||
| ) | if (gRotatedDebug) printf (a, b) |
Definition at line 97 of file Rotated.cxx.
Definition at line 98 of file Rotated.cxx.
Definition at line 99 of file Rotated.cxx.
Definition at line 100 of file Rotated.cxx.
| #define M_PI 3.14159265358979323846 |
Definition at line 105 of file Rotated.cxx.
| #define MCENTRE 5 |
Definition at line 57 of file Rotated.cxx.
| #define MLEFT 4 |
Definition at line 56 of file Rotated.cxx.
| #define MRIGHT 6 |
Definition at line 58 of file Rotated.cxx.
| #define NONE 0 |
Definition at line 52 of file Rotated.cxx.
| #define TCENTRE 2 |
Definition at line 54 of file Rotated.cxx.
| #define TLEFT 1 |
Definition at line 53 of file Rotated.cxx.
| #define TRIGHT 3 |
Definition at line 55 of file Rotated.cxx.
| #define XV_COPYRIGHT "xvertext routines Copyright (c) 1993 Alan Richardson" |
Definition at line 45 of file Rotated.cxx.
| #define XV_VERSION 5.0 |
Definition at line 44 of file Rotated.cxx.
| typedef struct RotatedTextItemTemplate_t RotatedTextItem_t |
|
static |
Create an XImage structure and allocate memory for it.
Definition at line 266 of file Rotated.cxx.
|
static |
Routine to mimic ‘strdup()’ (some machines don't have it)
Definition at line 179 of file Rotated.cxx.
|
static |
Routine to replace ‘strtok’ : this one returns a zero length string if it encounters two consecutive delimiters.
Definition at line 195 of file Rotated.cxx.
|
static |
Adds a text item to the end of the cache, removing as many items from the front as required to keep cache size below limit.
Definition at line 1118 of file Rotated.cxx.
|
static |
Create a rotated text item.
Definition at line 804 of file Rotated.cxx.
| int XRotDrawAlignedImageString | ( | Display * | dpy, |
| XFontStruct * | font, | ||
| float | angle, | ||
| Drawable | drawable, | ||
| GC | gc, | ||
| int | x, | ||
| int | y, | ||
| char * | text, | ||
| int | align | ||
| ) |
A front end to XRotPaintAlignedString: -does alignment, paints background.
Definition at line 325 of file Rotated.cxx.
| int XRotDrawAlignedString | ( | Display * | dpy, |
| XFontStruct * | font, | ||
| float | angle, | ||
| Drawable | drawable, | ||
| GC | gc, | ||
| int | x, | ||
| int | y, | ||
| char * | text, | ||
| int | align | ||
| ) |
A front end to XRotPaintAlignedString: -does alignment, no background.
Definition at line 314 of file Rotated.cxx.
|
static |
Draw a horizontal string in a quick fashion.
Definition at line 567 of file Rotated.cxx.
| int XRotDrawImageString | ( | Display * | dpy, |
| XFontStruct * | font, | ||
| float | angle, | ||
| Drawable | drawable, | ||
| GC | gc, | ||
| int | x, | ||
| int | y, | ||
| char * | str | ||
| ) |
A front end to XRotPaintAlignedString: -no alignment, paints background.
Definition at line 303 of file Rotated.cxx.
| int XRotDrawString | ( | Display * | dpy, |
| XFontStruct * | font, | ||
| float | angle, | ||
| Drawable | drawable, | ||
| GC | gc, | ||
| int | x, | ||
| int | y, | ||
| char * | str | ||
| ) |
A front end to XRotPaintAlignedString: -no alignment, no background.
Definition at line 292 of file Rotated.cxx.
|
static |
Free the resources used by a text item.
Definition at line 1221 of file Rotated.cxx.
|
static |
Magnify an XImage using bilinear interpolation.
Definition at line 1244 of file Rotated.cxx.
|
static |
Aligns and paints a rotated string.
Definition at line 336 of file Rotated.cxx.
|
static |
Query cache for a match with this font/text/angle/alignment request, otherwise arrange for its creation.
Definition at line 664 of file Rotated.cxx.
| void XRotSetBoundingBoxPad | ( | int | p | ) |
Set the padding used when calculating bounding boxes.
Definition at line 257 of file Rotated.cxx.
| void XRotSetMagnification | ( | float | m | ) |
Set the font magnification factor for all subsequent operations.
Definition at line 248 of file Rotated.cxx.
| XPoint * XRotTextExtents | ( | Display * | , |
| XFontStruct * | font, | ||
| float | angle, | ||
| int | x, | ||
| int | y, | ||
| char * | text, | ||
| int | align | ||
| ) |
Calculate the bounding box some text will have when painted.
Definition at line 1350 of file Rotated.cxx.
| float XRotVersion | ( | char * | str, |
| int | n | ||
| ) |
Return version/copyright information.
Definition at line 238 of file Rotated.cxx.
|
static |
Definition at line 139 of file Rotated.cxx.
|
static |
Definition at line 93 of file Rotated.cxx.
|
static |