home *** CD-ROM | disk | FTP | other *** search
Text File | 1991-06-09 | 34.8 KB | 1,321 lines |
- TABLE OF CONTENTS
-
- vFont.library/Transform
- vFont.library/Rotate
- vFont.library/Scale
- vFont.library/Transpose
- vFont.library/Bend
- vFont.library/Cross
- vFont.library/Widen
- vFont.library/PolyCDraw
- vFont.library/PolyACDraw
- vFont.library/DrawCurve
- vFont.library/VText
- vFont.library/VTextLength
- vFont.library/VTextRoof
- vFont.library/OpenBFont
- vFont.library/OpenVFont
- vFont.library/GetVFont
- vFont.library/SetVFont
- vFont.library/MakeChar
- vFont.library/ChangeVFont
- vFont.library/ReThinkVFont
- vFont.library/UnmapVFont
- vFont.library/LockVFont
- vFont.library/UnLockVFont
- vFont.library/PrintVText
- vFont.library/CloseVFont
- vFont.library/LoadVFont
- vFont.library/SaveVFont
- vFont.library/SetVRendering
- vFont.library/ReportStatus
- vFont.library/FlushWhat
- vFont.library/AlertUser
- vFont.library/NewVFontContents
- vFont.library/SaveFontAttr
- vFont.library/FlushFonts
-
- vFont.library/Transform
-
- NAME
- Transform -- Scale, rotate, move and clip some vertices.
-
- SYNOPSIS
- Transform(vertices, cnt, sx, sy, a, r, t, min, max)
- A0 D1 D2 D3 D4 D5 A1 A2 A3
-
- Point *vertices;
- ULONG cnt;
- FIX sx;
- FIX sy;
- FIX a;
- Point *r;
- Point *t;
- Point *min;
- Point *max;
-
- FUNCTION
- This is the grand function for transforming some
- vertices. It will scale, rotate, move and finally
- clip the points.
-
- INPUTS
- vertices = the points that you wish to transform.
- cnt = The number of vertices.
- sx = The horizontal scaling factor.
- sy = The vertical scaling factor.
- a = The angle that the vertices should be rotated.
- t = Where the vertices should be moved to.
- min = The lower boundary to clip against.
- max = The upper boundary to clip against.
-
- RESULT
- None
-
- BUGS
- Untested code with missing pieces (no clipping is performed yet.
-
- SEE ALSO
- /vfont/fixpoint.h, /vfont/fixsin.h, Rotate, Scale, Transpose.
-
-
- vFont.library/Rotate
-
- NAME
- Rotate -- Rotate some vertices.
-
- SYNOPSIS
- Rotate(vertices, cnt, sinarg, cosarg, rx, ry)
- A0 D1 D2 D3 D4 D5
-
- Point *vertices;
- ULONG cnt;
- FIX sinarg;
- FIX cosarg;
- WORD rx;
- WORD ry;
-
- FUNCTION
- This is a subset of the Transform function. It simple rotates some
- vertices.
-
- INPUTS
- vertices = The vertices that you want to rotate.
- cnt = The number of vertices that you want to rotate.
- sinarg = The sinus value of the angle in fixpoint format.
- cosarg = The cosines value of the angle in fixpoint format.
- rx = The horizontal rotation center.
- ry = The vertical rotation center.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- /vfont/fixpoint.h, /vfont/fixsin.h, Transform, Scale, Transpose.
-
-
-
- vFont.library/Scale
-
- NAME
- Scale -- Scale a number of vertices.
-
- SYNOPSIS
- Scale(vertices, from, to, sym_x, sym_y)
- a0 a1 a2 d3 d4
-
- Points *vertices;
- Point *from;
- Point *to;
- WORD sym_x;
- WORD sym_y;
-
- FUNCTION
- This is a subset of the Transform function. It simple scales some
- vertices. It is done with 16-bit integer arithmetic with the
- accuracy that it permits. The scaling factor is computed as:
- sx = from->x/to, and sy=from->y/to->y.
- Use sym_x and sym_y to improve the symmetry of the points, e.g. a
- square that is centered over some coordinate are guaranteed to stay
- centered after the scaling if the sym_x and sym_y are set to be that
- coordinate.
-
- INPUTS
- vertices = The vertices that you want to scale.
- from = A {dx, dy} pair that represents the original size.
- to = A {dx, dy} pair the represents the desired size.
- sym_x = Vertical symmetry line. Points that are at equal distance
- horizontally will be that also after the scaling.
- sym_y = Horizontal symmetry line. Points that are at equal distance
- vertically will be that also after the scaling.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- /vfont/fixpoint.h, /vfont/fixsin.h, Transform, Rotate, Transpose.
-
-
-
- vFont.library/Transpose
-
- NAME
- Transpose -- Move a number of vertices.
-
- SYNOPSIS
- Transpose(vertices, cnt, tx, ty)
- A0 D1 D2 D3
-
- Point *vertices;
- ULONG cnt;
- FIX a;
- WORD tx;
- WORD ty;
-
- FUNCTION
- This is a subset of the Transform function. It simple moves some
- vertices.
-
- INPUTS
- vertices = The vertices that you want to move.
- cnt = The number of vertices that you want to move.
- tx = The horizontal distance to that the vertices should be moved.
- ty = The vertical distance to that the vertices should be moved.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- /vfont/fixpoint.h, /vfont/fixsin.h, Transform, Scale, Rotate.
-
-
-
- vFont.library/Bend
-
-
- NAME
- Bend -- Create a spline out of some vertices.
-
- SYNOPSIS
- success = Bend(pts, r, e, curve)
- D0 A0 D1 D2 D3
-
- ULONG success;
- Points *pts;
- UBYTE r;
- UBYTE e;
- ULONG curve;
-
- FUNCTION
- This function attempts to create a spline. The
- original definition curve will be lost after this
- function call, and the spline curve will be found
- in its place if there was enough space for it.
-
- INPUTS
- pts = This is where you put the lines that you wishes to bend.
- Make sure that you initiate this structure properly with
- enough extra space. It must contain at least two points!
- r = This value indicate how well you wish the resulting spline
- should conforms the original lines. A low value will
- generate a spline that is close to original lines. It should
- be in the interval 0-255. A 60-70 will generate a perfect
- circle out of a square.
- e = This value indicate how smooth or rough the spline should
- be. A high value will leave the lines as they were, and a
- low value will generate a spline that is as smooth as
- possible. This value is highly related to the time that it
- takes to conform lines to a spline. It should always be
- between 0-255.
- curve = This is a flag that indicates whether this spline should
- be a curve, i.e. no end points, or not.
-
- RESULT
- success = TRUE if the operation succeeded, and FALSE otherwise.
- The result in pts should never be used if this function
- returns FALSE.
- pts = The created spline.
-
- BUGS
- None known.
-
- SEE ALSO
- Widen
-
-
- vFont.library/Cross
-
- NAME
- Cross -- Determine if and where two lines intersect.
-
- SYNOPSIS
- hit = Cross(l1, l2, p)
- D0 A0, A1, A2
-
- ULONG hit;
- line *l1;
- line *l2;
- Point *p;
-
- FUNCTION
- This function will first determine if the specified lines
- intersect and then calculate where if they do intersect. The
- result will be stored in a, by the user allocated, Point
- structure.
-
- INPUTS
- l1 = One of the intersecting lines.
- l2 = The other intersecting line.
-
- RESULT
- hit = TRUE if the lines intersect.
- p = The position where the lines intersect. NOTE! P MUST BE
- ALLOCATED BY THE USER! The value in p is only valid if the
- function returns TRUE.
-
- BUGS
- None known.
-
- SEE ALSO
- Nothing.
-
-
- vFont.library/Widen
-
-
- NAME
- Widen -- Create a thick line.
-
- SYNOPSIS
- Widen(vertices, cnt, l1, l2, t)
- A0 D1 A1 A2 D2
-
-
- Point *vertices;
- ULONG cnt;
- Points *l1;
- Points *l2;
- WORD t;
-
- FUNCTION
- This function takes some vertices and fills in l1 and l2 with
- the lines that are at an orthogonal distance of t/2 from the
- original line. NOTE! Make sure that you initiates l1 and l2 with
- sufficient memory to hold at least a copy of the original
- vertices.
-
- INPUTS
- cnt = The number of vertices.
- vertices = The original points.
- t = The width of the resulting line.
-
- RESULT
- l1 = One side of the line.
- l2 = The other side of it.
-
- BUGS
- Yes.
-
- SEE ALSO
- Bend
-
-
- vFont.library/PolyCDraw
-
- NAME
- PolyCDraw -- Draw the contour of a thick line into a RastPort.
-
- SYNOPSIS
- PolyCDraw(rp, vertices, cnt, t)
- A0 A1 D1 D2
-
- struct RastPort *rp;
- Point *vertices;
- ULONG cnt;
- WORD t;
-
- FUNCTION
- This function draws a line just like PolyDraw, with the
- difference that the line be the contour of a line with a
- width. PolyCDraw uses the same stuff in the rastport as
- PolyDraw, e.g. FgPen, BgPen, cp_x, cp_y, DrawMode,
- LinePtrn etc.
-
- INPUTS
- rp = The rastport to draw in.
- cnt = The number of vertices to draw.
- vertices = The vertices to draw.
- t = The width of the line.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- graphics.library/PolyDraw, PolyACDraw
-
- vFont.library/PolyACDraw
-
- NAME
- PolyACDraw -- Draw a thick solid line into a RastPort.
-
- SYNOPSIS
- PolyACDraw(rp, vertices, cnt, t)
- A0 A1 D1 D2
-
- struct RastPort *rp;
- Point *vertices;
- ULONG cnt;
- WORD t;
-
- FUNCTION
- This function draws a line just like PolyDraw, with the
- difference that the line be a solid line with a width.
- PolyACDraw uses the same stuff in the rastport as PolyDraw,
- e.g. FgPen, BgPen, cp_x, cp_y, DrawMode, AreaPtrn etc.
- NOTE! Make sure that you set up the AreaInfo and the TmpRas
- in the rastport before you use this function.
-
- INPUTS
- rp = The rastport to draw in.
- vertices = The vertices to draw.
- cnt = The number of vertices to draw.
- t = The width of the line.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- graphics.library/PolyDraw, PolyACDraw
-
- vFont.library/DrawCurve
-
- NAME
- DrawCurve -- Draws a specified curve into the RastPort
-
- SYNOPSIS
- DrawCurve(rp, curve, x, y)
- A0 A1 D1 D2
-
- struct RastPort *rp;
- Curve *curve;
- WORD x;
- WORD y;
-
- FUNCTION
- First, sets up the DrawMode and Pens in the RastPort
- according to the arguments of the Curve structure. Then,
- draws the vectors of the Curve argument into the RastPort,
- offset by the x and y Offsets. As with all graphics
- rendering routines, the border will be clipped to to the
- boundaries of the RastPort's layer, if it exists. This is
- the case with Windows' RastPort. Different types of curves
- can be drawn depending on the bits set in the Flags part of
- the Curve structure. The following types of curves exists:
- CF_CONTOUR:
- CF_BORDER:
- CF_LINE:
- CF_CURVE:
- CF_DOTTED:
- CF_STRAIGHT:
-
- INPUTS
- rp = The RastPort.
- curve = The curve to draw.
- x = The left offset.
- y = The top offset.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- vfont/curve.h, intuition.library/DrawBorder
-
- vFont.library/VText
-
- NAME
- VText -- Write a text string into the RastPort.
-
- SYNOPSIS
- VText(rp, text, length)
- A0 A1 D1
-
- struct RastPort *rp;
- UBYTE *text;
- ULONG length;
-
- FUNCTION
-
- Write some text into a RastPort. It uses all the relevant parts
- of RastPort, such as DrawMode FgPen etc. You should set a font
- for this RastPort with a SetVFont call before you call this
- function. The function will use the font set for this RastPort
- with the graphics.library function SetFont if no font has been
- set with SetVFont.
-
- VText is 100% compatible with the graphics.library function
- Text. The big difference between VText and Text is that VText
- can render text in any direction, while Text can only render
- text in a left to right (or right to left) fashion. They can
- both render text using a standard bitmap font (struct TextFont)
- or a vfont.library font (VFont). Make sure that all characters,
- when using a vfont with Text, in the font is cached (See other
- technical documentation about mapping and caching vfont's). An
- easy way is to open the font with the OpenBFont function.
-
- INPUTS
- rp = The RastPort.
- text = The text.
- length = Number of characters to write.
-
- RESULT
- None
-
- BUGS
- VText is implemented by using the graphics.library function
- BltTemplate, which will always clip against a layer. Using a
- rastport without a layer has two effects; it will make the
- rendering 30% faster, but will result in garbage under Kickstart
- 1.3. This has been fixed under Kickstart 2.0+. This means that
- printing characters directly on a screen's rastport will result
- in garbage, although quite fast.
-
- SEE ALSO
- graphics.library/Text
-
- vFont.library/VTextLength
-
- NAME
- VTextLength -- Estimate the length of a text string.
-
- SYNOPSIS
- length = VTextLength(vfont, text, count)
- D0 A0 A1 D0
-
- ULONG length;
- VFont *vfont;
- UBYTE *text;
- UWORD count;
-
- FUNCTION
- Estimate the length of the baseline for the text string. NOTE!
- IT RETURNS THE WIDTH NEEDED IF THE FONT IS USED HORIZONTALLY!
- This function does not concern itself with the path direction
- for the vector font, so you have to convert the length of the
- baseline to the width that the string will occupy when rendered
- in the chosen direction:
- x_distance=VTextLength(vfont, "testing..")*Cos(vfont->AlfaPath);
-
- Characters in the string that are not defined in the font are
- assumed to be rendered as the special undef-character of the
- font, and are therefor assumed to have that width. Make sure
- that you replace non-printable characters in the string, e.g.
- tabs etc., if you know that they should NOT be rendered as the
- undef-character.
-
- INPUTS
- vfont = The vector font.
- text = A null terminated text string.
- count = The number of characters in the string. A -1 will cause
- the function to first count the characters in the string
- up to the first '\0' character in the string.
-
- RESULT
- length = The length.
-
- BUGS
- None known.
-
- SEE ALSO
- VTextRoof
-
- vFont.library/VTextRoof
-
- NAME
- VTextRoof -- Estimate the height of a text string.
-
- SYNOPSIS
- height = VTextRoof(vfont, text)
- D0 A0 A1
-
- ULONG height;
- VFont *vfont;
- UBYTE *text;
-
- FUNCTION
- Estimate the height of the text string, i.e. the minimum
- height that is required to fit in the text string using this
- font when set to horizontal rendering. This might be lower than
- the height of the font is the string contains characters that
- are low, e.g. "xxxx" or ".....".
-
- INPUTS
- vfont = The vector font.
- text = A null terminated text string.
-
- RESULT
- height = The height.
-
- BUGS
- None known.
-
- SEE ALSO
- VTextLength
-
- vFont.library/OpenBFont
-
- NAME
- OpenBFont -- Open a graphics.library bitmap font.
-
- SYNOPSIS
- font = OpenBFont(attr)
- D0 A0
-
- struct TextFont *font;
- (struct )Text(V)Attr *attr;
-
- FUNCTION
- This function will open a standard graphics.library bitmap
- compatible font, i.e. a VFont font that is fully mapped and
- cached or a plain bitmap font.
-
- The attr contains information about how this should be done.
- attr can be either a graphics.library/TextAttr structure or a
- vfont.library/TextVAttr structure. The TextVAttr structure is a
- superset of the TextAttr structure. They are distinguished by
- the sign bit of the YSize in the TextAttr which is a one bit
- flag in the TextVAttr (speaking in C-lingo). Setting this
- flag means that the structure should be interpreted as a
- vfont.library/TextVAttr structure.
-
- NOTE: Specifying a graphics.library/TextAttr with a negative YSize
- will fool the function to believe that the structure is a TextVAttr
- and will result in unpredictable results. Since a negative size is
- illegal anyway that should not surprise you!
-
- This function is 100% compatible with diskfont.library/OpenDiskFont and
- graphics.library/OpenFont.
-
- INPUTS
- attr = The requirements, such as size, path etc.
-
- TextAttr: See documentation for graphics.library!
- TextVAttr {
- UBYTE *Name; /* The name of the class or bitmap font. */
- unsigned VectorFont : 1; /* Always TRUE. */
- unsigned YSize : 15; /* The height. (0-32768) */
- UBYTE Style; /* The desired style. */
- UBYTE Flags; /* Flags. */
- UBYTE *FontName; /* The vector font name. */
- UBYTE *Author; /* The name of the author. */
- UWORD XSize; /* Horizontal size. */
- UWORD VFlags; /* Flags for vector fonts. */
- }
-
- Name:
- The Name can have the '.font' or the '.vfont' or neither
- extensions. It can also include a path to the font. The 'fonts:'
- path will be appended to the name if the font can not be found under
- the name and if the font is to be loaded from disk.
-
- VectorFont:
- This bit must always be set, or else will function ignore the four
- last fields in the structure.
-
- YSize, XSize:
- This is the desired size. One or both can be set to zero if the
- font is created from a vfont class. Setting one of them to zero
- will let the function set that size so that the vfont will have the
- same proportions as when it was created. Setting both to zero will
- open the vfont in the size that is was designed in (typically
- 256x256).
-
- Style:
- This describes what kind of style you want. It can be:
- FS_NORMAL
- FSF_EXTENDED
- FSF_ITALIC
- FSF_BOLD
- FSF_UNDERLINED
-
- Flags:
- This describes some of the properties of the font. It can be:
- FPF_ROMFONT
- FPF_DISKFONT
- FPF_REVPATH
- FPF_TALLDOT
- FPF_WIDEDOT
- FPF_PROPORTINAL
- FPF_DESIGNED
- FPF_REMOVED
-
- FontName:
- The name that the vector font instance should have. Not used by
- this function.
-
- Author:
- The name of the author. The function will allocate a string with
- the name of the author of the font if the font was loaded from
- disk. The memory will automatically be deallocated when the
- library is flushed. You can be nice to the system and deallocated
- the memory with the VFreeMem function when you are done with the
- name of the author.
-
- VFlags:
- This specifies properties that are specific to vector fonts. It can be:
- VFB_MUTE /* Don't report errors. */
- VFB_DEBUG /* Report debug information via SER: */
- VFB_VERBOSE /* Report errors to the user via intuition. */
- VFB_FLUSHCLASS /* Free the font class when it is no longer in use. */
- VFB_FLUSHFONTS /* Free the font when it is no longer in use. */
- VFB_MAPPED /* Build the instance immediately. */
- VFB_EXCLUSIVE /* Don't let other use this font. */
- VFB_FORCED /* Use locked font classes by force. */
- VFB_NOCONVERT /* Do not try and convert another type of font. */
- VFB_ANYSIZE /* Use a best fit font if there is no exact match. */
-
- RESULT
-
- font = A graphics.library bitmap font that is ready to be used with
- graphics.library function such as SetFont.
-
- BUGS
- None known.
-
- SEE ALSO
- OpenVFont, graphics.library/OpenFont, diskfont.library/OpenDiskFont.
-
- vFont.library/OpenVFont
-
- NAME
- OpenVFont -- Open a vfont.library vector font.
-
- SYNOPSIS
- font = OpenVFont(attr)
- D0 A0
-
- VFont *font;
- (struct )Text(V)Attr *attr;
-
- FUNCTION
- This function will open a vfont.library vector font. The attr
- contains information about how this should be done. attr can be
- either a graphics.library/TextAttr structure or a
- vfont.library/TextVAttr structure. The TextVAttr structure is a
- superset of the TextAttr structure. They are distinguished by
- the sign bit of the YSize in the TextAttr which is a one bit
- flag in the TextVAttr. Setting this will means that the
- structure should be interpreted as a vfont.library/TextVAttr
- structure.
-
- NOTE: Specifying a graphics.library/TextAttr with a negative YSize
- will fool the function to believe that the structure is a TextVAttr
- and will result in unpredictable results. Since a negative size is
- illegal anyway that should not surprise you!
-
- The function will try to do in the following order:
- 1) Reuse an old font if the is a sharable font that
- maps the description of attr.
- 2) instanciate a vfont class or...
- 3) Call LoadVFont first and then try step 2 again.
- 4) Fail.
-
- The function will use default values for the four last fields of
- 'attr' if it is a graphics.library/TextAttr structure:
- FontName: Default=The name of the class.
- VFlags: Default=VFB_VERBOSE|VFB_EXCLUSIVE
- XSize: Default=0 (See OpenBFont for description on zero sizes.)
-
-
- INPUTS
- attr = The requirements, such as size, path etc.
-
- TextAttr: See documentation for graphics.library!
- TextVAttr: See OpenBFont
-
- RESULT
-
- font = A vfont.library vector font that is ready to be used.
-
- BUGS
- None known.
-
- SEE ALSO
- OpenBFont, graphics.library/OpenFont, diskfont.library/OpenDiskFont.
-
- vFont.library/GetVFont
-
- NAME
- GetVFont -- Retrieve the current vector font in a RastPort.
-
- SYNOPSIS
- vfont = GetVFont(rp)
- D0 A0
-
- VFont *vfont;
- struct RastPort *rp;
-
- FUNCTION
- This is the only way for you to know which vector font is
- being used in a RastPort because that information is private to
- vfont.library.
-
- INPUTS
- rp = The RastPort.
-
- RESULT
- vfont = The vector font.
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/SetVFont
-
- NAME
- SetVFont -- Set the current vector font for a RastPort.
-
- SYNOPSIS
- SetVFont(rp, vfont)
- A0 A1
-
- VFont *vfont;
- struct RastPort *rp;
-
- FUNCTION
- Set current vector font for a RastPort.
-
- INPUTS
- rp = The RastPort.
- vfont = The vector font.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/MakeChar
-
- NAME
- MakeChar -- Rebuild a character in a font.
-
- SYNOPSIS
- MakeChar(vfont, class, character)
- A0 A1 D1
-
- VFont *vfont;
- VFontClass *class;
- WORD character;
-
- FUNCTION
- This function will rebuild a character by using the
- description of that character that is found in a font
- class. There is no requirement that this font class must be
- the same class that was used when the font was created,
- e.g. you could create a font that has the general
- appearance of Times-Roman except for the digits which looks
- like Helvetica. Another use of this function is to
- manipulate the bitmap cache, i.e. you first call
- UnmapVFont and then explicitly make the most commonly used
- character first so that they will use the cache. (See other
- documentation about caching and mapping fonts and classes.)
-
- NOTE! No action is taken if the character is already
- mapped.
-
- INPUTS
- vfont = The vector font that you want to modify.
- class = The class that should be used.
- character = The character to build.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/ChangeVFont
-
- NAME
- ChangeVFont -- Change the characteristics of a vector font.
-
- SYNOPSIS
- ChangeVFont(vfont, mask, req, mapped)
- A0 D1 A1 D2
-
- VFont *vfont;
- UBYTE mask;
- VFont *req;
- ULONG mapped;
-
- FUNCTION
- This is the major manipulation function for vector fonts.
- Fill in the your preferences for the font in req and set the
- according bits in mask before you call this function.
-
- INPUTS
- vfont = The vector font that you want to modify.
- mask = What values you want to change.
- req = A font with the desired values.
- mapped = TRUE if the font should be mapped.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/ReThinkVFont
-
- NAME
- ReThinkVFont -- Rebuild a vector font.
-
- SYNOPSIS
- ReThinkVFont(vfont)
- A0
-
- VFont *vfont;
-
- FUNCTION
- Rebuild a vector font from its class. Might be time consuming.
-
- INPUTS
- vfont = The vector font to rebuild.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/UnmapVFont
-
- NAME
- UnmapVFont -- Invalidate a vector font.
-
- SYNOPSIS
- UnmapVFont(vfont)
- A0
-
- VFont *vfont;
-
- FUNCTION
- Set the dirty bit in each and every character in the vector
- font so that they have to be rebuild the next time they are used.
-
- INPUTS
- vfont = The vector font.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/LockVFont
-
- NAME
- LockVFont -- Make a vector font private.
-
- SYNOPSIS
- lock = LockVFont(vfont, busywait)
- D0 A0 D1
-
- ULONG lock;
- VFont *vfont;
- ULONG busywait;
-
- FUNCTION
- Attempt lock a font for private use only. The function will
- return a non zero value immediately if it succeeded or if
- busywait is FALSE.
-
- INPUTS
- vfont = The vector font to lock.
- busywait = FALSE if the call should return immediately, regardless
- if it succeeded or not.
-
- RESULT
- lock = A lock value that should be used when the font is unlocked.
-
- BUGS
- Not implemented yet.
-
- SEE ALSO
- *
-
- vFont.library/UnLockVFont
-
- NAME
- UnLockVFont -- Make a font public.
-
- SYNOPSIS
- UnLockVFont(vfont, lock)
- A0 D1
-
- VFont *vfont;
- ULONG lock;
-
- FUNCTION
- Attempt lock a font for public use again.
-
- INPUTS
- vfont = The vector font to lock.
- lock = A lock from a previous LockVFont call.
-
- RESULT
- None
-
- BUGS
- Not implemented yet.
-
- SEE ALSO
- *
-
- vFont.library/PrintVText
-
- NAME
- PrintVText -- Write a vector text into a RastPort.
-
- SYNOPSIS
- PrintVText(rp, vtext)
- A0 A1
-
- struct RastPort *rp;
- VectorText *vtext;
-
- FUNCTION
- Write a text, using the information that is specified in the
- VectorText structure, into a RastPort.
-
- INPUTS
- rp = The RastPort.
- vtext = The VectorText to print in the RastPort.
-
- RESULT
- None
-
- BUGS
- Not implemented yet.
-
- SEE ALSO
- *
-
- vFont.library/CloseVFont
-
- NAME
- CloseVFont -- Close a vector font.
-
- SYNOPSIS
- CloseVFont(vfont)
- A0
-
- VFont *vfont;
-
- FUNCTION
- Use this function just like CloseFont. The font will be disposed
- if there is nobody else using it.
-
- INPUTS
- vfont = The vector font to close.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/LoadVFont
-
- NAME
- LoadVFont -- Load a disk based vector font class.
-
- SYNOPSIS
- author = LoadVFont(tva)
- D0 A0
-
- (struct )Text(V)Attr *tva;
- UBYTE *author;
-
- FUNCTION
- Attempt to load a font class from disk. It will attempt to
- locate a FontContents file (files in the fonts: directory
- that has the .font extension) that matches the name used in
- the tva parameter. It will then scan through the file and
- look for an entry that matches the description as good as
- possible. If the entry in the file contains information
- about the font format then it will open the appropriate
- xdf-library and let that library load the font. The
- default library that is used if there is no information
- about the font format is the xdf_diskfont.library.
-
- INPUTS
- tva = A description of the font class to load.
- author = The name of the author of the font class.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- ReportStatus, SaveVFont.
-
- vFont.library/SaveVFont
-
- NAME
- SaveVFont -- Save a disk based font class.
-
- SYNOPSIS
- done = SaveVFont(tva)
- D0 A0
-
- (struct )Text(V)Attr *tva;
- ULONG done;
-
- FUNCTION
- Attempt to save a font class on disk. First it will try and
- locate the resident font class or fail if it canĀ“t. It will
- then attempt to locate a FontContents file (files in the
- fonts: directory that has the .font extension) that
- matches the name used in the tva parameter. A new
- directory and/or FontContents file will be created if they
- are missing. The appropriate xdf-library will then be used
- to save the actual class, which will then be added to the
- FontContents file, using the SaveFontAttr function.
-
- INPUTS
- tva = A description of the font class to be saved.
-
- RESULT
- done = TRUE if the operation was successful.
-
- BUGS
- None known.
-
- SEE ALSO
- ReportStatus, LoadVFont.
-
- vFont.library/SetVRendering
-
- NAME
- SetVRendering -- Set the color attributes for color vector fonts.
-
- SYNOPSIS
- SetVRendering(vfont, ???)
-
- FUNCTION
-
- INPUTS
-
- RESULT
- None
-
- BUGS
- Not implemented yet.
-
- SEE ALSO
- *
-
- vFont.library/ReportStatus
-
- NAME
- ReportStatus -- Choose how verbose error messages you want.
-
- SYNOPSIS
- ReportStatus(kind)
- D1
-
- WORD kind;
-
- FUNCTION
- The vFont.library will brief the user about system problems if it
- can find the req.library and if this function has been used to
- enable that. Set kind to VFB_DEBUG if you would like to get debug
- information, via SER: 9600 baud, about the usage of the library. Set
- kind to VFB_VERBOSE if you would like to get error messages via
- requesters, or set kind to VFB_MUTE if you don't want any reports
- at all.
-
- INPUTS
- kind = VFB_MUTE, VFB_DEBUG, VFB_VERBOSE or VFB_DEBUG|VFB_VERBOSE.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/FlushWhat
-
- NAME
- FlushWhat -- Specify if fonts or classes should be flushed.
-
- SYNOPSIS
- FlushWhat(kind)
- D1
-
- WORD kind;
-
- FUNCTION
- When a font is no longer in use there is an option to
- either release the memory used for the font or to keep it
- so that the font does not have to be loaded the next time
- it is going to be used. Use this function to set that
- option.
-
- INPUTS
- kind = 0L, VFB_FLUSHFONT, VFB_FLUSHCLASS or both.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/NewVFontContents
-
- NAME
- NewVFontContents -- Build a new FontContents structure.
-
- SYNOPSIS
- NewVFontContents(dir, header)
- A0 A1
-
- BPTR dir;
- UBYTE *header;
-
- FUNCTION
- This function will attempt to build a FontContents
- structure for the a font that is located in a sub-directory
- of dir named as header, minus the ".font" extension. It
- will try all the xdf-libraries to do this. (See
- diskfont.library/NewFontContents for a detailed
- description.)
-
- INPUTS
- dir = A file lock to the font directory (Normally FONTS:).
- header = The name of the font, plus the ".font" extension.
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/SaveFontAttr
-
- NAME
- SaveFontAttr -- Add a font entry to a FontContents file.
-
- SYNOPSIS
- SaveFontAttr(info,name,size,flags,style,type,forced)
- D1 A0 D2 D3 D4 A1 D5
-
- BPTR info;
- UBYTE *name;
- UWORD size;
- UBYTE flags;
- UBYTE style;
- UBYTE *type;
- BOOL forced;
-
- FUNCTION
- Use this function to a a new font class entry to a
- FontContents file.
-
- INPUTS
- info = A BPTR to the FontContents file.
- name = The name of the font file to add, such as "Times/11".
- size = Size of the font.
- flags = Font flags (See graphics.library documentation).
- style = Font style (--""--)
- type = The name of the XDF library, minus the prefix and suffix.
- forced = TRUE if you are sure that it is okay to overwrite an old
- entry in the FontContents file.
-
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-
- vFont.library/FlushFonts
-
- NAME
- FlushFonts -- Flush unused fonts and classes.
-
- SYNOPSIS
- FlushFonts(what)
- D1
-
- UWORD what;
-
- FUNCTION
- Use this function to remove unused fonts and/or classes
- from the library and release the memory that it occupies.
-
- INPUTS
- what = VFB_FLUSHFONT|VFB_FLUSHCLASS
-
- RESULT
- None
-
- BUGS
- None known.
-
- SEE ALSO
- *
-