Note: Descriptions are shown in the official language in which they were submitted.
r~ _
I ~ 6~3B7
Description
BIDIRECTIONAL CHARACTER DEFINITION
Cross-Reference to Related Applications
Canadian Patent Application No. 385,548, filed
September 9, 1981, having William C. Cason et al as
inventors and entitled "Multi-Directional Cursor
Motion-l.
Backqround of the Invention
l. Field of the Invention
This invention relates to interfacing hardware
and software components in a text information system
and more particularly to the definition of textual
material on which to perform one of several selected
operations.
,.
2~ ~escription of Prior Art --
- Heretofore text processing machines included
hardware and controls that enabled an operator to
highlight on a display screen a character or a block
of characters in the text stored in the machine. One
or more selected functions may then be applied to the
character(s) within this block. Typically, such
functions include the deletion,: movement or co~ying of
the highlighted cha-racter(s) contained within the block.
However, the controIs limited the operator to start
the character highlighting definition by positioning
a cursor at a starting point nearest the start of
the character or characters to be highlighted and
subsequently position the cursor to end the block
3b definition at an end point nearest the end o~ the
.
~ AT9-80-031
~.
3 ~ ~
identified characters. This restriction reduces the
productivity of the operator by placing an artificial
constraint on the manner in which the operator defines
the character or block of characters to be highlighted.
Summary of the Invention
In accordance with the present invention, a
character definition syste~ is provided for highlighting
; text stored in a text processing machine, with the text
to be highlighted being bounded by characters identified
by the operator~ The character definition system
includes a text storage buffer for storing characters in
a contextual array and a display screen for displaying
characters stored in the text storage buffer in a
spatial array. A display control block is provided for
highlighting a character or block of characters
- displayed on the display bounded by a character
identified by a start pointer and a character aPpearing
subsequent in the text and identified by an end pointer.
A keystroke~service routine provides control
instructions for determininq the character(s) identified
by the operator to bound the earliest appearing text
to be highlighted and identifying a character with the
start pointer and highlighting subsequently appearing
character identified by the operator with the end
pointer.
In accordance with another feature of the present
invention, a text storage buffer control block defines
first and second location pointers and a cursor pointer
for indicating individual characters in the text storage
buffer. A display control block is provided which
defines a display cursor for indicating individual
characters displayed on the display. The operator
determines the character to be indicated by the first
AT9-80-031
3 ~
. ~
location pointer by highlighting the character with
the display cursor on the display screen. The operator
subsequently determines the character to be indicated
by the second location pointer with the display cursor.
A keystroke service routine provides control
instructions for highlighting characters between a start
pointer and an end pointer in both the text storage
buffer and the display. The keystroke service routine
determines which character indicated by the first and
second location pointers, respectively, appears earliest
in the text and identifies this point with the start
pointer. The keystroke service routine then identifies
the latter character with the end pointer and the
display control block highlights the text bounded
lS thereby.
In accordance with another feature of the present
invention/ the keystroke service routine disables any
highlighting other than that between the start point
and end point.
In accordance with yet another feature of the
present invention, a method for highlighting a character
or a block of characters bounded by characters
identified by the operator in a text processing machine
is provided. The method includes the steps of storing
characters in a contextual array in a text storage
buffer and displaying characters stored in the text
storage buffer on a display screen in a spatial array.
The method further includes the step of highlighting a
character or a block of characters bounded by a
character identified with a start pointer and a
character appearing subsequent in the text identified
by an end pointer. The method also includes the step
of determining the operator identified character
appearing earliest in the text and identifying this
AT9-80-031
3 ~; ~
,,
character with the start pointer and the subsequently
appearing operator identified character by the end
pointer.
; Brief Description of the Drawinqs
A more complete understanding of the invention
may be had by reference to the following detailed
; description when taken in conjunction with the
accompanying drawings, wherein:
FIGURE 1 is a block diagram of various components
in a text processing machine in which the present
invention is e~ployed;
; FIGURE 2 is a block diagral~ of logic ele~ent
components in the processor illustrated in FIClURE l;
FIG~RE 3 is a logic flow chart of the block
definition routine forming a portion of the present
invention;
FIGURE 4 is a logic flow chart for a cursor up
or down motion routine forming a portion of the present
invention;
FIGURE 5 is a logic flow chart of a cursor movement
routine for move~ent other than up and down; and
FIG~RE 6 is a logic flow chart of the hi~hlight
routine forming a portion of the present invention.
Detailed Description
Referring now to the drawings, wherein like
reference characters designate like or corresponding
parts throughout several views, FIG~RE 1 illustrates
a text processing machine 10. The text processing
machine 10 prepares hard or printed copies of text
entered into the ~achine by operator controlled kèys
on the keyboard 12. The keyboard 12 drives a processor
14. The processor 14 is operably interconnected to a
, visual display 16, a diskette drive 18 and a rando~
AT9-80-031
t 1~3d~7
access me~ory 20 by a memory bus 22. A sys~em clock
23 is provided for timing functions within the text
processor machine 10. Text is input to the machine by
an operator entering ~eystrokes on the keyboard 12,
which includes a conventional typewriter keyboard with
additional control keys. The text input by the operator
appears as a te~tual display on the display screen 16
and the keystroke and instruction data is placed into a
memory for future recovery in preparing hard copy.
One important control function in keyboard 12 is
the definition or highlighting of a character or a block
or group of sequential characters in the text stored in
memory and displayed on display screen 16. Once a block
of characters is defined, a number of functions are
available for performance on this block. For example,
the character or characters in the block may be deleted,
moved to another part of the text in the memory, or
copied at another location in the text. The present
invention permits the operator to define the block by
moving a cursor or other indication pointer either
forward or backward in the text. This allows the
operator to define the bloc~ in whichever direction
is easiest, rather than placin~ an artificial constraint
on the direction of cursor motion as required in
previous machines. The text processing machine 10 then
functions to highlight the character or characters
within the block in preparation for a further function.
Referring to FIG~RE 2, the processor 14 is further
detailed to show typical logic hardware elements as
found in such processors. The processor may be a
commercially available unit, such as from Intel
Corporation and identified by the Number 8086.
Typically, the processor includes a ontrol logic unit
30 which responds to interrupts on a device bus 21 from
i
AT9-80-031
3 ~.~ 7
the keyboard 12. The control logic unit 30 is also
connected to the data and address bus 34 interconnected
to various other logic units of the processor 14.
In response to a fetch instruction from the random
access memory 20, the control logic unit 30 qenerates
control signals to other logic elements of the
processor. These control signals are interconnected to
the various other elements by means of a control line 36
which is illustrated directly connected to an arithmetic
logic unit 38 and identified as a "control" line 36 to
other elements of the processor. Synchronous ODeratiOn
of the control unit 30 with other logic elements of the
processor 14 is achieved by means of clock pulses input
to the processor from an external clock source 40. This
instruction bus is also shown interconnected to other
logic elements of the processor detailed in FIGURE 2.
Data and instructions to be processed in the
processor 14 are input through a bus control logic unit
42. Data to be processed may also COm.? from program
input/output control logic 44. The bus control logic 42
connects storage elements of the memory 20 and receives
instructions for processing data received from the data
input/output control 44 or received from the random
access memory 20. Thus, the input/output control 44
receives data from the keyboard 12 or the memory 20
while the bus control logic 42 receives instructions
and/or data from the same memory. Note that different
storage sections of the random access memory are
identifiable for instruction storage and data storage.
Device control information from the processor 14 is
output through the program input/output controller 44
over a data bus (48,49). Input data on the data~bus
(48,49) from the keyboard 12 is processed internally
through the processor by instructions on the bus 34 to
!
~T9-80-031
-
1 ~6~3~7
. .
the scratch register 52. The arithmetic logic unit
38, in response to a control si~nal on line 36 and in
accordance with instructions received on the memory bus
22, performs arithmetic computations which may be stored
in temporary scratch registers 52. Various other
transfers of data between the arithMetic logic unit 38
and other logic elements of the processor are of course
possible. Such additional transfers may be to a status
register 60, data pointer register 56 or a stack pointer
register 58. Also in the data stream for these various
logic elements by means of the bus 34 is a program
counter 54.
A particular operating sequence for the processor
14 is determined by instructions and data on the memory
bus 22 and input data on the bi-directional bus (48,49).
As an example, in response to received instructions,
the processor transfers data stored in the scratch
registers 52 to one of the registers 56, 58 or 60. Such
operations of processors as detailed in FIGURE 2 are
considered to be well known and understood by one of
ordinary skill in the data processing field. A detailed
description of each operation of the processor of FIGURE
2 for the described invention would be counterproductive
to an understanding of the invention as claimed.
With reference again to FIGURE 1, the operator
keystrokes are displayed on display screen 16 quite
similar in nature to a conventional television receiver
screen. This screen either displays a full page of
text, a partial page or, in some machines, only a single
line of text. The display not only provides a visual
presentation to the operator of the text being prepared
but also provides promptin~ instructions for the
operator on how to interface with the machine.
AT9-80-031
I 1~83~7
The diskette drive 18 includes a magnetic disk
for maintaining keystroke and instruction data in a
semi-permanent manner in association with the text
storage buffer ~TSB) as a part of the random access
memory 20 discussed hereinafter. Typically, parts of
a single page of text or a complete page of text in a
document stored in the machine 10 is stored in the text
storage buffer while the remaining document is store~
in the diskette drive.
The random access memory 20 represents a
combination of electronic hardware and software to
perform a number of discrete functions within the text
processing machine 10. The keystroke control service
function 70 takes a ~eystroke from the keyboard 12 and
determines which of the keystroke service routines 72
is to be used to process the keystroke. A routine may
be found in keystroke service routines 72 to service
every keystroke on the keyboard 12. If the keystroke
represents a typed character for insertion in a text, a
routine in ~eystroke service routines 72 will insert the
keystroke in the data stream wi~hin the text storage
buffer (TSB) 74 for display and eventual hard copy.
Also within the keystroke service routines 72 are the
block definition routine 76 and the highlight routine
100. These routines act to define a block of characters
and perform the desired highlighting function on that
block.
The text storage buffer (TSB) 74 stores the text
being displayed on the display screen 16. Routines are
provided for handling and updating the text stored
therein within a TSB control block 75. A display access
method program 80 controls the formatting of text on
the display screen 16 through display refresh buffer 82.
The display access method program 80 may update the
display on display 16 in accordance with a "BUILD"
AT9-80-031
3~'7
subroutine as described in aforementioned Canadian
Patent Application No. 385,548, filed September 9,
1981.
The text stored in the TSs 74 is in a contextual
array. In other words, the characters and the controls
that format the characters in the text are stored in
sequential order from the beginning to the end of the
text. The information on display screen 16, in turn, is
displayed in a spatial array, i.e., each graphic to be
displayed is displayed at some spatial (X,Y) coordinate
relative to the top left hand corner of the display 16.
Therefore, to define a block of characters in both
TSB 74 and on the display screen 16, a bi-directional
character definition routine is stored as one of the
keystroke service routines. A routine is provided in
memory 20 for converting the contextual to the spatial
for interaction between the TSB and the display to
permit the bi-directional character definition.
One portion of the TSB control block 75 comprises
a set of pointers which identify characters in the text
stored in the TSB~ The TSB manager 84 will be
instructed by a keystroXe service routine to set the
first location pointer to identify a preselected
character in the TSB. $he TSB manager will also set
the second location pointer to a preselected character
stored in the TSB upon direction by the keystroke
service routine. Whenever text is moved or altered
within the text storage buffer, the location pointers
will always indicate the preselected characters as long
as the characters remain in the memory of the machine
10. The location pointers will indicate the preselected
~ characters even if they have moved out of the TSB and
into the diskette drive 18 for storage. Typically, as
AT~-80-031
,. ..
... . __ ~
,
I ~B836 ~ ~`
\
noted above, the TSB will store a portion of or one
entire pa~e of text in a given document stored within
the machine 10. The remainder of the document will be
stored or magnetic disks in the diskette drive 18.
The location pointers will also indicate whether the
preselected characters are on that page or stored in
the diskett.e drive. If stored in the.diskette drive,
the location pointers will indicate whether these
characters are on a prior or subsequent page.
The TSB control block 75 also includes a cursor
pointer which identifies a character stored in the TSs.
A cursor key controlled display cursor identifies a
character displayed on display screen 16 pe.rceived
visually by the operator. The cursor pointer and
display cursor identify the identical character
substantially continuously.during the operation of
machine lO. .The only time at which the indicated
characters may not correspond is during an internal
operation necessary to service an operator request,
for example, the display cursor ~oving across the line.
of text displayed. Between the time the operator
presses the cursor key and the ti~e when the cursor
moves on the display screen, there will be a very short
time when the location cursor is not equal to the
display cursor because the routines have not had time
to execute. Motion of the cursor on the display screen
16 is also described in aforementioned Canadian Patent
Application No. 385,548, filed.September 9, 1981.
With reference to FIGURE 3, the block definitlon
routine 76 is represented by a series of logic
sequences. The operator will first press a delete,
~ move or copy key on the keyboard 12 as represented by
sequence 90. The keystroke is transferred into the
AT9-80-031
,. .
;~, ~ .~
~'~
~ ~83~ ~
11
keystroke service routines 72 for processing in sequence
92. When the delete, move or copy key is depressed,
the position of the display cursor will identify the
location of the first location pointer to identify one
end of the character or block of characters to be
highlighted. This function is represented by sequence
93. The operator may, depending on the key depressed,
then employ either of two modes of highlighting. In
one mode, the other end of the bloc:k of characters is
determined by the location of the clisplay cursor at a
given moment. In the second mode, the other end of
the block is defined by the second location pointer,
regardless of the position of the display cursor.
The operator activates the nhighli~ht to cursor"
mode by depressing a suitable key on the keyboard 12.
If this mode is activated, the display cursor forms one
boundary of the block and the first location pointer
is the other, regardless of the other actions of the
operator. This activation is represented as sequence
94. The operator can also activate the "highlight
between ~ointers" mode represented by a sequence 96. In
this mode, the operator positions the display cursor to
identify the character which the operator desires to be
identified by the second location pointer. The operator
inputs a keystroke and the second location pointer
thereafter represents that character and defines the
other end of the block of characters. Subsequently, the
display cursor may be moved throughout the text without
shifting the boundaries of the character block.
In general, the machine 10 uses the "highlight
to cursor" mode after the first end of the block of
characters has been identified and until the other end
of the block has been identified. After both ends have
been identified, the system uses the "highlight between
pointers" mode until the function has been completed or
cancelled.
AT9-80-031
~ 168367
12
Without consideration of the particular mode,
the block definition routine 76 disables any other
highlights on the display screen 16, as represented by
sequence 98. There are spelling functions, spelling
check functions and other functions which also employ
highlighting of the display screen. The deletion of the
other highlighting avoids confusion for the operator
because the only thing the operator sees highlighted on
the display screen 16 is text to be deleted, moved or
copied.
The block definition routine 76 then calls a
highlight routine 100, as represen~:ed by sequence 102.
The purpose of the highlight routine is to determine
where the beginning and end pointers of the block of
text to be highlighted are to be located. This is
necessary as machine 10 builds the highlighted text
beginning at the top of the display and moves downward
in the text. Rowever, in the highlight between
pointers, the second location pointer is the second
one used in time, but not necessarily in the text.
The second pointer location may be prior to the first
pointer location in the text, at a corresponding
location or be positioned after the first pointer
location. In the highlight to cursor mode, the display
cursor forming the final boundary on the block may,
in turn, be positioned before at or after the first
location pointer in the text.
The "8UIL~" routine, represented by sequence 99,
will be called if necessary to change the page or
portion of a page stored in the TSB. Additional
keystroke information may be input in the text during
highlighting as desired, as represented by sequences lnl
and 1030 The machine 10 awaits the depression of an
enter key by the operator to determine the location of
35 , the second location pointer or cursor pointer to fully
AT9 - ~ O- 03 1
357
13
define the character or block of characters to be
highlighted. This function is represented as sequence
104.
The highlight routine 100 is illustrated as a
series of sequences in FIGU~E 6. When the highlight
routine is called, the routine will first determine
if the highlight function of machinè 10 is active, as
represented by test 105. If the highlight function
i5 not active, the routine will disable the display
highlight, represented by sequence 106, and return the
highlight routine to the routine of FIGU~ 3 at the
return call.
If the highlighting is active, the routine will
then determine whether the highlight to cursor or
highlight between pointers mode has been selected by
the operator. This determination is represented by a
test 108. If the highlight between pointers mode
is selected, the routine will then determine if the
first location pointer lies beyond the second location
pointer in the text as represented by test 110.
The internal registers of processor 14 maintain
a start pointer (SP) and an end pointer (~P) ~or entry
into the display control block 86 so that at the next
energization o~ the display access method program 80,
the text displayed will be highlighted beginning with
the topmost boundary and moving downward in the text.
The principle function of highlight routine 100 is to
determine which location pointer appears first in the
text and make this the start pointer. The other
location pointer then becomes the end pointer.
If test 110 is answered yes, i.e., the first
location pointer lies beyond the second location pointer
in the text, then the first location pointer is the
end pointer an~ the second location pointer is the start
AT9-80-031
~ 1683~7
14
pointer, as indicated by sequence 112. If the test 110
is answered no, then the second location pointer is the
end pointer and the first location pointer is the st~rt
pointer as represented by sequence 114.
Once the starting point and ending point de~ining
the boundary of the block is deterrnined, the
highlighting may be enabled to appear on the display
screen 16 in most cases. However, while most
characters stored in the TSB 74 occupy only one byte
of information, some characters, such as control
instructions, contain more than one byte per character
on the display. To highlight a ~ultiple byte character,
the end pointer should indicate the last byte of the
sequence of bytes representing that character. However,
the operator can only position the display cursor or
location pointer at the first byte of a multi-byte
character.
Each multi-byte character is introduced by a
sequence byte, a class byte, a count byte and a type
byte. The sequence byte indicates the presence of a
multi-byte character. The class byte and type byte
together tell the machine 10 what type of control is
represented by the m~lti-byte character. ~or example,
an instruction such as a format change or keyboard
change may be directed by these bytes. The count byte,
which is the second byte of the sequence, indicates how
long the sequence is, starting with and including the
collnt byte.
The highlight ro~tine 100 makes provisions for
mutli-byte character text controls. The routine
determines if the end point is on a text control,
represented by test 116. If so, the end pointer is
automatically positioned at the end of the text control
character by examining the count byte and moving the en~
pointer the appropriate number of bytes as represented
AT9-80-031
~ 1 ~6~3~7 --
by sequence 117. After sequence 117, or if the end
pointer is not on a text control, the start pointer and
end pointer are entered into the display control bloc~
86 and the text is highlighted on the display screen 16 as
represented by sequence 119.
If the highlight to cursor mode is elected, the
test 108 will be answered yes. In t:he highlight to
cursor mode, the highlight routine becomes somewhat ~ore
complex because the text stored in the TSB 74 is in a
stream of continuous contextual characters while the
text displayed on display screen 16 is in a spatial
(X,Y) coordinate format. When the operator moves the
display cursor up and down the text, the machine 10 must
translate the motion in the spatial array on the display
screen 16 to a contextual array in the TSB 74. This
tr~nslation is performed by a "MOVE" function. The
"MOV~" function permits the cursor pointer within
the TSB 74 to indicate the identical character as the
display cursor. The "MOVE" function is described in the
20 aforementioned Canadian Patent Application No. 385,548, ,
filed September 9, 1981.
The cursor pointer will be represented by a
temporary pointer (TP) during the operation in the
highlight to cursor mode as represented by sequence
115. If the display cursor is being moved up or down,
test 118 will direct the routine to call the "CONSP"
routine (convert spatial to contextual) as represented
by sequence 120, also described in the aforementioned
Canadian Patent Application No. 385,548, filed
September 9, 1981. The updated display cursor will
update the cursor pointer in the TSB 74 through the
"MOVE" function and
AT9-80-031
.~3
., ~
. ~ . . ... . _ _ . .. _ _ .
~ :~683~7
16
the new location of the cursor pointer will forrn a
temporary pointer (TP) in sequence 121. When this is
done, or if there is no cursor up or down rnotion, the
test 122 will determine whether the temporary pointer
is beyond the first location pointer. If so, the
temporary pointer represents the start pointer and the
first location pointer represents the end pointer as
represented by sequence 124. If the temporary pointer
is not beyond the first location pointer, the first
location pointer forms the start pointer and the
temporary pointer forms the end pointer as represented
b~ sequence 126. The start and end pointers may then be
entered into the display control block 86 for display
on the display screen 16 in a manner similar to the
highlight between pointer mode.
Referring to FIGURE 4, the cursor up or down
motion routine is illustrated by a series of sequences.
Activation of the cursor un or down motion by the
operator, represented by sequence 130, is processed in
the appropriate key stroke service routine represented
by sequence 132. The routine highlight is called, as
indicated by sequence 134, which provides the pointers
for highlighting on the display. The "MOVE" routine is
called, represented by sequence 136, to update the
display cursor and inform the machine of the desired
location of the cursor pointer in the TSB 74O The
routine sets the cursor point in the TSB 74, as
represented by sequence 138 before returning to the
routine of FIGURE 6, represented by sequence 140.
During cursor up or down motion, the display cursor
informs the cursor pointer within the TSs 74 of the
proper location so that the cursor pointer is
synchronous with the display cursor.
Referring to ~IGURE 5, a routine for other cursor
35, motion is provided which is represented by a series
of sequences. An operator may select a function on
AT9--8 0- 031
.
keyboard 12 which directs the cursor to go to a
particular page of text. The keystroke of such
a function is represented by sequence 152. The
appropriate ~eystroke service routine, represented as
sequence 154 processes the input keystroke. Internal
calculations within the machine determine where the
cursor pointer should be located in the TSB 74.
Sequence 156 represents the motion of the cursor pointer
within the TSB. It is then necessary to update the
display cursor with reference to the location of the
cursor pointer in the TSB 74. The function then calls
the highlight routine, as represented by sequence 158.
There are two paths that may be taken. If the new
cursor pointer location is on the same page of text
stored in the TSB 74 but not displayed on display screen
16, the sequence 160 will be answered no. .he routine
update will be called, as represented by sequence 162,
to update the display as it may be necessary to display
different portions of the same page as stored in the
20 TSB 74. If the new location of the cursor pointer is
on a page prior to or subsequent to the present page
stored in the TSB, it will be necessary to move the
cursor pointer and bui~d the text within the ~5B 7
as represented by sequence 164.
In summary, ~he bloc~ definition routine per~its
the operator to be~in at either end in defining a
character or block of characters to be deleted, moved or
copied. This feature enhances the productivity of the
operator by defining the block in whichever direction is
easiest, rather than placing an artificial constraint
on the direction of cursor movement. In addition,
depending on the function, the machine 10 will activate
either the "highlight to cursor" or "highlight between
pointers" mode. The "hiyhlight to cursor" mode
AT9 - 80 - 031
83~7
18
highlights the characters between the initial point of
the cursor and the present position of the cursor. The
"highlight between pointers" mode permits the cursor to
be moved on the display screen without affecting the
block after definition of the block.
Although a single embodiment of the invention has
been illustrated in the accompanying drawings described
in the foregoing detailed description, it will be
understood that the invention is not limited to the
embodiments disclosed, but is capable of numerous
rearrangements, moAifications and substitutions of parts
and elements without departing from the spirit of the
invention.
AT9-80-031