JPH04113396A - Display position determination system for character string - Google Patents

Display position determination system for character string

Info

Publication number
JPH04113396A
JPH04113396A JP2233829A JP23382990A JPH04113396A JP H04113396 A JPH04113396 A JP H04113396A JP 2233829 A JP2233829 A JP 2233829A JP 23382990 A JP23382990 A JP 23382990A JP H04113396 A JPH04113396 A JP H04113396A
Authority
JP
Japan
Prior art keywords
character string
character
characters
data
center position
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2233829A
Other languages
Japanese (ja)
Inventor
Shuji Kimura
修治 木村
Kazuhiro Hosoya
和弘 細谷
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP2233829A priority Critical patent/JPH04113396A/en
Publication of JPH04113396A publication Critical patent/JPH04113396A/en
Pending legal-status Critical Current

Links

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)

Abstract

PURPOSE:To display the character string in a display area at a specific position by displaying the character string from the display position of the head character which is found by arithmetic according to data indicating the center position of the display area and the number of characters. CONSTITUTION:A printer device 1 prints a control report and the character string of a necessary item name, etc., is specified automatically and printed in specified language at a specific place. A character string storage part 11 is stored with the numbers of characters and character data DC as to many character strings to be printed including languages of respective countries. A center position specification part 12 is stored with the center position Xc of the print area and when a character string is printed, the center position Xc is read in an arithmetic part 13 so as to determine the array position of the character string in a row. The arithmetic part 13 calculates a write start position X according to the number N of characters and the center position Xc. A write control part 14 controls the writing of the character data DC to a line memory 15 according to the write start position X and the number N of characters. A mechanism 16 prints the character string on a document CS according to the print data from the memory 15.

Description

【発明の詳細な説明】 〔概 要〕 印刷又は画面によって文字列を表示する際の表示位置決
定方式に関し、 各国の言語に対応する多数のプログラムを必要とするこ
となく、且つデータ量を増大させることなく、各国の言
語に対応した文字列を表示領域内に表示するための文字
列の表示位置決定方式を提供することを目的とし、 一連の文字からなる文字列を表示領域内の所定の位置に
表示するための文字列の表示位置決定方式であって、表
示すべき文字列について、当該文字列を構成する文字デ
ータとともに文字数を示すデータを持たせておき、前記
表示領域の中心位置を示すデータと前記文字列の文字数
に基づいて当該文字列の先頭文字の表示位置を演算し、
演算により求められた先頭文字の表示位置から当該文字
列を表示するように構成する。
[Detailed Description of the Invention] [Summary] Regarding a display position determination method when displaying a character string by printing or on a screen, the present invention does not require multiple programs corresponding to the languages of each country and increases the amount of data. The purpose of this method is to provide a method for determining the display position of character strings for displaying character strings in the display area that correspond to the languages of each country, without having to A method for determining the display position of a character string for display in a display area, in which a character string to be displayed has data indicating the number of characters along with character data composing the character string, and indicates the center position of the display area. Calculate the display position of the first character of the string based on the data and the number of characters in the string,
The character string is configured to be displayed from the display position of the first character determined by the calculation.

〔産業上の利用分野〕[Industrial application field]

本発明は、ファクシミリ装置、プリンタ装置、デイスプ
レィ装置などにおいて、印刷又は画面によって文字列を
表示する際の表示位置決定方式に関する。
The present invention relates to a method for determining a display position when displaying a character string by printing or on a screen in a facsimile machine, a printer device, a display device, or the like.

近年の国際化にともなって、ある国において製造され使
用されているプリンタ装置、デイスプレィ装置などが、
はぼ同時期に他の国においても使用されるケースが増加
してきた。
With recent internationalization, printer devices, display devices, etc. manufactured and used in a certain country,
At around the same time, its use increased in other countries as well.

そのため、これらプリンタ装置、デイスプレィ装置など
において表示(又は印刷)されるメツセージや定型表示
文字などは、プログラムなどの変更を行うことなく各国
の言語に対応して所定の位置に表示可能であることが望
まれている。
Therefore, messages and standard display characters displayed (or printed) on these printers, display devices, etc. can be displayed in predetermined positions in accordance with the languages of each country without changing the program. desired.

〔従来の技術〕[Conventional technology]

従来において、文字列を表示領域内の中央位置に表示(
印字を含む)するために、当該文字列の書き出し位置(
先頭文字の位置)がその文字列に応じてプログラムによ
り与えられていた。
Conventionally, character strings were displayed at the center position within the display area (
(including printing), change the writing position of the string (including printing).
The position of the first character) was given by the program according to the string.

第5図は従来におけるプリンタ装置による文字列の配置
処理を示すフローチャートである。
FIG. 5 is a flowchart showing character string arrangement processing performed by a conventional printer device.

すなわち、プログラムによって当該文字列の書き出し位
置Xがレジスタにセントされ(ステップ#51)、当該
文字列の文字データとともに格納されている文字数Nの
データが繰り返しカウンタにセットされ(ステップ#5
2)、当該文字列の文字データが印字データとして取り
込まれ(ステップ#53L印字データの中の先頭データ
が書き出し位置にセットされ(ステップ#54L書き出
し位置の更新及び繰り返しカウンタのデクリメントが行
われ(ステップ#55L繰り返しカウンタが零になるま
でステップ#53以降の処理が繰り返される(ステップ
#56)。
That is, the program writes the writing start position X of the character string in the register (step #51), and sets the data of the number of characters N stored together with the character data of the character string in the repeat counter (step #5).
2), the character data of the character string is taken in as print data (Step #53L The first data in the print data is set to the write start position (Step #54L The write start position is updated and the repetition counter is decremented (Step #54L) #55L The processing from step #53 onwards is repeated until the repeat counter becomes zero (step #56).

例えば、日本語の文字列「送信」を帳票の中央位置に印
刷する際には、当該文字列「送信」に対する書き出し位
置X1がプログラムによって与えられ、文字数Nのデー
タとして「2」が格納されているので、2文字の配列が
行われた後に印字が行われる。
For example, when printing the Japanese character string "send" in the center of a form, the program will give the writing position X1 for the character string "send" and store "2" as data for the number of characters N. Therefore, printing is performed after the two characters are arranged.

これによって、第6図に示すように、文字列「送信」が
書き出し位置X1で指定された帳票の位置に印字される
As a result, as shown in FIG. 6, the character string "Send" is printed at the position of the form designated by the writing start position X1.

また、書き出し位置Xをプログラムにより与える代わり
に、各文字列について、それぞれの文字データ及び文字
数のデータとともに書き出し位置を示すデータを格納し
ておき、これによって当該文字列の書き出し位置Xを与
えるようにした方式さらには、固定長データ方式を採用
して文字列の文字数を揃えておき、書き出し位置を同一
の位置とするようにした方式もある。
Also, instead of giving the writing position In addition, there is also a method that uses a fixed length data method to keep the number of characters in the string the same and write the data at the same position.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

しかし、書き出し位置χをプログラムにより与える方式
では、日本語の文字列「送信」と同一の意味を示す英語
のrTRANsMI SS I ONJを日本語と同様
に表示領域内の中央位置に印字する場合には、これらの
文字数が互いに異なるため、第7図に示すように異なる
書き出し位置X2を与えるための別のプログラムを用意
しなければならない。
However, in the method of giving the writing start position χ by a program, if the English character string rTRANsMI SS I ONJ, which has the same meaning as the Japanese character string "send", is to be printed at the center position within the display area as in Japanese, , these numbers of characters are different from each other, so another program must be prepared to give different writing start positions X2 as shown in FIG.

そのため、同一のプリンタ装置で各国の言語に対応する
ためには、それぞれの言語ごとにプログラムを準備して
おかなければならず、そのプログラムの作成、変更、メ
ンテナンスなどに時間を要するとともに、プログラムを
格納するためのメモリ容量が増大するという問題があっ
た。
Therefore, in order to use the same printer device to support the languages of each country, programs must be prepared for each language, which requires time to create, modify, and maintain the programs. There is a problem in that the memory capacity for storage increases.

また、書き出し位置Xを示すデータをそれぞれの文字列
のデータとして格納しておく方式では、そのためにデー
タ量が増大してしまうという問題があった。
Further, in a method in which data indicating the writing start position X is stored as data for each character string, there is a problem in that the amount of data increases.

さらに、固定長データ方式では、全ての国の言語を考慮
して最大文字数をデータ長として決定しなければならな
いばかりでなく、空白文字という余分なデータを持たせ
なければならないためにデータ量が増大するという問題
があった。
Furthermore, with the fixed-length data method, not only must the maximum number of characters be determined as the data length considering the languages of all countries, but also the amount of data increases due to the need to include extra data in the form of blank characters. There was a problem.

本発明は、上述の問題に鑑み、各国の言語に対応する多
数のプログラムを必要とすることなく、且つデータ量を
増大させることなく、各国の言語に対応した文字列を表
示領域内に表示するための文字列の表示位置決定方式を
提供することを目的としている。
In view of the above-mentioned problems, the present invention displays character strings corresponding to the languages of each country in a display area without requiring multiple programs corresponding to the languages of each country and without increasing the amount of data. The purpose of this paper is to provide a method for determining the display position of character strings.

〔課題を解決するための手段〕[Means to solve the problem]

本発明に係る方式は、上述の課題を解決するため、第1
図に示すように、一連の文字からなる文字列を表示領域
内の所定の位置に表示するための文字列の表示位置決定
方式であって、表示すべき文字列について、当該文字列
を構成する文字データDCとともに文字数Nを示すデー
タを持たせておき、前記表示領域の中心位置Xcを示す
データと前記文字列の文字数Nに基づいて当該文字列の
先頭文字の表示位置Xを演算し、演算により求められた
先頭文字の表示位置Xから当該文字列を表示する。
In order to solve the above-mentioned problems, the system according to the present invention has the following advantages:
As shown in the figure, this is a character string display position determination method for displaying a character string consisting of a series of characters at a predetermined position within a display area, in which the character string to be displayed is configured. Data indicating the number of characters N is provided along with the character data DC, and the display position X of the first character of the character string is calculated based on the data indicating the center position Xc of the display area and the number N of characters of the character string. The character string is displayed from the display position X of the first character determined by .

〔作 用〕[For production]

文字列を表示するに当たり、帳票C3などの表示領域内
における中心位置Xcが与えられ、中心位置Xcと文字
数Nとに基づいて書き出し位置Xが演算により求められ
る。書き出し位置Xから当該文字列が配列されることに
より、行内におけるセンタリングが行われる。
When displaying a character string, a center position Xc in a display area such as the form C3 is given, and a writing start position X is calculated based on the center position Xc and the number N of characters. By arranging the character string from the writing start position X, centering within the line is performed.

〔実施例〕〔Example〕

以下、本発明の実施例を図面を参照しつつ説明する。 Embodiments of the present invention will be described below with reference to the drawings.

第1図は本発明に係る表示位置決定方式を採用したプリ
ンタ装置1の要部を示すブロック図である。
FIG. 1 is a block diagram showing the main parts of a printer device 1 that employs a display position determination method according to the present invention.

プリンタ装置1においては、適当なタイミングで管理レ
ポートが印刷されるようになっており、その際には、管
理レポートの書式に必要な項目名などの文字列が自動的
に指定され、所定の箇所に指定された言語で印字される
The printer device 1 is designed to print a management report at an appropriate time, and at that time, character strings such as item names necessary for the format of the management report are automatically specified and will be printed in the specified language.

そのために、プリンタ装置1は、文字列データ格納部1
1、中心位置指定部12、演算部13、書込みIIJ御
部14、ラインメモリ15、印字機構16などから構成
されている。
For this purpose, the printer device 1 has a character string data storage section 1.
1, a center position specifying section 12, a calculation section 13, a writing IIJ control section 14, a line memory 15, a printing mechanism 16, etc.

文字列データ格納部11には、各国の言語を含む印刷す
べき多数の文字列について、その文字数N、及び文字デ
ータDCが格納されている。なお、いずれの言語によっ
て印刷を行うかを選択するための図示しないスイッチが
プリンタ装置1に設けられており、このスイッチにより
選択された言語の文字列が用いられる。
The character string data storage unit 11 stores the number N of characters and character data DC for a large number of character strings to be printed including languages of various countries. Note that the printer device 1 is provided with a switch (not shown) for selecting which language to print in, and the character string of the language selected by this switch is used.

中心位置指定部12には、印刷すべき領域における中心
位置Xcが格納されており、文字列の印刷を行う際には
行内における文字列の配列位置を決定するために中心位
置Xcが演算部13に読み込まれる。中心位置Xcとし
ては、例えば1行内の指数によって示される。
The center position specifying unit 12 stores the center position Xc in the area to be printed, and when printing a character string, the center position Xc is stored in the calculation unit 13 in order to determine the arrangement position of the character string within a line. is loaded into. The center position Xc is indicated by an index within one line, for example.

演算部13は、文字数N及び中心位置Xcに基づいて書
き出し位置Xを演算するためのものであり、次式にした
がって演算を行う。
The calculation unit 13 is for calculating the writing start position X based on the number of characters N and the center position Xc, and performs the calculation according to the following equation.

X=X c−(N/ 2 ) −−(1)書込み制御部
14は、書き出し位置X及び文字数Nに基づいて、ライ
ンメモリI5への文字データDCの書き込みを制御する
X=X c -(N/2) --(1) The write control unit 14 controls writing of the character data DC to the line memory I5 based on the write start position X and the number of characters N.

ラインメモリ15は、印刷すべき1行分の印字データを
格納するためのものである。
The line memory 15 is for storing print data for one line to be printed.

印字機構16は、ラインメモリ15から送られてくる印
字データに基づいて帳票C3に印字を行う。
The printing mechanism 16 prints on the form C3 based on the print data sent from the line memory 15.

第2図はプリンタ装置1の印字処理を示すフローチャー
トである。
FIG. 2 is a flowchart showing the printing process of the printer device 1.

管理レポートの印字処理が開始されて印字すべき文字列
が指定されると、まず、演算部13によって、書き出し
位置Xが演算により求められる(ステップ#11)。
When the printing process of the management report is started and a character string to be printed is specified, first, the calculation unit 13 calculates the writing start position X (step #11).

次に、書込み制御部14の繰り返しカウンタに文字数N
がセットされ(ステップ#12)、文字データDCが印
字データとして取り込まれ(ステップ#13)、ライン
メモリ15の書き出し位置Xに印字データの中の先頭デ
ータがセットされる(ステップ#14)。
Next, the number of characters N is entered in the repetition counter of the write control unit 14.
is set (step #12), the character data DC is taken in as print data (step #13), and the first data in the print data is set at the write start position X of the line memory 15 (step #14).

書込み制御部14において書き出し位置Xが更新され、
繰り返しカウンタがデクリメントされ(ステップ#15
L繰り返しカウンタが零になるまでステップ#13以降
の処理が繰り返される(ステップ#16)。
The write start position X is updated in the write control unit 14,
The repeat counter is decremented (step #15)
The processing from step #13 onwards is repeated until the L repetition counter becomes zero (step #16).

ラインメモリ15にデータが揃ったら、印字機構に送ら
れて1行分の印字が行われる(ステップ#17)。
Once the data is in the line memory 15, it is sent to the printing mechanism and one line is printed (step #17).

第3図及び第4図は日本語の文字列「送信」及び英語の
文字列rTRANsMI SS I ONJを帳票C8
に印刷した状態を示す図である。つまり、第3図は日本
語が指定されていた場合、第4図は英語が指定されてい
た場合である。
Figures 3 and 4 show the Japanese character string "send" and the English character string rTRANsMI SS I ONJ in form C8.
It is a figure which shows the state printed on. That is, FIG. 3 shows the case when Japanese is specified, and FIG. 4 shows the case when English is specified.

同図に示すように、帳票C3の幅方向の中央位置が中心
位置Xcによって指定されることによって、文字列の中
央部が中心位置Xcと一致するように演算部13によっ
て書き出し位置Xが求められ、文字数Nの異なる種々の
言語に対応した文字が帳票C3の中央位置に印刷される
As shown in the figure, by specifying the center position in the width direction of the form C3 by the center position Xc, the calculation unit 13 calculates the writing start position , characters corresponding to various languages with different numbers of characters N are printed at the center position of the form C3.

したがって、帳票C3の印刷領域の中心位置XCを用意
しておくだけでよく、各国の言語に対応する多数のプロ
グラムを必要としない。また、文字列のデータとしては
文字数N及び文字データDCであり、書き出し位置Xに
関するデータを必要とせず且つ空白文字のような無駄な
データを必要しないので、文字列のデータ量を増大させ
ることがない。
Therefore, it is only necessary to prepare the center position XC of the print area of the form C3, and there is no need for a large number of programs corresponding to the languages of each country. In addition, the data of the character string is the number of characters N and the character data DC, and data regarding the writing position do not have.

上述の実施例においては、1行分の文字列について説明
したが、複数の文字列が複数行に渡って印刷される場合
に、それぞれの行における書き出し位1xを同一とする
ためには、例えば書き出し位置Xを前の行と同一にする
か又は新たに演算により求めるかを決定するためのフラ
グを制御情報として持たせておき、このフラグに応じて
、新たに書き出し位置Xの演算を行うことなく前と同一
の書き出し位置Xから文字列を配列するようにすればよ
い。
In the above embodiment, a character string for one line was explained, but when multiple character strings are printed over multiple lines, in order to make the writing start position 1x in each line the same, for example, A flag for determining whether to make the writing start position X the same as the previous line or to obtain it by a new calculation is provided as control information, and a new calculation of the writing start position Instead, the character strings can be arranged from the same writing position X as before.

上述の実施例においては、帳票C8O幅方向の中央位置
に文字列を印刷する場合について説明したが、帳票C3
などに設けられた欄内又は表内の中央位置に文字列を印
刷するためには、その欄内又は表内における中心位fl
(Xcを演算部I3に与えるようにすればよい。
In the above embodiment, a case has been described in which a character string is printed at the center position in the width direction of form C8O.
In order to print a character string at the center position in a column or table provided in
(Xc may be given to the calculation unit I3.

本発明は、プリンタ装置1を内蔵したファクタミリ装置
、その他の装置における管理レポートその他の印刷、デ
イスプレィ装置にけるメツセージの表示など、種々の文
字列の表示に適用することができる。
The present invention can be applied to displaying various character strings, such as printing management reports and other documents in a factory device incorporating the printer device 1 or other devices, and displaying messages on a display device.

〔発明の効果〕〔Effect of the invention〕

本発明によると、各国の言語に対応する多数のプログラ
ムを必要とすることなく、且つデータ量を増大させるこ
となく、各国の言語に対応した文字列を表示領域内に表
示するための文字列の表示位置決定方式を提供すること
ができる。
According to the present invention, character strings can be created to display character strings corresponding to the languages of each country in a display area without requiring a large number of programs corresponding to the languages of each country and without increasing the amount of data. A display positioning scheme can be provided.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明に係る表示位置決定方式を採用したプリ
ンタ装置の要部を示すブロック図、第2図はプリンタ装
置の印字処理を示すフローチャート、 第3図は日本語の文字列「送信」を帳票に印刷した状態
を示す図、 第4図は英語の文字列rTRANSMI SS rON
Jを帳票に印刷した状態を示す図、第5図は従来におけ
るプリンタ装置による文字列の配置処理を示すフローチ
ャート、 第6図は従来における日本語の文字列「送信jを帳票に
印刷した状態を示す図、 第7図は従来における英語の文字列rTRANSMIS
SION」を帳票に印刷した状態を示す図である。 図において、 DCは文字データ、 Nは文字数、 Xcは中心位置、 Xは書き出し位置(表示位置)である。
Fig. 1 is a block diagram showing the main parts of a printer device that employs the display position determination method according to the present invention, Fig. 2 is a flowchart showing the printing process of the printer device, and Fig. 3 is a Japanese character string “send”. Figure 4 shows the English character string rTRANSMI SS rON printed on a form.
Figure 5 is a flowchart showing the process of arranging character strings by a conventional printer device. Figure 6 is a diagram showing the state in which the conventional Japanese character string ``Send j'' is printed on a form. Figure 7 shows the conventional English character string rTRANSMIS.
FIG. 3 is a diagram showing a state in which "SION" is printed on a form. In the figure, DC is character data, N is the number of characters, Xc is the center position, and X is the writing start position (display position).

Claims (1)

【特許請求の範囲】[Claims] (1)一連の文字からなる文字列を表示領域内の所定の
位置に表示するための文字列の表示位置決定方式であっ
て、 表示すべき文字列について、当該文字列を構成する文字
データ(DC)とともに文字数(N)を示すデータを持
たせておき、 前記表示領域の中心位置(Xc)を示すデータと前記文
字列の文字数(N)に基づいて当該文字列の先頭文字の
表示位置(X)を演算し、 演算により求められた先頭文字の表示位置(X)から当
該文字列を表示する ことを特徴とする文字列の表示位置決定方式。
(1) A character string display position determination method for displaying a character string consisting of a series of characters at a predetermined position within a display area, in which character data ( DC) as well as data indicating the number of characters (N), and based on the data indicating the center position of the display area (Xc) and the number of characters (N) in the character string, determine the display position ( A method for determining the display position of a character string, characterized in that the character string is displayed from the display position (X) of the first character determined by the calculation.
JP2233829A 1990-09-03 1990-09-03 Display position determination system for character string Pending JPH04113396A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2233829A JPH04113396A (en) 1990-09-03 1990-09-03 Display position determination system for character string

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2233829A JPH04113396A (en) 1990-09-03 1990-09-03 Display position determination system for character string

Publications (1)

Publication Number Publication Date
JPH04113396A true JPH04113396A (en) 1992-04-14

Family

ID=16961218

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2233829A Pending JPH04113396A (en) 1990-09-03 1990-09-03 Display position determination system for character string

Country Status (1)

Country Link
JP (1) JPH04113396A (en)

Similar Documents

Publication Publication Date Title
JPH058449B2 (en)
JPH03229356A (en) Layout display controller for document processor
JPH0137783B2 (en)
JPH0438005B2 (en)
JPH04113396A (en) Display position determination system for character string
JPH0452476B2 (en)
JPH0522933B2 (en)
JPS62229464A (en) Document processor
JP3266170B2 (en) Data display printer
JP2903516B2 (en) Document processing device
JP2700001B2 (en) Character data output device
JPH02255965A (en) Word processor
JPS60164873A (en) Word processor provided with simple language for preparation of table
JPS59123046A (en) Display system of document processor
JPH06162007A (en) Document preparing method
JPH10235823A (en) Document composing device
JPS61286177A (en) Document-forming device
JPH06162004A (en) Document preparing method
JPH05100805A (en) Format design system
JPH0293496A (en) Character output device
JPH06162006A (en) Document preparing method
JPS63103373A (en) Document producing device
JPH05303576A (en) Document processing system
JPH03263257A (en) Document processor
JPH0969089A (en) Table output device