Skip to main content

SpecialCharacterInfo

SpecialCharacterInfo (notebookNameStr, specialCharacterNameStr, whichStr)

The SpecialCharacterInfo function returns a string containing information about the named special character in the named notebook window.

Parameters

If notebookNameStr is "", the top visible notebook is used. Otherwise notebookNameStr contains either kwTopWin for the top notebook window, the name of a notebook window or a host-child specification (an hcSpec) such as Panel0#nb0. See Subwindow Syntax for details on host-child specifications.

specialCharacterNameStr is the name of a special character in the notebook.

If specialCharacterNameStr is "" and if exactly one special character is selected, the selected special character is used. If other than exactly one special character is selected, an error is returned.

whichStr identifies the information item you want. Because SpecialCharacterInfo can return several items that may contain semicolons, it does not return a semicolon-separated keyword-value list like other info functions. Instead it returns just one item as specified by whichStr.

Details

Here are the supported values for whichStr.

KeywordReturned Action Information
NAMEThe name of the special character.
FRAMEValue of the frame property: 0 = none; 1 = single; 2 = double; 3 = triple; 4 = shadow.
LOCParagraph and character position (e.g., 1,3).
SCALINGHorizontal and vertical scaling in units of one tenth of a percent (e.g., 1000,1000).
TYPESpecial character type is: Picture, Graph, Table, Layout, Action, ShortDate, LongDate, AbbreviatedDate, Time, Page, TotalPages, or WindowTitle.

These keywords apply to Igor-object pictures only. If the specified special character is not an Igor-object picture, "" is returned.

KeywordReturned Action Information
WINTYPEReturns a window type code: 1 for graphs, 2 for tables, 3 for layouts.
OBJECTNAMEReturns the name of the window with which the special character is associated.

The remaining keywords apply to notebook action characters only. If the specified special character is not a notebook action character, "" is returned.

KeywordReturned Action Information
BGRGBBackground color in RGB format (e.g., 65535,65534,49151).
COMMANDSCommand string.
ENABLEBGRGB1 if the action's background color is enabled, 0 if not.
HELPTEXTHelp text string.
IGNOREERRORS0 or 1.
LINKSTYLE0 or 1.
PADDINGThe value of the left, right, top, bottom and internal padding properties, in that order (.e.g, 4,4,4,4,8).
PICTURE1 if the action has a picture, 0 if not.
PROCPICTNAMEThe name of the action Proc Picture or "" if none.
QUIET0 or 1.
SHOWMODEShow mode property:
1:Display title only
2:Display picture only
3:Display picture below title
4:Display picture above title
5:Display picture to the left of title
6:Display picture to the right of title
TITLETitle string.

If whichStr is an unknown keyword, SpecialCharacterInfo returns "" but does not generate an error.

Examples

Function PrintSpecialCharacterInfo(notebookName, specialCharacterName)
String notebookName, specialCharacterName

String typeStr = SpecialCharacterInfo(notebookName, specialCharacterName, "TYPE")
String locStr = SpecialCharacterInfo(notebookName, specialCharacterName, "LOC")

Printf "TYPE: %s\r", typeStr
Printf "LOC: %s\r", locStr
End

See Also

Notebook, NotebookAction, SpecialCharacterList, Using Igor-Object Pictures