The scene above provides a simple example of using some of the special text-based objects that come with CiteMap Builder. These objects have "built-in" text annotation, which can replace the need for a label, or augment the label information.
The text properties for each object are accessed via the PROTO fields (Advanced) tab of the Tricon (Object) Attributes screen. There are three basic knobs: TextCol, TextSiz, and TextStr.
Text Color (TextCol)
This is the diffuseColor for the text. A value should be defined which
contrasts with the object's color. This can sometimes take a little
tweaking. TextCol is a SFColor field, which requires three floating
point numbers between 0 and 1, representing the fraction of red,
green, and blue to be applied. Black is 0 0 0 and white is 1 1 1.
Red is 1 0 0, Green is 0 1 0, and Blue is 0 0 1.
Text Size (TextSiz)
The size value is generally less than 1.0. It is usually best to try the
default, then adjust slightly as desired.
Text String Contents (TextStr)
This contains the words that make up the text annotation. This field
is an MFString. Examples of some valid MFStrings, with their results, are
given below:
- - -
MFString "some text"
some text
- - -
MFString ["some text"]
some text
- - -
MFString ["some","text"]
some
text
- - -
MFString ["some",
"text"]
some
text
- - -
MFString ["some","","text"]
some
text
- - -
MFString ["This game","","is easy!"]
This game
is easy!
- - -
In general, the only character that cannot be included verbatim within a text string is the quote sign ("). There is a way to "escape" this character so that it will be included correctly: put a backslash in front of the quote sign. Although it can be hard to follow, here is an example of making a quoted string:
- - - MFString ["Fred said:","\"Exactly!\""] Fred said: "Exactly!" - - -
One final note: the non-advanced fields for the CiteMap attributes, such as the label, title, and abstract fields do not need all the delimiters of the MFString - they are automatically applied. Also, the backslash escape will be added automatically by the code if a quote sign is included in a non-advanced field. In other words, the only place you'll need to hassle with the MFString delimiter stuff is in the advanced PROTO fields option.
Here is the CiteMap Builder CMB file for this example: TxtObj.cmb (right click to download).