\begindata{text,538442812} \textdsversion{12} \template{default} \define{fixedtext

\begindata{text,538442812}
\textdsversion{12}
\template{default}
\define{fixedtext
menu:[Region~4,Fixedtext]
attr:[Justification LeftJustified Point 0]
attr:[FontFace FixedFace Int Set]
attr:[FontFamily AndyType Int 0]
attr:[FontSize ConstantFontSize Point 10]}
\define{fixedindent
menu:[Region~4,Fixedindent]
attr:[LeftMargin LeftMargin Cm 83230]
attr:[Justification LeftJustified Point 0]
attr:[FontFace FixedFace Int Set]
attr:[FontFamily AndyType Int 0]
attr:[FontSize ConstantFontSize Point 10]}
\define{paramname
menu:[Font~1,Paramname]
attr:[FontFace Italic Int Set]}
\define{fieldheading
menu:[Region~4,Fieldheading]
attr:[Justification LeftJustified Point 0]
attr:[FontFace Bold Int Set]
attr:[FontFamily AndySans Int 0]
attr:[FontSize ConstantFontSize Point 10]}
\define{fieldtext
menu:[Region~4,Fieldtext]
attr:[LeftMargin LeftMargin Cm 83230]
attr:[Justification LeftJustified Point 0]
attr:[FontFamily AndySans Int 0]
attr:[FontSize ConstantFontSize Point 10]}
\section{\paramname{textview}}
The class\italic{ \paramname{textview}} (text view) provides the methods
can
class procedures needed to view \italic{text} on a workstation screen and
to
edit that \italic{text}.
\section{About this section}
The class \paramname{textview} is a subclass of \paramname{view} and
\paramname{observable}. This section assumes you are familiar with the
following:
-- class
-- view
-- observable
-- text
This section is related to the sections \italic{text,}
\italic{environment},
and \italic{style.} \italic{Example 14}, \italic{Vol. 1}, illustrates
how to
use \italic{text/textview} in an application program. \italic{Example
15},
\italic{Vol. 1}, illustrates how to format \italic{text} using
\italic{environment} and \italic{style}.
\section{About \paramname{textview}}
\paragraph{The dot}
The dot is used to represent (1) the current position of the text caret
and
(2) the starting position and length of a selected region. The dot has a
position and a length. The length is zero when the user sees the text
caret;
positive when the user creates a selected region. Normally, the
characters
that a user types should be inserted at the dot's position; likewise
formatting commands should be take effect from the dot's starting
position to
its length.
\begindata{bp,538271496}
\enddata{bp,538271496}
\view{bpv,538271496,206,0,0}
\section{\paramname{textview} functions}
______________________________________________________
\paragraph{textview_CanView}
\majorheading{Check whether textview can view the object}
______________________________________________________
\fixedtext{boolean \bold{textview_CanView }(}\fixedindent{
struct textview *\paramname{textview},
char *\paramname{TypeName});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Checks whether \paramname{textview} can view the dataobject
specified by \paramname{TypeName} by comparing its type to "text."
}
\fieldheading{Return Value}
\fieldtext{TRUE if \paramname{textview} can view \paramname{TypeName;}
FALSE
otherwise.}
\fieldheading{See Also}
\fieldtext{\paramname{class_IsTypeByName} (class/doc/class.doc).}
\begindata{bp,538271560}
\enddata{bp,538271560}
\view{bpv,538271560,207,0,0}
______________________________________________________
\paragraph{textview_CollapseDot}
\majorheading{Collapse the dot by setting the dot length to zero}
______________________________________________________
\fixedtext{void \bold{textview_CollapseDot }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Collapses \paramname{textview}'s dot by setting the dot length
to
zero.
}
\fieldheading{Side Effects}
\fieldtext{Sets the position of \paramname{textview}'s dot to the old
position
plus the old length.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_GetDotLength},
\paramname{textview_GetDotPosition}, \paramname{textview_FrameDot},
\paramname{textview_SetDotLength}, \paramname{textview_SetDotPosition}.}
\view{bpv,538271560,208,0,0}
______________________________________________________
\paragraph{textview_DeleteApplicationLayer}
\majorheading{Delete the application layer, namely, the scroll bar}
______________________________________________________
\fixedtext{void \bold{textview_DeleteApplicationLayer }(}\fixedindent{
struct textview *\paramname{textview},
struct view *\paramname{scrollbar});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Deletes \paramname{scrollbar},
application
layer.}
\paramname{textview}'s
\fieldheading{Side Effects}
\fieldtext{Sets \paramname{textview}'s field
\paramname{hasApplicationLayer}
to FALSE.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_GetApplicationLayer. }For a discussion of
application layers, see atk/basics/common/view.doc.}
\view{bpv,538271560,209,0,0}
______________________________________________________
\paragraph{textview_DesiredSize}
\majorheading{Negotiates the desired size of textview with a parent view}
______________________________________________________
\fixedtext{enum view_DSattributes \bold{textview_DesiredSize
}(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{width},
long \paramname{height},
enum view_DSpass \paramname{pass},
long *\paramname{dWidth},
long *\paramname{dHeight});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Conducts size negotiations between a parent view and
\paramname{textview}. The parameters \italic{\paramname{width} and
\paramname{height}} are the parent view's preferred width and height;
the
parameter \italic{\paramname{pass}} allows the parent view to tell
\paramname{textview} which parameters are flexible and which are fixed.
It
can take on one of three values:
\leftindent{\description{\fixedindent{\smaller{view_NoSe}t\formatnote{@\\
}Both
dimensions are flexible.
\smaller{view_}WidthSet\formatnote{@\\}The width cannot be changed.
\smaller{view_}HeightSet\formatnote{@\\}The height cannot be changed.}
}
}
In response to these three parameters,
\paramname{text\italic{view_DesiredSize}}
sets \italic{\paramname{dWidth}} and
\paramname{\paramname{dHeigh}t}\italic{,
which indicate }what \paramname{textview} desires as its width and
height.
}
\fieldheading{Return Value}
\fieldtext{The return value is an \smaller{OR-ed} combination two
\italic{\paramname{DSattributes}}, \paramname{view_WidthFlexible} |
\paramname{view_HeightFlexible}, indicating that both
\paramname{textview}'s
width and height are flexible.}
\fieldheading{Usage}
\fieldtext{Call \paramname{textview_DesiredSize} if you want a parent
view to
negotiate a \paramname{textview}'s size. You can call it several times.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_GetTextSize},
\paramname{textview_WantNewSize},
and \paramname{view_DesiredSize} (atk/basics/common/view.doc).}
\view{bpv,538271560,210,0,0}
______________________________________________________
\paragraph{textview_FinalizeObject}
\majorheading{Finalize the textview object}
______________________________________________________
\fixedtext{void \bold{textview_FinalizeObject }(}
\fixedindent{struct textview *textview);}
\fieldheading{Category}
\fieldtext{Classprocedure}
\fieldheading{Description}
\fieldtext{Deletes \paramname{textview} and any data pointed to by
\paramname{textview} (e.g., styles, view references, etc.)
}\fieldheading{Usage}\fieldtext{
Use this to delete instances of \paramname{textview}.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_InitializeObject};
\paramname{FinalizeObject}
(class/doc/class.doc).}
\view{bpv,538271560,211,0,0}
______________________________________________________
\paragraph{textview_FindLineNumber}
\majorheading{Find a line number}
______________________________________________________
\fixedtext{long \bold{textview_FindLineNumber }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{pos});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Finds the line number associated with position
\italic{\paramname{pos} in \paramname{textview}.
}}
\fieldheading{Return Value}
\fieldtext{The line number, 0 <= i <= number of lines; -1 upon error.}
\view{bpv,538271560,212,0,0}
______________________________________________________
\paragraph{textview_FrameDot}
\majorheading{Set the frame dot mark}
______________________________________________________
\fixedtext{void \bold{textview_FrameDot }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{pos});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Sets \paramname{textview}'s frame dot mark to \paramname{pos}.
}
\fieldheading{Usage}
\fieldtext{Call only to ensure that \italic{\paramname{pos}} will be
visible
on the screen after the next update.}
\view{bpv,538271560,213,0,0}
______________________________________________________
\paragraph{textview_FullUpdate}
\majorheading{Fully update the screen}
______________________________________________________
\fixedtext{void \bold{textview_FullUpdate }(}\fixedindent{
struct textview *\paramname{textview},
enum view_UpdateType \paramname{type},
long \paramname{left},
long \paramname{top},
long \paramname{width},
long \paramname{height});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Fully updates (i.e., redraws) the part the screen allocated to
\paramname{textview}. Ignores the parameters \paramname{type},
\paramname{left}, \paramname{top}, \paramname{width} and
\paramname{height}.
}
\fieldheading{Usage}
\fieldtext{If you are using \paramname{textview} as a child view, call
this
method when the parent view gets a \paramname{FullUpdate} request.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_Update}; \paramname{view_FullUpdate}
(atk/basics/common/view.doc).}
\view{bpv,538271560,214,0,0}
______________________________________________________
\paragraph{textview_GetApplicationLayer}
\majorheading{Get an application layer, namely, create a scroll bar}
______________________________________________________
\fixedtext{struct view *\bold{textview_GetApplicationLayer
}(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Get an application layer. In this case, if
\paramname{textview}->
\paramname{hasApplicationLayer} is set to TRUE, create a scrollbar on the
left
side of \paramname{textview}}\fieldtext{.}\fieldtext{
}
\fieldheading{Return Value}
\fieldtext{A pointer to the newly created scrollbar view; NULL upon
error.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_GetApplicationLayer. }For a discussion of
application layers, see atk/basics/common/view.doc.}
\view{bpv,538271560,215,0,0}
______________________________________________________
\paragraph{textview_GetClickPosition}
\majorheading{Help manage the selection region behavior for textview}
______________________________________________________
\fixedtext{void \bold{textview_GetClickPosition }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{position},
long \paramname{numberOfClicks},
enum view_MouseAction \paramname{action},
long \paramname{startLeft},
long \paramname{startRight},
long *\paramname{leftPos},
long *\paramname{rightPos});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Helps to manage the selection region behavior of
\paramname{textview}. The parameters are:
\fieldtext{\paramname{position} -- the position at which the user has
clicked
\paramname{numberOfClicks} -- the number of clicks (one, two or three).
\paramname{action} -view_LeftMovement)
the type of mouse action (view_LeftDown or
\paramname{startLeft}
-- the position of the old dot
\paramname{startRight} -- the position of the old dot plus the length of
the
old dot}
In response to these parameters,
\paramname{text\italic{view_GetClickPosition}}
sets \paramname{leftPos} to the position of the a new selection region
and
sets \paramname{rightPos} to the position of a new selection region plus
its
length. Note that the method does not actually change
\paramname{textview}'s
position.
}
\fieldheading{Usage}
\fieldtext{Used for managing mouse hits in \paramname{textview}. See
\paramname{help selection} for a description of mouse hit behavior for
\paramname{textview}.}
\view{bpv,538271560,216,0,0}
______________________________________________________
\paragraph{textview_GetDefaultStyle}
\majorheading{Get the default style}
______________________________________________________
\fixedtext{struct style *\bold{textview_GetDefaultStyle }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Gets \paramname{textview}'s default style.
}
\fieldheading{Return Value}
\fieldtext{A pointer to the default style.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_SetDefaultStyle}.}
\view{bpv,538271560,217,0,0}
______________________________________________________
\paragraph{textview_GetDotLength}
\majorheading{Get the length of the dot}
______________________________________________________
\fixedtext{long \bold{textview_GetDotLength }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Gets the length of \paramname{textview}'s dot.
}
\fieldheading{Return Value}
\fieldtext{The length of textview's dot, 0 < = length <= the length of
\paramname{textview}.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_SetDotLength}.}
\view{bpv,538271560,218,0,0}
______________________________________________________
\paragraph{textview_GetDotPosition}
\majorheading{Get the position of the dot}
______________________________________________________
\fixedtext{long \bold{textview_GetDotPosition }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Get the position of \paramname{textview}'s dot.}\fieldtext{
}
\fieldheading{Return Value}
\fieldtext{The position of \paramname{textview}'s dot, 0 < = position <=
the
length of \paramname{textview}.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_SetDotPosition}.}
\view{bpv,538271560,219,0,0}
______________________________________________________
\paragraph{textview_GetInterface}
\majorheading{Get the scroll bar interface}
______________________________________________________
\fixedtext{char *\bold{textview_GetInterface }(}\fixedindent{
struct textview *\paramname{textview},
char *\paramname{interfaceName});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{If \paramname{interfaceName} is "scroll,vertical," provides a
scrollbar interface for \paramname{textview}.}\fieldtext{
}
\fieldheading{Return Value}
\fieldtext{A scrollbar interface or NULL.
}
\fieldheading{See Also}
\fieldtext{See \paramname{Example 6, Scroll bars}
(atk/examples/ex6/example.doc) and \paramname{view_GetInterface}
(atk/basics/common/view.doc) for a discussion of the scroll bar
interface.}
\view{bpv,538271560,220,0,0}
______________________________________________________
\paragraph{textview_GetOrigin}
\majorheading{Get textview's desired origin}
______________________________________________________
\fixedtext{void \bold{textview_GetOrigin }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{width},
long \paramname{height},
long *\paramname{originX},
long *\paramname{originY});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Allows communication about the origin of
\paramname{textview}'s
rectangle. The parameters \italic{\paramname{width} and
\paramname{height}}
are the size of \paramname{textview}'s rectangle. In response to these
two
parameters, \paramname{textview_GetOrigin} sets \paramname{originX} and
\paramname{originY} to the (x,y) coordinate where it would like the
parent to
place its origin.}
\fieldheading{Usage}
\fieldtext{Used to properly position a view that is being inserted inline
along a text's baseline.
}
\fieldheading{See Also}
\fieldtext{\paramname{view_GetOrigin} (atk/basics/common/view.doc).}
\view{bpv,538271560,221,0,0}
______________________________________________________
\paragraph{textview_GetTextSize}
\majorheading{Get the size of the text}
______________________________________________________
\fixedtext{void \bold{textview_GetTextSize }(}\fixedindent{
struct textview *\paramname{textview},
long *\paramname{width},
long *\paramname{height});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Sets \paramname{width} and \paramname{height} to the size of
the
text (i.e., to \paramname{textview}'s logical rectangle adjusted for the
whitespace border).
}
\fieldheading{See Also}
\fieldtext{For a discussion of logical rectangle, see graphic.doc
(atk/basics/common/graphic.doc).}
\view{bpv,538271560,222,0,0}
______________________________________________________
\paragraph{textview_GetTopPosition}
\majorheading{Function description}
______________________________________________________
\fixedtext{long \bold{textview_GetTopPosition }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{What does it do? What are the arguments?
NULL?
Assumptions about paths or environment? etc. }
Can arguments be
\fieldtext{The following comment was in the .ch file:
<no comment was found>
}
\fieldheading{Return Value}
\fieldtext{What does it return?}
\fieldheading{Usage}
\fieldtext{When would you use this? When would you not use this?
would
you use something else instead of this?
}
\fieldheading{Error Conditions}
\fieldtext{What will cause errors?
What are the errors?}
\fieldheading{Side Effects}
\fieldtext{What are the side effects, if any?}
\fieldheading{Known Bugs}
When
\fieldtext{What are the known bugs?
bugs?}
What is the status of the known
\fieldheading{See Also}
\fieldtext{List of related commands? Other sections of relevant
interest?
Refer by class/procedure,view name, by document, by source file.
(Example:
message_AskForStringCompleted, Msghndler.doc, txtvcmds.c)}
\fieldheading{Example}
\fieldtext{Concrete example.
}\
\view{bpv,538271560,223,0,0}
______________________________________________________
\paragraph{textview_Hit}
\majorheading{Manage mouse hits}
______________________________________________________
\fixedtext{struct view *\bold{textview_Hit }(}\fixedindent{
struct textview *\paramname{textview},
enum view_MouseAction \paramname{action},
long \paramname{x},
long \paramname{y},
long \paramname{numberOfClicks});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Manages \paramname{textview}'s mouse hits. The parameter
\italic{\paramname{action}} defines the type of mouse input that has
occurred
and can have the following values:
\formatnote{\fieldtext{\italic{view_NoMouseEvent}\formatnote{@\\}No mouse
action.
\italic{view_LeftDown}\formatnote{@\\}Left button pressed down.
\italic{view_LeftUp}\formatnote{@\\}Left button let up.
\italic{view_LeftMovement}\formatnote{@\\}Left button down and mouse has
moved.
\italic{view_RightDown}\formatnote{@\\}Right button pressed down.
\italic{view_RightUp}\formatnote{@\\}Right button let up.
\italic{view_RightMovement}\formatnote{@\\}Right button down and mouse
has
moved.}
}
The coordinates \italic{\paramname{x}} and \italic{\paramname{y}} provide
the
location of the the mouse event, relative to the \paramname{textview}'s
own
coordinate system. The parameter \italic{\paramname{numberOfClicks}} is
the
number of times the mouse button was clicked at that location.}
\fieldheading{Return Value}
\fieldtext{The view, possibly a child of \paramname{textview}, that
accepted
the mouse event.}
\fieldheading{Usage}
\fieldtext{Use to pass a mouse hit to a child \paramname{textview}.
mouse event occurs in a region of the screen allocated to a
If a
\paramname{textview}, usually the correct thing to do is simply pass the
mouse
hit to the \paramname{textview} by calling \paramname{textview_Hit}.}
\fieldheading{See Also}
\fieldtext{For a discussion of parent-child protocols for handling mouse
hits,
see Example 17 (atk/examples/ex17/example17.doc) and view_Hit
(atk/basics/common/view.doc).}
\view{bpv,538271560,224,0,0}
______________________________________________________
\paragraph{textview_InitChildren}
\majorheading{Initialize any children}
______________________________________________________
\fixedtext{void \bold{textview_InitChildren }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Examines \paramname{textview}'s text for all children and, if
appropriate, creates views for them and links them into the view tree.
Recursively calls \paramname{view_InitChildren} on all children.
}
\fieldheading{Usage}
\fieldtext{Would usually be invoked as a parent if \paramname{textview}
is a
child by calling \paramname{view_InitChildren}.
}
\fieldheading{See Also}
\fieldtext{ \paramname{view_InitChildren} (atk/basics/common/view.doc).}
\view{bpv,538271560,225,0,0}
______________________________________________________
\paragraph{textview_InitializeClass}
\majorheading{Initialize the class}
______________________________________________________
\fixedtext{boolean \bold{textview_InitializeClass }(}\fixedindent{);}
\fieldheading{Category}
\fieldtext{Classprocedure}
\fieldheading{Description}
\fieldtext{Initializes the class \paramname{textview} upon its first
being
loaded. In particular, it initializes a keymap for the class and the
preference for whether styles are exposed upon start up.
}
\fieldheading{Return Value}
\fieldtext{Always returns TRUE.}
\fieldheading{Usage}
\fieldtext{Called in \paramname{textview_New}; not called directly by the
application programmer.}
\fieldheading{See Also}
\fieldtext{For a discussion of \paramname{InitializeClass}, see class.doc
(class/doc/class.doc) and Example 4 (examples/ex4/example4.doc).}
\view{bpv,538271560,226,0,0}
______________________________________________________
\paragraph{textview_InitializeObject}
\majorheading{Initialize an instance of textview}
______________________________________________________
\fixedtext{boolean \bold{textview_InitializeObject }(}
\fixedindent{struct textview *\paramname{self});}
\fieldheading{Category}
\fieldtext{Classprocedure}
\fieldheading{Description}
\fieldtext{Initializes \paramname{textview}, and instance of the class
textview. In particular, it initializes internal variables and creates a
keystate, a menulist and default styles.
}\fieldheading{Return Value}
\fieldtext{Always returns TRUE.}
\fieldheading{Usage}
\fieldtext{Used by \paramname{textview_New}; not used by the application
programmer directly.}
\fieldheading{See Also}
\fieldtext{For a discussion o}\fieldtext{f \paramname{InitializeObject},
see
class.doc (class/doc/class.doc) and Example 2
(examples/ex2/example2.doc).}
\view{bpv,538271560,227,0,0}
______________________________________________________
\bold{textview_LineRedraw}
\majorheading{Function description}
______________________________________________________
\fixedtext{long \bold{textview_LineRedraw }(}\fixedindent{
struct textview *\paramname{textview},
enum textview_LineRedrawType \paramname{type},
struct mark \paramname{currentLine},
long \paramname{x},
long \paramname{y},
long \paramname{xSize},
long \paramname{ySize},
long \paramname{search},
boolean *\paramname{cont},
long *\paramname{textheight},
struct formattinginfo *\paramname{info});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{What does it do? What are the arguments?
NULL?
Assumptions about paths or environment? etc. }
\fieldtext{The following comment was in the .ch file:
<no comment was found>
Can arguments be
}
\fieldheading{Return Value}
\fieldtext{What does it return?}
\fieldheading{Usage}
\fieldtext{When would you use this? When would you not use this?
would
you use something else instead of this?
When
}
\fieldheading{Error Conditions}
\fieldtext{What will cause errors?
What are the errors?}
\fieldheading{Side Effects}
\fieldtext{What are the side effects, if any?}
\fieldheading{Known Bugs}
\fieldtext{What are the known bugs?
bugs?}
What is the status of the known
\fieldheading{See Also}
\fieldtext{List of related commands? Other sections of relevant
interest?
Refer by class/procedure,view name, by document, by source file.
(Example:
message_AskForStringCompleted, Msghndler.doc, txtvcmds.c)}
\fieldheading{Example}
\fieldtext{Concrete example.}
\view{bpv,538271560,228,0,0}
______________________________________________________
\paragraph{textview_LinkTree}
\majorheading{Link a textview into the view tree}
______________________________________________________
\fixedtext{void \bold{textview_LinkTree }(}\fixedindent{
struct textview *\paramname{textview},
struct view *\paramname{parent});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Links \paramname{textview} and any of its children into
\paramname{parent}'s view tree.
}
\fieldheading{Usage}
\fieldtext{Before drawing in a child \paramname{textview} or passing
events to
it, a parent should call \paramname{textview_LinkTree}.}
\fieldheading{See Also}
\fieldtext{\paramname{view_LinkTree} (atk/basics/common/view.doc) for a
discussion of view trees.}
\view{bpv,538271560,229,0,0}
______________________________________________________
\paragraph{textview_Locate}
\majorheading{Locate a child view}
______________________________________________________
\fixedtext{long \bold{textview_Locate }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{x},
long \paramname{y},
struct view **\paramname{view});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{If there is a child view at (x,y), set \paramname{view} to
}it.\fieldtext{
}
\fieldheading{Return Value}
\fieldtext{What is the return value?}
\fieldheading{Usage}
\fieldtext{Used by \paramname{textview} to pass mouse hits to its
children.}
\view{bpv,538271560,230,0,0}
______________________________________________________
\paragraph{textview_LookCmd}
\majorheading{Function description}
______________________________________________________
\fixedtext{void \bold{textview_LookCmd }(}\fixedindent{
struct textview *\paramname{textview},
int \paramname{look});}
\fieldheading{Category}
Method
\fieldheading{Description}
\fieldtext{What does it do? What are the arguments?
NULL?
Assumptions about paths or environment? etc. }
Can arguments be
\fieldtext{The following comment was in the .ch file:
<no comment was found>
}
\fieldheading{Return Value}
\fieldtext{What does it return?}
\fieldheading{Usage}
\fieldtext{When would you use this? When would you not use this?
would
you use something else instead of this?
}
\fieldheading{Error Conditions}
\fieldtext{What will cause errors?
What are the errors?}
\fieldheading{Side Effects}
\fieldtext{What are the side effects, if any?}
\fieldheading{Known Bugs}
When
\fieldtext{What are the known bugs?
bugs?}
What is the status of the known
\fieldheading{See Also}
\fieldtext{List of related commands? Other sections of relevant
interest?
Refer by class/procedure,view name, by document, by source file.
(Example:
message_AskForStringCompleted, Msghndler.doc, txtvcmds.c)}
\fieldheading{Example}
\fieldtext{Concrete example.
}\
\view{bpv,538271560,231,0,0}
______________________________________________________
\paragraph{textview_LoseInputFocus}
\majorheading{Give up the input focus}
______________________________________________________
\fixedtext{void \bold{textview_LoseInputFocus }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Give up the input focus and call for an update.}
\fieldheading{Usage}
\fieldtext{A parent should notify a child \paramname{textview} that it
has
lost the input focus by calling this method.
}
\fieldheading{Side Effects}
\fieldtext{Sets \paramname{textview->hasInputFocus} to FALSE; the
\paramname{textview} communicates a \paramname{WantUpdate}.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_ReceiveInputFocus}. For a discussion of
the
input focus, see \paramname{view_LoseInputFocus} and Example 4
(examples/ex4/example.doc).}
\view{bpv,538271560,232,0,0}
______________________________________________________
\paragraph{textview_MoveBack}
\majorheading{Move the dot backward}
______________________________________________________
\fixedtext{long \bold{textview_MoveBack }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{pos},
long \paramname{n},
enum textview_MovementUnits \paramname{type},
long *\paramname{distMoved},
long *\paramname{linesAdded});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Moves the dot back from \italic{\paramname{pos}} \paramname{n}
\italic{units. The parameter \paramname{type} specifies the type of
units,
}either \italic{\paramname{textview_MoveByPixels}} or
\italic{\paramname{textview_MoveByLines}}. Sets
\italic{\paramname{distMoved}}
to the distance moved from the original position in terms of pixels and
\italic{\paramname{linesAdded}} to the number of any lines
added.}\fieldtext{
}
\fieldheading{Return Value}
\fieldtext{The position in the text that will be at the beginning of the
line
you land on after moving back the indicated distance.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_MoveForward}.}
\view{bpv,538271560,233,0,0}
______________________________________________________
\paragraph{textview_MoveForward}
\majorheading{Move the dot forward}
______________________________________________________
\fixedtext{long \bold{textview_MoveForward }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{pos},
long \paramname{units},
enum textview_MovementUnits \paramname{type},
long *\paramname{distMoved},
long *\paramname{linesAdded});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Moves the dot forward from \italic{\paramname{pos}}
\paramname{n}
\italic{units. The parameter \paramname{type} specifies the type of
units,
}either \italic{\paramname{textview_MoveByPixels}} or
\italic{\paramname{textview_MoveByLines}}. Sets
\italic{\paramname{distMoved}}
to the distance moved from the original position in terms of pixels and
\italic{\paramname{linesAdded}} to the number of any lines added.}
\fieldheading{Return Value}
\fieldtext{The position in the text that will be at the beginning of the
line
you land on after moving forward the indicated distance.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_MoveBack}.}
\view{bpv,538271560,234,0,0}
______________________________________________________
\paragraph{textview_ObservedChanged}
\majorheading{Take appropriate action upon observing a change}
______________________________________________________
\fixedtext{void \bold{textview_ObservedChanged }(}\fixedindent{
struct textview *\paramname{textview},
struct observable *\paramname{changed},
long \paramname{value});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{On the one hand, if \paramname{changed} is equal to
\paramname{textview}'s dataobject and \paramname{value} is
\paramname{observable_OBJECTDESTROYED}, sets \paramname{textview}'s
dataobject
field to NULL; if value is not equal to
\paramname{observable_OBJECTDESTROYED}, calls a \paramname{WantUpdate}.
On
the other hand, if \paramname{changed} is a view reference and
\paramname{value} is \paramname{observable_OBJECTDESTROYED}, unlinks the
view
reference from the view tree, deletes its entry in the dictionary, and
destroys it.}
\fieldheading{See Also}
\fieldtext{\paramname{view_ObservedChanged}i
(atk/basics/common/view.doc).}
\view{bpv,538271560,235,0,0}
______________________________________________________
\paragraph{textview_Print}
\majorheading{Prints a text file}
______________________________________________________
\fixedtext{void \bold{textview_Print }(}\fixedindent{
struct textview *\paramname{textview},
FILE *\paramname{file},
char *\paramname{processor},
char *\paramname{finalFormat},
boolean \paramname{topLevel});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{If \paramname{processor} is "troff" and
\paramname{finalFormat} is
"PostScript," prints the \paramname{file}, which should be the text file
associated with \paramname{textview}. If \paramname{textview_Print} is
being
called from another \paramname{view_Print} invocation, the
\paramname{topLevel}
parameter should be one more than the caller's level parameter.
}
\fieldheading{Usage}
\fieldtext{Call if you want to print a textview.
}
\fieldheading{Error Conditions}
\fieldtext{If the class \paramname{texttroff} cannot be loaded, displays
the
message "Print aborted: could not load class 'texttroff'. "}
\fieldheading{Known Bugs}
\fieldtext{Should return an error if texttroff cannot be loaded.}
\fieldheading{See Also}
\fieldtext{\paramname{view_Print} (atk/basics/common/view.doc).}
\view{bpv,538271560,236,0,0}
______________________________________________________
\paragraph{textview_ReceiveInputFocus}
\majorheading{Takes actions appropriate to receiving the input focus}
______________________________________________________
\fixedtext{void \bold{textview_ReceiveInputFocus }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Takes actions appropriate to having received the input focus;
in
particular, posts a keystate and a menulist and calls for an update.
}\fieldheading{Usage}
\fieldtext{A parent should notify a child \paramname{textview} that it
has
received the input focus by calling this method.}
\fieldheading{Side Effects}
\fieldtext{Sets \paramname{textview->hasInputFocus} to TRUE; the
\paramname{textview} communicates a \paramname{WantUpdate}.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_LoseInputFocus}; For a discussion of the
input
focus, see \paramname{view_ReceiveInputFocus} and Example 4
(examples/ex4/example.doc).}
\view{bpv,538271560,237,0,0}
______________________________________________________
\paragraph{textview_SetBorder}
\majorheading{Sets the whitespace borders for text}
______________________________________________________
\fixedtext{void \bold{textview_SetBorder }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{xBorder},
long \paramname{yBorder});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Sets the left and right borders to \paramname{xBorder} and
the top
and bottom borders to \paramname{yBorder}. These borders are used when
the
text has an application layer.}
\fieldheading{Known Bugs}
\fieldtext{Needs to do some update for resetting the border.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_SetEmbeddedBorder}.
For a discussion
of
application layers, see view.doc (atk/basics/common/view.doc).}
\view{bpv,538271560,238,0,0}
______________________________________________________
\paragraph{textview_SetDataObject}
\majorheading{Set the data object}
______________________________________________________
\fixedtext{void \bold{textview_SetDataObject }(}\fixedindent{
struct textview *\paramname{textview},
struct dataobject *\paramname{dataObject});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Associates \paramname{textview} with its
\paramname{dataObject},
where \paramname{dataObject} should be an instance of the class
\paramname{text}.}\fieldtext{
}
\fieldheading{Error Conditions}
\fieldtext{If the type of dataObject is not "text," prints the message
"Incompatible dataobject associated with textview\\n" to standard error.}
\fieldheading{Side Effect}
\fieldtext{Adds \paramname{textview} to \paramname{dataObject}'s list of
observers.}
\fieldheading{See Also}
\fieldtext{\paramname{view_SetDataObject} (atk/basics/common/view.doc).}
\view{bpv,538271560,239,0,0}
______________________________________________________
\paragraph{textview_SetDefaultStyle}
\majorheading{Set the default style}
______________________________________________________
\fixedtext{void \bold{textview_SetDefaultStyle }(}\fixedindent{
struct textview *\paramname{textview},
struct style *\paramname{styleptr});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Sets \paramname{textview'}s default style to
\paramname{styleptr}.
}
\fieldheading{Usage}
\fieldtext{When an instance of \paramname{textview} is initialized, the
default style includes font family Andy, font size 12, justification left
justified.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_GetDefaultStyle}.}
\view{bpv,538271560,240,0,0}
______________________________________________________
\paragraph{textview_SetDotLength}
\majorheading{Set the length of the dot}
______________________________________________________
\fixedtext{void \bold{textview_SetDotLength }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{newLength});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Sets the length of \paramname{textview}'s dot to
\paramname{newLength}.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_GetDotLength}.}
\view{bpv,538271560,241,0,0}
______________________________________________________
\paragraph{textview_SetDotPosition}
\majorheading{Set the position of the dot}
______________________________________________________
\fixedtext{void \bold{textview_SetDotPosition }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{newPosition});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Set the position of \paramname{textview}'s dot to
\paramname{newPosition}.
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_GetDotPosition}.}
\view{bpv,538271560,242,0,0}
______________________________________________________
\paragraph{textview_SetEmbeddedBorder}
\majorheading{Function description}
______________________________________________________
\fixedtext{void \bold{textview_SetEmbeddedBorder }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{xBorder},
long \paramname{yBorder});}
\fieldheading{Category}
Method
\fieldheading{Description}
\fieldtext{Sets the left and right embedded borders to
\paramname{xBorder}
and the top and bottom embedded borders to \paramname{yBorder}.
borders
are used when the text has no application layer.}
\fieldheading{Known Bugs}
\fieldtext{Needs to do some update for resetting the border.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_SetBorder}.
For a discussion of
application
layers, see view.doc (atk/basics/common/view.doc).}
\view{bpv,538271560,243,0,0}
These
______________________________________________________
\paragraph{textview_SetTopPosition}
\majorheading{Function description}
______________________________________________________
\fixedtext{void \bold{textview_SetTopPosition }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{newTopPosition});}
\fieldheading{Category}
Method
\fieldheading{Description}
\fieldtext{What does it do? What are the arguments?
NULL?
Assumptions about paths or environment? etc. }
Can arguments be
\fieldtext{The following comment was in the .ch file:
<no comment was found>
}
\fieldheading{Return Value}
\fieldtext{What does it return?}
\fieldheading{Usage}
\fieldtext{When would you use this? When would you not use this?
would
you use something else instead of this?
}
\fieldheading{Error Conditions}
When
\fieldtext{What will cause errors?
What are the errors?}
\fieldheading{Side Effects}
\fieldtext{What are the side effects, if any?}
\fieldheading{Known Bugs}
\fieldtext{What are the known bugs?
bugs?}
What is the status of the known
\fieldheading{See Also}
\fieldtext{List of related commands? Other sections of relevant
interest?
Refer by class/procedure,view name, by document, by source file.
(Example:
message_AskForStringCompleted, Msghndler.doc, txtvcmds.c)}
\fieldheading{Example}
\fieldtext{Concrete example.
}
\view{bpv,538271560,244,0,0}
______________________________________________________
\paragraph{textview_Update}
\majorheading{Updates those text lines that need to be redrawn}
______________________________________________________
\fixedtext{void \bold{textview_Update }(}\fixedindent{
struct textview *\paramname{textview});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Updates (i.e., redraws) those \paramname{textview} lines that
need
to be redrawn.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_FullUpdate}; \paramname{view_Update}
(atk/basics/common/view.doc).}
\view{bpv,538271560,245,0,0}
______________________________________________________
\paragraph{textview_ViewMove}
\majorheading{Function description}
______________________________________________________
\fixedtext{void \bold{textview_ViewMove }(}\fixedindent{
struct textview *\paramname{textview},
struct mark *\paramname{currentLine},
long \paramname{movement});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{What does it do? What are the arguments?
NULL?
Assumptions about paths or environment? etc. }
Can arguments be
\fieldtext{The following comment was in the .ch file:
<no comment was found>
}
\fieldheading{Return Value}
\fieldtext{What does it return?}
\fieldheading{Usage}
\fieldtext{When would you use this? When would you not use this?
would
you use something else instead of this?
When
}
\fieldheading{Error Conditions}
\fieldtext{What will cause errors?
What are the errors?}
\fieldheading{Side Effects}
\fieldtext{What are the side effects, if any?}
\fieldheading{Known Bugs}
\fieldtext{What are the known bugs?
bugs?}
What is the status of the known
\fieldheading{See Also}
\fieldtext{List of related commands? Other sections of relevant
interest?
Refer by class/procedure,view name, by document, by source file.
(Example:
message_AskForStringCompleted, Msghndler.doc, txtvcmds.c)}
\fieldheading{Example}
\fieldtext{Concrete example.
}
\view{bpv,538271560,246,0,0}
______________________________________________________
\paragraph{textview_Visible}
\majorheading{Position is visible}
______________________________________________________
\fixedtext{boolean \bold{textview_Visible }(}\fixedindent{
struct textview *\paramname{textview},
long \paramname{pos});}
\fieldheading{Category}
\fieldtext{Method}
\fieldheading{Description}
\fieldtext{Tests whether \paramname{pos} is visible.}
\fieldheading{Return Value}
\fieldtext{TRUE if pos is visible; FALSE otherwise.}
\view{bpv,538271560,247,0,0}
______________________________________________________
\paragraph{textview_WantNewSize}
\majorheading{Request a new size}
______________________________________________________
\fixedtext{void \bold{textview_WantNewSize }(}\fixedindent{
struct textview *\paramname{textview},
struct view *\paramname{requestor});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Provides a method for a view, \italic{\paramname{requestor}},
to
request \paramname{textview} to begin a desired size negotiation.}
\fieldheading{Usage}
\fieldtext{A child view should request size negotiations from its parent
by
calling this method
}
\fieldheading{See Also}
\fieldtext{\paramname{textview_DesiredSize}}\fieldtext{;
}\fieldtext{\paramname{view_WantNewSize} (atk/basics/common/view.doc).}
\view{bpv,538271560,248,0,0}
______________________________________________________
\paragraph{textview_WantUpdate}
\majorheading{Request an update}
______________________________________________________
\fixedtext{void \bold{textview_WantUpdate }(}\fixedindent{
struct textview *\paramname{textview},
struct view *\paramname{requestor});}
\fieldheading{Category}
\fieldtext{Override}
\fieldheading{Description}
\fieldtext{Requests an update for view \paramname{requestor} from
\paramname{textview}.
}
\fieldheading{Usage}
\fieldtext{If a view to update its image, it should call
\italic{\paramname{view_WantUpdate}} with both arguments set to itself.}
\fieldheading{See Also}
\fieldtext{\paramname{textview_Update}; for a discussion of update
requests,
see \paramname{view_WantUpdate} (atk/basics/common/view.doc).}
\begindata{bp,538271624}
\enddata{bp,538271624}
\view{bpv,538271624,249,0,0}
\section{\paramname{textview} key bindings and proctable functions}
\fixedtext{\{"textview-beginning-of-line",
"\\001",0,NULL,0,0,textview_BeginningOfLineCmd,"Move to beginning of
current
line."\},
\{"textview-beginning-of-line", "\\033H",0\},
\{"textview-backward-character",
"\\002",0,NULL,0,0,textview_BackwardCmd,"Move backward one character."\},
\{"textview-backward-character", "\\033D",0\},
\{"textview-delete-next-character",
"\\004",0,NULL,0,0,textview_DeleteCmd,"Delete the next character."\},
\{"textview-end-of-line",
"\\005",0,NULL,0,0,textview_EndOfLineCmd,"Move
to end of the current line."\},
\{"textview-end-of-line", "\\033F",0\},
\{"textview-forward-character",
"\\006",0,NULL,0,0,textview_ForwardCmd,"Move forward one character."\},
\{"textview-forward-character", "\\033C",0\},
\{"textview-delete-previous-character",
"\\010",0,NULL,0,0,textview_RuboutCmd,"Delete the previous character."\},
\{"textview-delete-previous-character", "\\177",0\},
\{"textview-insert-newline",
"\\015",0,NULL,0,0,textview_InsertNLCmd,"Insert a newline character."\},
\{"textview-next-line", "\\016",0,NULL,0,0,textview_NextLineCmd,"Move
to
next line."\},
\{"textview-next-line", "\\033B",0\},
\{"textview-previous-line",
"\\020",0,NULL,0,0,textview_PreviousLineCmd,"Move to previous line."\},
\{"textview-previous-line", "\\033A",0\},
\{"textview-set-argument",
"\\025",0,NULL,0,0,textview_SetArgumentCmd,"Set
argument count."\},
\{"textview-indent", "\\033i",0,NULL,0,0,textview_IndentCmd,"Indent
current line."\},
\{"textview-GrabReference",
"\\030w",0,NULL,0,0,textview_GrabReference,"Grab the next viewref"\},
\{"textview-PlaceReference",
"\\030y",0,NULL,0,0,textview_PlaceReference,"Create a new viewref"\},
\{"textview-unindent", "\\033u",0,NULL,0,0,textview_UnindentCmd,"Unindent
current line."\},
\{"textview-exch", "\\030\\030",0,NULL,0,0,textview_ExchCmd,"Exchange
dot
and mark."\},
\{"textview-select-region",
"\\033\\200",0,NULL,0,0,textview_SelectRegionCmd,"Select between dot and
mark."\},
\{"textview-copy-region",
"\\033w",0,"Copy~11",0,textview_SelectionMenus,textview_CopyRegionCmd,"Co
py
region to kill-buffer."\},
\{"textview-mylf", "\\012",0,NULL,0,0,textview_MyLfCmd,"Skip to next
line
and indent."\},
\{"textview-zap-region", "\\027",0,"Cut~10",0,
textview_SelectionMenus |
textview_NotReadOnlyMenus,textview_ZapRegionCmd,"Remove the text within
the
selection region and place it in a cutbuffer."\},
\{"textview-append-next-cut",
"\\033\\027",0,NULL,0,0,textview_AppendNextCut, "Make next cut command
append
to the cutbuffer as opposed to making a new buffer."\},
\{"textview-yank", "\\031",0,"Paste~10",0,textview_NotReadOnlyMenus |
textview_NoSelectionMenus,textview_YankCmd,"Yank text back from
kill-buffer."\},
\{"textview-insert-file", "\\030\\t", 0,"File~10,Insert
File~10",0,textview_NotReadOnlyMenus,textview_InsertFile,"Prompt for a
filename and insert that file's contents into the document."\},
\{"textview-rotate-backward-paste",
"\\033\\031",0,NULL,0,0,textview_BackwardsRotatePasteCmd,"Rotate killbuffer
backwards."\},
\{"textview-line-to-top",
"\\033!",0,NULL,0,0,textview_LineToTopCmd,"Move
current line to top of screen."\},
\{"textview-rotate-paste",
"\\033y",0,NULL,0,0,textview_RotatePasteCmd,"Rotate kill-buffer."\},
\{"textview-forward-para",
"\\033]",0,NULL,0,0,textview_ForwardParaCmd,"Move to the next
paragraph."\},
\{"textview-backward-para",
"\\033[",0,NULL,0,0,textview_BackwardParaCmd,"Move to the next
paragraph."\},
\{"textview-open-line",
"\\017",0,NULL,0,0,textview_OpenLineCmd,"Insert
blank line at current pos."\},
\{"textview-plainer",
"\\030\\020",0,"Plainer~40",0,textview_NotReadOnlyMenus,textview_PlainerC
md,"Re\
move innermost environment."\},
\{"textview-plainest",NULL,0,"Plainest~41",0,textview_SelectionMenus
|
textview_NotReadOnlyMenus,textview_PlainestCmd,"Remove all enclosing
styles."\},
\{"textview-prev-screen",
"\\033v",0,NULL,0,0,textview_PrevScreenCmd,"Move
forward to previous screen"\},
\{"textview-prev-screen", "\\033G",0\},
\{"textview-next-screen",
"\\026",0,NULL,0,0,textview_NextScreenCmd,"Move
forward to next screen"\},
\{"textview-next-screen", "\\033E",0\},
\{"textview-glitch-down",
"\\021",0,NULL,0,0,textview_GlitchDownCmd,"Glitch screen down one
line."\},
\{"textview-glitch-down", "\\033z",0\},
\{"textview-glitch-up",
"\\032",0,NULL,0,0,textview_GlitchUpCmd,"Glitch
screen up one line."\},
\{"textview-twiddle-chars",
"\\024",0,NULL,0,0,textview_TwiddleCmd,"Exchange previous two chars."\},
\{"textview-kill-line", "\\013",0,NULL,0,0,textview_KillLineCmd,"Kill
rest
of line."\},
\{"textview-search", "\\023",0,"Search/Spell~1,Forward~10",0,0,(void
(*)())textview_SearchCmd,"Search forward."\},
\{"textview-reverse-search",
"\\022",0,"Search/Spell~1,Backward~11",0,0,(void
(*)())textview_RSearchCmd,"Search backward."\},
\{"textview-search-again",NULL,0,"Search/Spell~1,Search
Again~12",0,0,textview_SearchAgain,"Repeat last search."\},
\{"textview-insert-inset-here",
"\\033\\t",0,NULL,0,0,textview_InsertInsetCmd,"Add inset at this
location."\},
\{"textview-what-paragraph",
"\\033N",0,NULL,0,0,textview_WhatParagraphCmd,"Print current paragraph
number."\},
\{"textview-show-styles",
"\\033s",0,NULL,0,0,textview_ShowStylesCmd,"Show
styles at dot."\},
\{"textview-goto-paragraph",
"\\033n",0,NULL,0,0,textview_GotoParagraphCmd,"Go to specific
paragraph."\},
\{"textview-query-replace", "\\033q",0,"Search/Spell~1,Query
Replace~20",0,textview_NotReadOnlyMenus,textview_QueryReplaceCmd,"Query
replace."\},
#ifdef IBM
\{"spell-check-document",NULL,0,"Search/Spell~1,Check Spelling~30",
0,textview_NotReadOnlyMenus,textview_CheckSpelling,"Checks spelling from
the
caret on.", "spell"\},
#else /* IBM */
\{"spell-check-document",NULL,0,"Search/Spell~1,Check Spelling~30",
0,textview_NotReadOnlyMenus,NULL,"Checks spelling from the caret on.",
"spell"\},
#endif /* IBM */
\{"textview-quote",
"\\030\\021",0,NULL,0,0,textview_QuoteCmd,"Uninterpreted insert of any
char or
octal code."\},
\{"textview-kill-white-space",
"\\033k",0,NULL,0,0,textview_KillWhiteSpaceCmd,"Delete spaces and tabs
around
the current pos."\},
\{"textview-ctrl-at", "\\200",0,NULL,0,0,textview_CtrlAtCmd,"Set a
mark."\},
\{"textview-backward-word",
"\\033b",0,NULL,0,0,textview_BackwardWordCmd,"Move backward to beginning
of
word."\},
\{"textview-delete-next-word",
"\\033d",0,NULL,0,0,textview_DeleteWordCmd,"Delete
the next word."\},
\{"textview-forward-word",
"\\033f",0,NULL,0,0,textview_ForwardWordCmd,"Move forward to end of
word."\},
\{"textview-delete-previous-word",
"\\033h",0,NULL,0,0,textview_RuboutWordCmd,"Delete the previous word."\},
\{"textview-delete-previous-word",
"\\033\\b",0,NULL,0,0,textview_RuboutWordCmd,NULL\},
\{"textview-delete-previous-word",
"\\033\\177",0,NULL,0,0,textview_RuboutWordCmd,NULL\},
\{"textview-end-of-text",
"\\033>",0,NULL,0,0,textview_EndOfTextCmd,"Move
to end of text."\},
\{"textview-beginning-of-text",
"\\033<",0,NULL,0,0,textview_BeginningOfTextCmd,"Move to beginning of
text."\},
\{"textview-toggle-character-case",
"\\036",0,NULL,0,0,textview_ToggleCase,"Toggle the case of the character
at
the dot."\},
\{"textview-lowercase-word",
"\\033l",0,NULL,0,0,textview_LowercaseWord,"Convert word (or region) to
lower
case."\},
\{"textview-uppercaseword",NULL,0,NULL,0,0,textview_UppercaseWord,"Convert\
word (or region) to upper case."\},
\{"textview-capitalizeword",NULL,0,NULL,0,0,textview_CapitalizeWord,"Capit\
alize word (or all words within a region)."\},
\{"textview-cursor-to-top",
"\\033,",0,NULL,0,0,textview_CursorToTop,"Moves cursor to the beggining
of the
line currently at the top of the screen."\},
\{"textview-cursor-to-bottom",
"\\033.",0,NULL,0,0,textview_CursorToBottom,"Moves cursor to the
beggining of
the line currently at the bottom of the screen."\},
\{"textview-cursor-to-center",
"\\033/",0,NULL,0,0,textview_CursorToCenter,"Moves cursor to the
beggining of
the line currently at the center of the screen."\},
\{"textview-change-template",NULL,0,"File~10,Add
Template~31",0,textview_NotReadOnlyMenus,textview_ChangeTemplate, NULL,
"Change to named template."\},
\{"textview-toggle-read-only",
"\\033~",0,NULL,0,0,textview_ToggleReadOnly,"Change read only status of
text
object."\},
\{"textview-toggle-expose-styles",
NULL,0,NULL,0,0,textview_ToggleExposeStyles,"Expose/hide style
information"\},
\{"textview-edit-styles", NULL, 0, NULL, 0,
textview_NotReadOnlyMenus,
textview_ExposeStyleEditor,"Expose style editor"\},
\{"textview-insert-pagebreak", NULL,0,"Page~3,Insert
Pagebreak~11",0,textview_NotReadOnlyMenus,textview_InsertPageBreak,"Add
page
break at this location."\},
\{"textview-next-page", NULL,0,"Page~3,Next
Page~12",0,0,textview_NextPage,"Frame text at next page break object"\},
\{"textview-last-page", NULL,0,"Page~3,Previous
Page~13",0,0,textview_LastPage,"Frame text at last page break object"\},
\{"textview-insert-footnote", NULL,0,"Page~3,Insert
Footnote~20",0,textview_NotReadOnlyMenus,textview_InsertFootnote,"Add
footnote
at this location."\},
\{"contentv-make-window", NULL,0,"Page~3,Table of
Contents~30",0,0,NULL,"Make a table of contents window","contentv"\},
\{"textview-open-footnotes",NULL,0,"Page~3,Open
Footnotes~22",0,0,textview_OpenFootnotes,"Open all footnotes"\},
\{"textview-close-footnotes",NULL,0,"Page~3,Close
Footnotes~23",0,0,textview_CloseFootnotes,"Close all footnotes"\},
\{"textview-writefootnotes",NULL,0,NULL,0,0,textview_WriteFootnotes,"Write\
all footnotes"\},
NULL
\};
struct keymap *textview_InitKeyMap(classInfo, normalMenus)
struct textview_classinfo *classInfo;
struct menulist **normalMenus;
\{
struct keymap *newKeymap = keymap_New();
register long i;
char str[2];
struct proctable_Entry *si,*dig;
if(normalMenus!=NULL)
*normalMenus=menulist_New();
lcKill = im_AllocLastCmd();
lcYank = im_AllocLastCmd();
lcMove = im_AllocLastCmd();
lcDisplayEnvironment = im_AllocLastCmd();
bind_BindList(textviewBindings, newKeymap, *normalMenus, classInfo);
si=proctable_DefineProc("textview-self-insert",
textview_SelfInsertCmd,
classInfo, NULL, "Insert a character.");
dig=proctable_DefineProc("textview-digit", textview_DigitCmd,
classInfo,
NULL, "Insert a character.");
str[0] = ' ';
str[1] = '\\0';
for (i = 32; i < 127; i++)
\{
if (i < '0' || i > '9')
keymap_BindToKey(newKeymap, str, si, i);
else
keymap_BindToKey(newKeymap, str, dig, i);
str[0]++;
\}
keymap_BindToKey(newKeymap, "\\t", si, '\\t');
return newKeymap;}\fixedtext{ }
\begindata{bp,537558784}
\enddata{bp,537558784}
\view{bpv,537558784,251,0,0}
Copyright 1992 Carnegie Mellon University and IBM.
All rights reserved.
\smaller{\smaller{$Disclaimer:
Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted, provided
that the above copyright notice appear in all copies and that both that
copyright notice and this permission notice appear in supporting
documentation, and that the name of IBM not be used in advertising or
publicity pertaining to distribution of the software without specific,
written prior permission.
THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD
TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ANY COPYRIGHT
HOLDER BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
$
}}\enddata{text,538442812}