JP3933517B2 - DOCUMENT SEARCH METHOD, DOCUMENT SEARCH DEVICE, DOCUMENT SEARCH PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM - Google Patents

DOCUMENT SEARCH METHOD, DOCUMENT SEARCH DEVICE, DOCUMENT SEARCH PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM Download PDF

Info

Publication number
JP3933517B2
JP3933517B2 JP2002136686A JP2002136686A JP3933517B2 JP 3933517 B2 JP3933517 B2 JP 3933517B2 JP 2002136686 A JP2002136686 A JP 2002136686A JP 2002136686 A JP2002136686 A JP 2002136686A JP 3933517 B2 JP3933517 B2 JP 3933517B2
Authority
JP
Japan
Prior art keywords
character
document
ruby
search
result
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.)
Expired - Lifetime
Application number
JP2002136686A
Other languages
Japanese (ja)
Other versions
JP2003330917A (en
Inventor
靖朗 立入
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.)
Sharp Corp
Original Assignee
Sharp Corp
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 Sharp Corp filed Critical Sharp Corp
Priority to JP2002136686A priority Critical patent/JP3933517B2/en
Publication of JP2003330917A publication Critical patent/JP2003330917A/en
Application granted granted Critical
Publication of JP3933517B2 publication Critical patent/JP3933517B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Images

Description

【0001】
【発明の属する技術分野】
本発明は、ルビや下線、太字、斜体、色、フォント、フォントサイズ等の装飾が付加された文字を含む文書を検索することが可能である文書検索方法、文書検索装置、文書検索プログラム、および、そのプログラムを記録した記録媒体に関するものである。
【0002】
【従来の技術】
文書にはルビや下線、太字、斜体、色、フォント、フォントサイズ等の装飾が存在する。ルビは読みづらい文字や読み誤りやすい文字に対して付加される読み仮名である。下線、太字、斜体、色、フォント、フォントサイズは、その文字を強調するため、注意箇所を表示するため、あるいは他の文字と区別するために付加される。ルビの表示形態を図8に示す。図8(a)は文字の上部に小さく読み仮名を付加している。図8(b)は文字の後に括弧書きで付加している。文書表示装置の中には、ユーザの好みに応じてルビを表示するか否かを選択することができるものもあり、その場合にはルビを表示するよう選択したときのみルビが表示される。下線、太字、斜体、色、フォント、フォントサイズ等の装飾もユーザの好みに応じて表示するか否か選択することができる。
【0003】
また、ルビを文書中に格納するデータ構造の形態としては、文字の後に括弧書きで付加する方法や、HTML(Hyper Text Markup Language)、XML(eXtensible Markup Language)といったマークアップ言語を使用する方法がある。文字の後に括弧書きで付加する方法は、図8(b)の表示形態と同様にルビを格納する。マークアップ言語を使用する方法の一例を図9(a)に示す。ルビ付きの文字列を<ruby>と</ruby>という文字列で囲み、その中でさらにルビを振る文字列を<rb>と</rb>という文字列の間に書き、ルビを<rt>と</rt>という文字列の間に書く。
【0004】
ルビ以外の装飾の場合、HTMLでは以下のようなデータ構造の形態になる。いずれも装飾したい文字をはさむ形態で使用する。
下線:<u></u>
太字:<b></b>
斜字:<i></i>
色:<font color="#ff0000"></font>
フォント:<font face="MS ゴシック"></font>
フォントサイズ:<font size="7"></font>
※<font>は色、フォント、サイズを同時に指定できる。
例:<font color="#ff0000" face="MS ゴシック" size="7">装飾される文字</font>
一般に、文書作成装置や文書表示装置には文字列の検索機能がある。これは、ユーザがある文字列を指定し、検索機能を実行すると、指定した文字列が文書中に存在するか否か、結果を返す機能である。これによりユーザは、所望の文字列を文書から探し出すことができる。ルビを含む文書でも検索を行うことは可能であり、例えば図9(a)に示す文字列が文中に存在する場合、図9(b)のように、ルビを示す括弧や文字列を削除した状態に対し検索を行う方法が一般的である。検索結果の一般的な表示形態を図11に示す。図11は「かいけつ」という文字列で検索した結果の一例であるが、図11(a)のようにルビを反転させる方法や、図11(b)のようにルビが振ってある文字列を反転させる方法や、ルビとルビが振ってある文字列の双方を反転させる方法がある。下線、太字、斜字、色、フォント、フォントサイズについてもルビと同様に検索を行い、表示することができる。
【0005】
また、特開平5−257939号公報では、以下の方法を提案している。仮名漢字変換方式で入力した読み仮名を、仮名漢字変換時に変換された漢字の語または熟語と共に文書として記憶し、その文書の再使用時に入力した読み仮名を検索キーとして使用する。例えば、操作者が入力手段から「ぶんしょ」と入力した後、仮名漢字変換で「文書」に変換し、決定すると、決定した語(文書)と読み仮名(ぶんしょ)を共に記憶手段に格納する。読み仮名を再度入力し、例えば「ブンショ」と訂正することも可能である。こうして変換した語および読み仮名の双方を決定後、ともに記憶手段に文書として格納する。この文書に対し、読み仮名である「ブンショ」で検索すると、「文書」という語を検索結果として得ることができる。
【0006】
【発明が解決しようとする課題】
ところが、上記方法では以下のような問題がある。
【0007】
図9(a)で示した文字列を含む文書に対し「かいけつ」で検索した場合、図9(a)で示した文字列を見つけることができる。しかし、検索時に図9(a)で示した文字列は図9(b)の状態に対し検索がかけられるため、「課題を解決する」、「課題をかいけつする」といった、ルビ付文字列の前後の文字を含めた文字列で検索すると見つけることができない。
【0008】
また、図10(a)に示すように、「解決」という熟語に対し「解」と「決」のそれぞれにルビがつけられている場合もある。この場合、検索時は図10(b)の状態に対し検索がかけられるため、「かいけつ」、「解決」で検索しても見つけることができない。
【0009】
特開平5−257939号公報で提案された方法にも同様の問題がある。例えば「課題を解決する手段」という文字列が文書中にあり、「解決」という文字列に「カイケツ」という読み仮名が登録されていたとすると、「解決」「カイケツ」で検索した場合は見つけることができるが、「課題を解決する」「課題をカイケツする」といった、読み仮名付文字列の前後の文字を含めた文字列で検索した際の結果に関しては言及されていない。また、仮名漢字変換時に読み仮名を漢字の語と共に文書として記憶し、その文書の再使用時に入力した読み仮名を検索キーとして使用するため、「解」と「決」を1文字ずつ変換した場合はそれぞれに「カイ」、「ケツ」という読み仮名が登録される。そのため、「カイケツ」という読み仮名で検索することはできない。
【0010】
さらに、図11のように検索結果を表示する方法には以下の問題がある。
文書表示装置の中には、ユーザの好みに応じてルビを表示するか否かを選択することができるものもあり、その場合にはルビを表示するよう選択したときのみルビが表示される。図11のように検索結果を表示した場合、ルビを表示しているときは検索結果がよく分かるが、ルビを表示していないときは何が見つかったのか分かりづらく、ユーザが混乱する恐れがある。例えば図9(a)の文に対して「いけ」で検索した場合、ルビの「かいけつ」の一部が該当するため、文書表示装置には図12のように検索結果が表示される。図12(a)ではどこが該当するのか全く分からず、図12(b)でも「解決」の読みが分かっていないとどこが該当するのか分かりづらい。
【0011】
本発明は、上述の問題に鑑みてなされたものであり、ルビや下線、太字、斜体、色、フォント、フォントサイズ等の装飾が付加された文字を含む文書を検索することが可能であり、それをユーザに分かりやすく知らせることが可能である文書検索方法、文書検索装置、文書検索プログラム、および、そのプログラムが記録された記録媒体を提供するものである。
【0012】
【課題を解決するための手段】
上記課題を達成するため、本発明のある局面に従うと、文書検索方法は、文書中の文字にルビが付加された文書をコンピュータの記憶手段が記憶するステップと、
前記文書を、ルビを含む文書の文字が順に格納される文字格納領域と、文書の文字がルビであるか、ルビが振られる基底文字であるか、ルビでも前記基底文字でもないかを識別するフラグが格納されるルビフラグ格納領域とからなるデータ構造にコンピュータの変換手段が変換するステップと、
前記ルビが付加された文字あるいはルビを検索するための検索条件をコンピュータの記憶手段が記憶するステップと、
前記検索条件にしたがって前記データ構造に変換された前記文書をコンピュータの検索手段が検索するステップと、
検索結果をコンピュータの表示手段が表示するステップと、を含み、
前記変換するステップは、
前記文字格納領域に文字を格納するに際し、前記基底文字の直後または直前に当該基底文字のルビを配置し、
前記文字格納領域に格納される文字と前記ルビフラグ格納領域に格納されるフラグとを、互いに関連つけて格納し、
前記検索するステップは、
前記検索条件と比較する前記文書内の文字位置を決定するステップと、
前記検索条件の文字と前記文書内の文字をおのおの比較するステップと、
前回比較した結果一致する前記文書内の文字がルビでありかつ今回比較した結果一致する前記文書内の文字にルビが付されている場合および、前回比較した結果一致する前記文書内の文字にルビが付されていてかつ今回比較した結果一致する前記文書内の文字がルビである場合に、前記検索条件文字位置はそのままで、前記文書内の比較する文字位置のみをずらすステップとを含むことを特徴とする。
【0014】
好ましくは、請求項1に記載の文書検索方法において、前記検索結果を表示するステップは、検索前にルビを表示しておらず、かつ検索結果にルビが含まれているときに、ルビを表示し、強調表示するステップを含むことを特徴とする
【0015】
好ましくは、請求項1に記載の文書検索方法において、前記検索結果を表示するステップは、検索前にルビを表示しておらず、かつ検索結果にルビが含まれているときに、ルビが付加されている文字をルビで置換し、ルビを強調表示するステップを含むことを特徴とする
【0016】
本発明のさらに他の局面に従うと、文書検索装置は、文書中の文字にルビが付加された文書を記憶する文書記憶手段と、
前記文書を、ルビを含む文書の文字が順に格納される文字格納領域と、文書の文字がルビであるか、ルビが振られる基底文字であるか、ルビでも前記基底文字でもないかを識別するフラグが格納されるルビフラグ格納領域とからなるデータ構造に変換する変換手段と、
前記ルビが付加された文字あるいはルビを検索するための検索条件を記憶する検索文字記憶手段と、
前記検索条件にしたがって前記データ構造に変換された前記文書を検索する検索手段と、
検索結果を表示する表示手段と、を含み、
前記変換手段は、
前記文字格納領域に文字を格納するに際し、前記基底文字の直後または直前に当該基底文字のルビを配置し、
前記文字格納領域に格納される文字と前記ルビフラグ格納領域に格納されるフラグとを、互いに関連つけて格納し、
前記検索手段は、
前記検索条件と比較する前記文書内の文字位置を決定する比較文字位置決定手段と、
前記検索条件の文字と前記文書内の文字をおのおの比較する比較手段と、
前回比較した結果一致する前記文書内の文字がルビでありかつ今回比較した結果一致する前記文書内の文字にルビが付されている場合および、前回比較した結果一致する前記文書内の文字にルビが付されていてかつ今回比較した結果一致する前記文書内の文字がルビである場合に、前記検索条件文字位置はそのままで、前記文書内の比較する文字位置のみをずらす比較文字位置前進手段とを含むことを特徴とする。
【0018】
本発明のさらに他の局面に従うと、文書検索プログラムは、文書中の文字にルビが付加された文書をコンピュータの記憶手段が記憶するステップと、
前記文書を、ルビを含む文書の文字が順に格納される文字格納領域と、文書の文字がルビであるか、ルビが振られる基底文字であるか、ルビでも前記基底文字でもないかを識別するフラグが格納されるルビフラグ格納領域とからなるデータ構造にコンピュータの変換手段が変換するステップと、
前記ルビが付加された文字あるいはルビを検索するための検索条件をコンピュータの記憶手段が記憶するステップと、
前記検索条件にしたがって前記データ構造に変換された前記文書をコンピュータの検索手段が検索するステップと、
検索結果をコンピュータの表示手段が表示するステップと、をコンピュータに実行させる文書検索プログラムであって、
前記変換するステップは、
前記文字格納領域に文字を格納するに際し、前記基底文字の直後または直前に当該基底文字のルビを配置し、
前記文字格納領域に格納される文字と前記ルビフラグ格納領域に格納されるフラグとを、互いに関連つけて格納し、
前記検索するステップは、
前記検索条件と比較する前記文書内の文字位置を決定するステップと、
前記検索条件の文字と前記文書内の文字をおのおの比較するステップと、
前回比較した結果一致する前記文書内の文字がルビでありかつ今回比較した結果一致する前記文書内の文字にルビが付されている場合および、前回比較した結果一致する前記文書内の文字にルビが付されていてかつ今回比較した結果一致する前記文書内の文字がルビである場合に、前記検索条件文字位置はそのままで、前記文書内の比較する文字位置のみをずらすステップとを含むことを特徴とする。
【0020】
本発明のさらに他の局面に従うと、コンピュータ読み取り可能な記録媒体は、請求項に記載の文書検索プログラムを記録する。
【0021】
【発明の実施の形態】
以下、本発明の実施の形態の一例を、具体例を用いて説明する。
【0022】
図1に示すように、本発明の実施の形態に係る文書検索装置は、コンピュータ1と、コンピュータ1に指示を与えるためのキーボード5およびマウス6と、各種情報を表示するためのディスプレイ2と、コンピュータ1で実行されるプログラムおよび検索対象となる文書をそれぞれ読み取るための磁気ディスク装置3、CD−ROM(Read Only Memory)装置7および通信モデム9とを含み、各機器間はバスライン15で相互に接続される。
【0023】
文書検索を行うためのプログラムおよび検索対象となる文書は、コンピュータ1で読み取り可能な記録媒体である磁気ディスク4またはCD−ROM8に記録され、磁気ディスク装置3またはCD−ROM装置7でそれぞれ読み取られる。または、通信回線を解して通信モデム9で読み取られる。
【0024】
コンピュータ1は、磁気ディスク装置3、CD−ROM装置7または通信モデム9を解して読み取られたプログラムを実行するためのCPU(CentralProcessing Unit)10と、コンピュータ1の動作に必要なその他のプログラムおよびデータを記憶するためのROM(Read Only Memory)11と、プログラム、プログラム実行時のパラメータ、演算結果などを記憶するためのRAM(Random Access Memory)12と、プログラム、文書データなどを記憶するための磁気ディスク13とを含む。
【0025】
図2を参照して、本発明の文書検索方法について説明する。
【0026】
まず最初に、オペレータによって検索をするための検索条件がキーボード5から入力される。入力された検索条件を、RAM12の中に確保した入力文字列バッファ21に格納する(ステップS1)。文書中に装飾が付加された検索対象となる文書を、RAM12の中に確保した検索文書バッファ22に格納する(ステップS2)。文書から検索条件にしたがって検索する(ステップS3)。検索結果をディスプレイ2に表示する(ステップS4)。
【0027】
ステップS1の処理は、キーボード5以外であってもよい。マウス6を操作して文字列を入力してもよいし、あらかじめ入力された文字列が格納された磁気ディスク13などから読み込むようにしてもよい。ステップS1とステップS2は順序が逆であってもよい。
【0028】
ステップS4では、ディスプレイ2に検索結果を表示しているが、ディスプレイ2は、CRT(Cathode Ray Tube)ディスプレイやLCD(Liquid Crystal Display)などであってもよい。また、ディスプレイ2の代わりにプリンタなどの出力装置や、FAXなどの通信装置に検索結果を出力するようにしてもよい。さらに、磁気ディスク13、FD、光磁気ディスクなどに検索結果を書き込むようにしてもよい。
【0029】
図3を参照して、図2のステップS2の処理について説明する。図3は検索文書バッファ22のデータ構造を説明する図である。検索文書バッファ22は文字格納領域23と装飾フラグ格納領域24からなる。文字格納領域23には、検索対象となる装飾を含む文書の文字列が順に格納される。装飾フラグ格納領域24には文書の文字がそれぞれルビであるか、ルビが振られた文字(これをルビ基底文字と呼ぶことにする)であるか、どちらでもないかを識別するフラグが格納される。例えば検索対象となる文書中に図9(a)に示すような文字列が含まれていたとすると、検索文書バッファ22には図3(a)に示すデータ構造のように格納される。ここで装飾フラグ格納領域24に格納される装飾フラグの種類は、ルビを2、ルビ基底文字を1、どちらでもない文字を0としている。同様に、検索対象となる文書中に図10(a)に示すような文字列が含まれていたとすると、検索文書バッファ22には図3(b)のように格納される。この処理は、検索対象となる文書全体に対して行われる。ここで用いられる装飾フラグの種類は図3(a)と同じである。
【0030】
ルビ以外の装飾の場合は、1つの文字に複数の装飾が付くこともあるので、フラグは2の累乗にしてその和を格納するとよい。例えば12が格納されていれば4+8で下線と太字の装飾が付いていると判別できる。すなわち、装飾基底文字を1、下線を4、太字を8、斜字を16、色を32、フォントを64、フォントサイズを128、装飾文字でもなく装飾でもない文字を0のようにし、複数の装飾を持つ場合はその和を格納するとよい。
【0031】
図4を参照して、図2のステップS3の処理について説明する。
【0032】
まず、入力文字列バッファ21と検索文書バッファ22の文字を1文字ずつ比較していく。本実施の形態では検索文書バッファ22の検索開始位置をディスプレイ2に表示されている部分の先頭位置とするが、文書の先頭でもよいし、ユーザが決定してもよい。そして、比較対象文字を入力文字列バッファ21は1番目の文字、検索文書バッファ22は検索開始位置にする(ステップS31)。
【0033】
次に、入力文字列バッファ21の文字と検索文書バッファ22の文字を比較する(ステップS32)。文字が同一でなければ検索文書バッファ22の検索開始位置を1文字ずらし(ステップS33)、ステップS31から再度処理を行う。
【0034】
文字が同一であれば、入力文字列バッファ21の比較対象文字が1番目であるか調べる(ステップS34)。1番目であれば、ステップS32で比較した検索文書バッファ22の比較対象文字に対応する装飾フラグ(これを現装飾フラグと呼ぶことにする)をRAM12の内部に確保された装飾フラグ保存バッファ25に保存し、入力文字列バッファ21と検索文書バッファ22の比較対象文字をそれぞれ1文字ずらす(ステップS35)。
【0035】
1番目でなければ、現装飾フラグと装飾フラグ保存バッファ25に保存されている装飾フラグ(これを前装飾フラグと呼ぶことにする)を調べる(ステップS36)。現装飾フラグがルビで前装飾フラグがルビ基底文字であるか、現装飾フラグがルビ基底文字で前装飾フラグがルビであれば、検索文書バッファ22のスキップ対象となり、検索文書バッファ22の比較対象文字を1文字ずらし(ステップS37)、ステップS32の処理を行う。
【0036】
現装飾フラグと前装飾フラグの組み合わせがそれ以外であれば、ステップS35の処理を行う。ステップS35の処理が終了した時点で入力文字列バッファ21の比較対象文字が存在するか否か調べ(ステップS38)、存在しなければ入力文字列が検索文書中にあったことを示すため、検索を終了する(ステップS39)。
【0037】
入力文字列バッファ21の比較対象文字がまだ存在すれば、検索文書バッファ22の比較対象文字が存在するか否か調べ(ステップS391)、存在しなければ入力文字列が検索文書中になかったことを示すため、検索を終了する(ステップS392)。
【0038】
検索文書バッファ22の比較対象文字がまだ存在すればステップS32の処理を行う。以上の処理を、検索が終了するまで繰り返す。
【0039】
図5を参照して、ステップS4の処理について説明する。図5は、文書検索装置のディスプレイ2に文書を表示させた例である。この文書検索装置は、ルビの表示の有無をユーザが設定でき、現在はルビを表示しないよう設定されている。そのため、この文書には「解決」という文字列に「かいけつ」というルビが振られているが、ルビは表示されていない。ここで、図2に示した検索処理を実行し、ステップS1で「をかいけつする」という文字を検索すると、ステップS3で「解決」に振られたルビも含めて検出され、図6に示すように、検出されたルビを表示して、検出された文字列を反転する。図6(a)のようにルビ基底文字の上にルビを表示してもよいし、図6(b)のようにルビ基底文字の後に括弧書きでルビを表示してもよい。
【0040】
また、検索結果は図7のように、ルビ基底文字とルビを入れ替えて表示してもよい。図7(a)ではルビの上にルビ基底文字を表示している。図7(b)ではルビの後に括弧書きでルビ基底文字を表示している。
【0041】
また、検索結果の強調表示は反転に限らず、他の強調手法でもよい。例えば文字色を変えてもよいし、下線を引いてもよいし、太字にしてもよいし、斜体にしてもよいし、フォントを変えてもよいし、フォントサイズを変えてもよい。
【0042】
以上の説明において、ルビの検索を例示的に示したが、本発明はルビだけでなく、文書に付される下線、太字、斜体、色、フォント、フォントサイズ等の装飾に適用可能である。
【0043】
ここに開示した実施の形態は全ての点で例示であって制限的なものではないと考えるべきである。本発明の範囲は上記した説明ではなく特許請求の範囲によって示され、特許請求の範囲と均等の意味および範囲内でのすべての変更が含まれることが意図される。
【0044】
【発明の効果】
本発明の文書検索方法、文書検索装置、文書検索プログラム、および、そのプログラムを記録した記録媒体によれば、検索した際にルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾付文字列の前後の文字を含めた文字列を見つけることが可能である。さらに、その文字列の中でルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾が付加された文字をルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾に置き換えて入力し、検索しても見つけることが可能である。さらに、熟語のルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾が複数に分けて振られていても、検索した際に1つのルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾と同様に見つけることが可能である。
【0045】
また、ルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾が表示されていない状態で検索し、検索結果にルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾が含まれていた際にも、ルビ、下線、太字、斜字、色、フォント、フォントサイズ等の装飾が見つかったことをユーザが容易に認識することが可能である。
【図面の簡単な説明】
【図1】本発明の文書検索装置のハードウェア構成図である。
【図2】本発明の文書検索方法のフローチャートである。
【図3】本発明の検索文書バッファの構造を説明する図である。
【図4】図2のステップS3の詳細フローチャートである。
【図5】本発明の文書検索装置に文書を表示させた画面の一例を示す図である。
【図6】本発明の実施の形態による、検索結果にルビが含まれるときの画面の一例を示す図である。
【図7】本発明の実施の形態による、検索結果にルビが含まれるときの画面の一例を示す図である。
【図8】ルビの一般的な表示形態の一例である。
【図9】マークアップ言語を使用してルビを文書中に格納する形態の一例である。
【図10】マークアップ言語を使用してルビを文書中に格納する形態の一例である。
【図11】検索結果の一般的な表示形態の一例である。
【図12】ルビを表示していない状態で、検索結果がルビであるときの一般的な表示形態の一例である。
【符号の説明】
1 コンピュータ
2 ディスプレイ
9 通信モデム
10 CPU
11 ROM
12 RAM
13 磁気ディスク
21 入力文字列バッファ
22 検索文書バッファ
23 文字格納領域
24 装飾フラグ格納領域
25 装飾フラグ保存バッファ
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a document search method, a document search apparatus, a document search program, and a document search method capable of searching for a document including characters with decorations such as ruby, underline, bold, italic, color, font, and font size. The invention relates to a recording medium on which the program is recorded.
[0002]
[Prior art]
The document has decorations such as ruby, underline, bold, italic, color, font and font size. Ruby is a reading pseudonym added to characters that are difficult to read or easy to read. The underline, bold, italic, color, font, and font size are added to emphasize the character, to display a caution area, or to distinguish it from other characters. The display form of ruby is shown in FIG. In FIG. 8A, a small reading kana is added to the upper part of the character. In FIG. 8B, the characters are added in parentheses after the characters. Some document display devices can select whether or not to display ruby according to the user's preference. In that case, ruby is displayed only when it is selected to display ruby. It is possible to select whether or not decorations such as underline, bold, italic, color, font, and font size are displayed according to the user's preference.
[0003]
In addition, as a form of a data structure for storing ruby in a document, there are a method of adding characters in parentheses after a character, and a method of using a markup language such as HTML (Hyper Text Markup Language) or XML (extensible Markup Language). is there. In the method of adding characters in parentheses after characters, ruby is stored in the same manner as in the display form of FIG. An example of a method using a markup language is shown in FIG. A character string with ruby is surrounded by character strings <ruby> and </ ruby>, and a character string to be further ruby is written between character strings <rb> and </ rb>, and ruby is <rt > And </ rt>.
[0004]
For decorations other than ruby, HTML has the following data structure. Both are used in the form of sandwiching the character you want to decorate.
Underline: <u></u>
Bold: <b></b>
Italic: <i></i>
Color: <font color = "# ff0000"></font>
Font: <font face = "MS Gothic"></font>
Font size: <font size = "7"></font>
* <Font> can specify color, font and size at the same time.
Example: <font color = "# ff0000" face = "MS Gothic" size = "7"> Decorated characters </ font>
Generally, a document creation device and a document display device have a character string search function. This is a function that, when a user designates a certain character string and executes a search function, returns whether or not the designated character string exists in the document. Thus, the user can search for a desired character string from the document. Search is possible even for documents containing ruby. For example, when the character string shown in FIG. 9A exists in the sentence, parentheses and character strings indicating ruby are deleted as shown in FIG. 9B. A method for performing a search on a state is common. A general display form of the search result is shown in FIG. FIG. 11 shows an example of a search result using a character string “Kaietsu”. A method of inverting ruby as shown in FIG. 11A, or a character string with ruby as shown in FIG. 11B. There are a method of inverting and a method of inverting both ruby and a character string with ruby. Searches can be performed for underline, bold, italic, color, font and font size as well as ruby.
[0005]
Japanese Patent Laid-Open No. 5-257939 proposes the following method. The reading kana entered by the kana-kanji conversion method is stored as a document together with the kanji words or idioms converted at the time of kana-kanji conversion, and the reading kana entered when the document is reused is used as a search key. For example, after the operator inputs “Bunsho” from the input means, it is converted to “Document” by Kana-Kanji conversion, and when it is determined, the determined word (document) and the reading Kana (Bunsho) are both stored in the storage means. To do. It is also possible to input the reading pseudonym again and correct it, for example, “Bunsho”. After determining both the converted word and the reading kana, both are stored as documents in the storage means. If this document is searched with “Bunsho” as a reading pseudonym, the word “document” can be obtained as a search result.
[0006]
[Problems to be solved by the invention]
However, the above method has the following problems.
[0007]
When a document including the character string shown in FIG. 9A is searched with “Kaikeitsu”, the character string shown in FIG. 9A can be found. However, since the character string shown in FIG. 9A can be searched for the state shown in FIG. 9B at the time of the search, a character string with ruby such as “solve the problem” or “skill the problem”. Cannot be found by searching with a character string including the characters before and after
[0008]
In addition, as shown in FIG. 10A, ruby may be attached to each of “solution” and “decision” for the idiom “solution”. In this case, since the search is performed on the state of FIG. 10B at the time of the search, it cannot be found even if the search is made with “Kaikeitsu” or “Solution”.
[0009]
The method proposed in JP-A-5-257939 has the same problem. For example, if there is a character string “Means to solve an issue” in the document and a reading name “Kaikets” is registered in the string “Solution”, find it when searching with “Solution” “Kaikets”. However, there is no mention of the results when searching with a character string including the characters before and after the character string with the reading kana such as “solve the problem” and “kick the problem”. Also, when Kana-Kanji conversion is performed, Kana-Kana is stored as a document along with Kanji words, and the Kana-Kana entered when the document is reused is used as a search key. Are registered with the readings of “Kai” and “Ass”. For this reason, it is not possible to search with the reading “Kaikets”.
[0010]
Further, the method of displaying the search result as shown in FIG. 11 has the following problems.
Some document display devices can select whether or not to display ruby according to the user's preference. In that case, ruby is displayed only when it is selected to display ruby. When the search result is displayed as shown in FIG. 11, the search result is well understood when the ruby is displayed, but when the ruby is not displayed, it is difficult to understand what was found, and the user may be confused. . For example, when searching for the sentence in FIG. 9A with “Ike”, a part of the ruby “Kaiketsu” corresponds, and the search result is displayed on the document display device as shown in FIG. In FIG. 12 (a), it is not known at all where it corresponds, and even in FIG. 12 (b), it is difficult to know where it corresponds unless the reading of “Solution” is known.
[0011]
The present invention has been made in view of the above problems, and can search for documents including characters with decorations such as ruby, underline, bold, italic, color, font, font size, etc. The present invention provides a document search method, a document search apparatus, a document search program, and a recording medium on which the program is recorded, which can be easily informed to the user.
[0012]
[Means for Solving the Problems]
In order to achieve the above object, according to one aspect of the present invention, a document search method includes a step in which a storage unit of a computer stores a document in which ruby is added to characters in the document;
The document, and the character storage area character of the document containing the ruby is stored sequentially, or letter of the document is ruby, or a base character ruby is swung, identify whether nor the base character in ruby The computer conversion means converts the data structure to a ruby flag storage area in which a flag to be stored is stored;
Storing a search condition for searching for the character or ruby with the ruby added, and a storage means of a computer;
A search unit of a computer searching for the document converted into the data structure according to the search condition;
Displaying the search result on the display means of the computer,
The converting step includes:
Upon storing the characters in the character storage area, place a ruby of the base character immediately or immediately before the base character,
And a flag to be stored with the characters stored in the character storage area in the Rubifuragu storage area, and store associate with each other,
The searching step includes
Determining a character position in the document to be compared with the search condition;
Comparing the character of the search condition with the character in the document;
If the character in the document that matches as a result of the previous comparison is ruby and the character in the document that matches as a result of the comparison in this time is attached with ruby, and the character in the document that matches as a result of the previous comparison And when the character in the document that matches as a result of the comparison this time is ruby, the search condition character position remains unchanged, and only the character position to be compared in the document is shifted. Features.
[0014]
Preferably, in the document search method according to claim 1, in the step of displaying the search result, the ruby is displayed when the ruby is not displayed before the search and the search result includes the ruby. And a step of highlighting .
[0015]
Preferably, in the document search method according to claim 1, in the step of displaying the search result, ruby is added when ruby is not displayed before the search and the search result includes ruby. The method includes a step of replacing a character being displayed with ruby and highlighting the ruby .
[0016]
According to yet another aspect of the present invention, a document retrieval system, a document storage means for memorize a document ruby is added to the character in the document,
The document, and the character storage area character of the document containing the ruby is stored sequentially, or letter of the document is ruby, or a base character ruby is swung, identify whether nor the base character in ruby conversion means for flag is converted into a data structure composed of a Rubifuragu storage area to be stored to,
A search character storage means for memorize a search condition for searching the character or ruby the ruby is added,
The document has been converted into the data structures and search means for search according to the search condition,
Results include a table Shimesuru display means,
The converting means includes
Upon storing the characters in the character storage area, place a ruby of the base character immediately or immediately before the base character,
And a flag to be stored with the characters stored in the character storage area in the Rubifuragu storage area, and store associate with each other,
The search means includes
Comparison character position determining means for determining a character position in the document to be compared with the search condition;
A comparison means for comparing the character of the search condition with the character in the document;
If the character in the document that matches as a result of the previous comparison is ruby and the character in the document that matches as a result of the comparison in this time is attached with ruby, and the character in the document that matches as a result of the previous comparison And a comparison character position advancing means for shifting only the character position to be compared in the document without changing the search condition character position when the character in the document that matches as a result of the current comparison is ruby. It is characterized by including.
[0018]
According to still another aspect of the present invention, the document search program stores the document in which the ruby is added to the characters in the document in the storage unit of the computer,
The document, and the character storage area character of the document containing the ruby is stored sequentially, or letter of the document is ruby, or a base character ruby is swung, identify whether nor the base character in ruby The computer conversion means converts the data structure to a ruby flag storage area in which a flag to be stored is stored;
Storing a search condition for searching for the character or ruby with the ruby added, and a storage means of a computer;
A search unit of a computer searching for the document converted into the data structure according to the search condition;
A document search program for causing a computer to execute a step of displaying a search result by a display means of the computer,
The converting step includes:
Upon storing the characters in the character storage area, place a ruby of the base character immediately or immediately before the base character,
And a flag to be stored with the characters stored in the character storage area in the Rubifuragu storage area, and store associate with each other,
The searching step includes
Determining a character position in the document to be compared with the search condition;
Comparing the character of the search condition with the character in the document;
If the character in the document that matches as a result of the previous comparison is ruby and the character in the document that matches as a result of the comparison in this time is attached with ruby, and the character in the document that matches as a result of the previous comparison And when the character in the document that matches as a result of the comparison this time is ruby, the search condition character position remains unchanged, and only the character position to be compared in the document is shifted. Features.
[0020]
According to still another aspect of the present invention, a computer-readable recording medium records the document search program according to claim 5 .
[0021]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, an example of an embodiment of the present invention will be described using a specific example.
[0022]
As shown in FIG. 1, the document search apparatus according to the embodiment of the present invention includes a computer 1, a keyboard 5 and a mouse 6 for giving instructions to the computer 1, a display 2 for displaying various information, A magnetic disk device 3 for reading a program executed on the computer 1 and a document to be searched, a CD-ROM (Read Only Memory) device 7 and a communication modem 9 are included. Connected to.
[0023]
A program for searching a document and a document to be searched are recorded on a magnetic disk 4 or a CD-ROM 8 that is a recording medium readable by the computer 1, and read by the magnetic disk device 3 or the CD-ROM device 7, respectively. . Alternatively, the data is read by the communication modem 9 via the communication line.
[0024]
The computer 1 includes a CPU (Central Processing Unit) 10 for executing a program read through the magnetic disk device 3, the CD-ROM device 7, or the communication modem 9, and other programs necessary for the operation of the computer 1. ROM (Read Only Memory) 11 for storing data, RAM (Random Access Memory) 12 for storing programs, parameters at the time of program execution, calculation results, etc., and programs, document data, etc. A magnetic disk 13.
[0025]
The document search method of the present invention will be described with reference to FIG.
[0026]
First, a search condition for searching by an operator is input from the keyboard 5. The input search condition is stored in the input character string buffer 21 secured in the RAM 12 (step S1). A document to be searched with decorations added to the document is stored in the search document buffer 22 secured in the RAM 12 (step S2). The document is searched according to the search condition (step S3). The search result is displayed on the display 2 (step S4).
[0027]
The process of step S1 may be other than the keyboard 5. A character string may be input by operating the mouse 6, or may be read from a magnetic disk 13 or the like in which a character string input in advance is stored. Step S1 and step S2 may be reversed in order.
[0028]
In step S4, the search result is displayed on the display 2, but the display 2 may be a CRT (Cathode Ray Tube) display, LCD (Liquid Crystal Display), or the like. Further, instead of the display 2, the search result may be output to an output device such as a printer or a communication device such as FAX. Further, the search result may be written to the magnetic disk 13, FD, magneto-optical disk or the like.
[0029]
With reference to FIG. 3, the process of step S2 of FIG. 2 will be described. FIG. 3 is a diagram for explaining the data structure of the search document buffer 22. The search document buffer 22 includes a character storage area 23 and a decoration flag storage area 24. In the character storage area 23, character strings of documents including decorations to be searched are sequentially stored. The decoration flag storage area 24 stores a flag for identifying whether each character of the document is ruby or a character with a ruby character (hereinafter referred to as a ruby base character) or neither. The For example, if a character string as shown in FIG. 9A is included in a document to be searched, the search document buffer 22 stores the data structure as shown in FIG. Here, the types of decoration flags stored in the decoration flag storage area 24 are 2 for ruby, 1 for ruby base characters, and 0 for non-native characters. Similarly, if a character string as shown in FIG. 10A is included in a document to be searched, it is stored in the search document buffer 22 as shown in FIG. This process is performed on the entire document to be searched. The types of decoration flags used here are the same as those in FIG.
[0030]
For decorations other than ruby, a single character may have multiple decorations, so the flag should be a power of 2 and the sum stored. For example, if 12 is stored, it can be determined that 4 + 8 has underlined and bold decorations. In other words, the decorative base character is 1, the underline is 4, the bold is 8, the italic is 16, the color is 32, the font is 64, the font size is 128, and the character that is neither a decorative character nor an ornament is 0. If you have decorations, store the sum.
[0031]
With reference to FIG. 4, the process of step S3 of FIG. 2 will be described.
[0032]
First, the characters in the input character string buffer 21 and the search document buffer 22 are compared one by one. In the present embodiment, the search start position of the search document buffer 22 is set as the start position of the portion displayed on the display 2, but it may be the start position of the document or may be determined by the user. Then, the input character string buffer 21 is set to the first character and the search document buffer 22 is set to the search start position (step S31).
[0033]
Next, the characters in the input character string buffer 21 and the characters in the search document buffer 22 are compared (step S32). If the characters are not the same, the search start position in the search document buffer 22 is shifted by one character (step S33), and the process is performed again from step S31.
[0034]
If the characters are the same, it is checked whether the comparison target character in the input character string buffer 21 is the first (step S34). If it is the first, the decoration flag corresponding to the character to be compared in the search document buffer 22 compared in step S32 (hereinafter referred to as the current decoration flag) is stored in the decoration flag storage buffer 25 secured in the RAM 12. Then, the comparison target characters in the input character string buffer 21 and the search document buffer 22 are shifted by one character respectively (step S35).
[0035]
If not the first, the current decoration flag and the decoration flag stored in the decoration flag storage buffer 25 (hereinafter referred to as the previous decoration flag) are examined (step S36). If the current decoration flag is ruby and the previous decoration flag is a ruby base character, or if the current decoration flag is a ruby base character and the front decoration flag is ruby, the search document buffer 22 is skipped and the search document buffer 22 is compared. The character is shifted by one character (step S37), and the process of step S32 is performed.
[0036]
If the combination of the current decoration flag and the previous decoration flag is other than that, the process of step S35 is performed. When the process of step S35 is completed, it is checked whether or not there is a character to be compared in the input character string buffer 21 (step S38). If it does not exist, a search is performed to indicate that the input character string was in the search document. Is finished (step S39).
[0037]
If there is still a comparison target character in the input character string buffer 21, it is checked whether or not there is a comparison target character in the search document buffer 22 (step S391). If there is no comparison target character, the input character string was not in the search document. The search is terminated (step S392).
[0038]
If there are still characters to be compared in the search document buffer 22, the process of step S32 is performed. The above processing is repeated until the search is completed.
[0039]
With reference to FIG. 5, the process of step S4 will be described. FIG. 5 shows an example in which a document is displayed on the display 2 of the document search apparatus. This document retrieval apparatus is set so that the user can set whether or not to display ruby and currently does not display ruby. Therefore, in this document, the ruby “Kaikeitsu” is given to the character string “Solution”, but the ruby is not displayed. Here, when the search process shown in FIG. 2 is executed and the character “defeats” is searched in step S1, it is detected including the ruby assigned to “solution” in step S3, and is shown in FIG. Thus, the detected ruby is displayed and the detected character string is inverted. Ruby may be displayed on the ruby base character as shown in FIG. 6A, or ruby may be displayed in parentheses after the ruby base character as shown in FIG. 6B.
[0040]
Further, as shown in FIG. 7, the search result may be displayed by replacing ruby base characters and ruby. In FIG. 7A, ruby base characters are displayed on the ruby. In FIG. 7B, ruby base characters are displayed in parentheses after ruby.
[0041]
Further, the highlighted display of search results is not limited to inversion, and other highlighting methods may be used. For example, the character color may be changed, the underline may be underlined, bolded, italicized, the font may be changed, or the font size may be changed.
[0042]
In the above description, the ruby search is shown as an example. However, the present invention is applicable not only to ruby but also to decorations such as underline, bold, italic, color, font, font size, etc. attached to a document.
[0043]
It should be considered that the embodiments disclosed herein are illustrative and non-restrictive in every respect. The scope of the present invention is defined by the terms of the claims, rather than the description above, and is intended to include any modifications within the scope and meaning equivalent to the terms of the claims.
[0044]
【The invention's effect】
According to the document search method, document search apparatus, document search program, and recording medium on which the program is recorded according to the present invention, decoration such as ruby, underline, bold, italic, color, font, font size, and the like when searched It is possible to find a character string including characters before and after the attached character string. In addition, characters with decorations such as ruby, underline, bold, italic, color, font, font size, etc. in the character string are decorated with ruby, underline, bold, italic, color, font, font size, etc. You can also find it by searching for In addition, even if the idiom ruby, underline, bold, italic, color, font, font size, etc. are decorated in multiple parts, one ruby, underline, bold, italic, color, It can be found as well as decorations such as font and font size.
[0045]
Also, search without decoration such as ruby, underline, bold, italic, color, font, font size, etc., and search results such as ruby, underline, bold, italic, color, font, font size, etc. Even when the decoration is included, the user can easily recognize that the decoration such as ruby, underline, bold, italic, color, font, and font size is found.
[Brief description of the drawings]
FIG. 1 is a hardware configuration diagram of a document search apparatus according to the present invention.
FIG. 2 is a flowchart of a document search method according to the present invention.
FIG. 3 is a diagram illustrating the structure of a search document buffer according to the present invention.
FIG. 4 is a detailed flowchart of step S3 in FIG.
FIG. 5 is a diagram showing an example of a screen on which a document is displayed on the document search device of the present invention.
FIG. 6 is a diagram showing an example of a screen when ruby is included in a search result according to the embodiment of the present invention.
FIG. 7 is a diagram showing an example of a screen when ruby is included in a search result according to the embodiment of the present invention.
FIG. 8 is an example of a general display form of ruby.
FIG. 9 is an example of a mode in which ruby is stored in a document using a markup language.
FIG. 10 is an example of a mode in which ruby is stored in a document using a markup language.
FIG. 11 is an example of a general display form of a search result.
FIG. 12 is an example of a general display form when a search result is ruby in a state where ruby is not displayed.
[Explanation of symbols]
1 Computer 2 Display 9 Communication Modem 10 CPU
11 ROM
12 RAM
13 Magnetic disk 21 Input character string buffer 22 Search document buffer 23 Character storage area 24 Decoration flag storage area 25 Decoration flag storage buffer

Claims (6)

文書中の文字にルビが付加された文書をコンピュータの記憶手段が記憶するステップと、
前記文書を、ルビを含む文書の文字が順に格納される文字格納領域と、文書の文字がルビであるか、ルビが振られる基底文字であるか、ルビでも前記基底文字でもないかを識別するフラグが格納されるルビフラグ格納領域とからなるデータ構造にコンピュータの変換手段が変換するステップと、
前記ルビが付加された文字あるいはルビを検索するための検索条件をコンピュータの記憶手段が記憶するステップと、
前記検索条件にしたがって前記データ構造に変換された前記文書をコンピュータの検索手段が検索するステップと、
検索結果をコンピュータの表示手段が表示するステップと、を含み、
前記変換するステップは、
前記文字格納領域に文字を格納するに際し、前記基底文字の直後または直前に当該基底文字のルビを配置し、
前記文字格納領域に格納される文字と前記ルビフラグ格納領域に格納されるフラグとを、互いに関連つけて格納し、
前記検索するステップは、
前記検索条件と比較する前記文書内の文字位置を決定するステップと、
前記検索条件の文字と前記文書内の文字をおのおの比較するステップと、
前回比較した結果一致する前記文書内の文字がルビでありかつ今回比較した結果一致する前記文書内の文字にルビが付されている場合および、前回比較した結果一致する前記文書内の文字にルビが付されていてかつ今回比較した結果一致する前記文書内の文字がルビである場合に、前記検索条件文字位置はそのままで、前記文書内の比較する文字位置のみをずらすステップとを含むことを特徴とする、文書検索方法。
A step in which a storage means of a computer stores a document in which ruby is added to characters in the document;
The document, and the character storage area character of the document containing the ruby is stored sequentially, or letter of the document is ruby, or a base character ruby is swung, identify whether nor the base character in ruby The computer conversion means converts the data structure to a ruby flag storage area in which a flag to be stored is stored;
Storing a search condition for searching for the character or ruby with the ruby added, and a storage means of a computer;
A search unit of a computer searching for the document converted into the data structure according to the search condition;
Displaying the search result on the display means of the computer,
The converting step includes:
Upon storing the characters in the character storage area, place a ruby of the base character immediately or immediately before the base character,
And a flag to be stored with the characters stored in the character storage area in the Rubifuragu storage area, and store associate with each other,
The searching step includes
Determining a character position in the document to be compared with the search condition;
Comparing the character of the search condition with the character in the document;
If the character in the document that matches as a result of the previous comparison is ruby and the character in the document that matches as a result of the comparison in this time is attached with ruby, and the character in the document that matches as a result of the previous comparison And when the character in the document that matches as a result of the comparison this time is ruby, the search condition character position remains unchanged, and only the character position to be compared in the document is shifted. Characteristic document search method.
前記検索結果を表示するステップは、検索前にルビを表示しておらず、かつ検索結果にルビが含まれているときに、ルビを表示し、強調表示するステップを含むことを特徴とする、請求項1に記載の文書検索方法。  The step of displaying the search result includes a step of displaying and highlighting ruby when ruby is not displayed before the search and ruby is included in the search result, The document search method according to claim 1. 前記検索結果を表示するステップは、検索前にルビを表示しておらず、かつ検索結果にルビが含まれているときに、ルビが付加されている文字をルビで置換し、ルビを強調表示するステップを含むことを特徴とする、請求項1に記載の文書検索方法。  In the step of displaying the search result, when the ruby is not displayed before the search and the ruby is included in the search result, the character to which the ruby is added is replaced with the ruby and the ruby is highlighted. The document search method according to claim 1, further comprising a step of: 文書中の文字にルビが付加された文書を記憶する文書記憶手段と、
前記文書を、ルビを含む文書の文字が順に格納される文字格納領域と、文書の文字がルビであるか、ルビが振られる基底文字であるか、ルビでも前記基底文字でもないかを識別するフラグが格納されるルビフラグ格納領域とからなるデータ構造に変換する変換手段と、
前記ルビが付加された文字あるいはルビを検索するための検索条件を記憶する検索文字記憶手段と、
前記検索条件にしたがって前記データ構造に変換された前記文書を検索する検索手段と、
検索結果を表示する表示手段と、を含み、
前記変換手段は、
前記文字格納領域に文字を格納するに際し、前記基底文字の直後または直前に当該基底文字のルビを配置し、
前記文字格納領域に格納される文字と前記ルビフラグ格納領域に格納されるフラグとを、互いに関連つけて格納し、
前記検索手段は、
前記検索条件と比較する前記文書内の文字位置を決定する比較文字位置決定手段と、
前記検索条件の文字と前記文書内の文字をおのおの比較する比較手段と、
前回比較した結果一致する前記文書内の文字がルビでありかつ今回比較した結果一致する前記文書内の文字にルビが付されている場合および、前回比較した結果一致する前記文書内の文字にルビが付されていてかつ今回比較した結果一致する前記文書内の文字がルビである場合に、前記検索条件文字位置はそのままで、前記文書内の比較する文字位置のみをずらす比較文字位置前進手段とを含むことを特徴とする、文書検索装置。
A document storage means for memorize a document ruby is added to the character in the document,
The document, and the character storage area character of the document containing the ruby is stored sequentially, or letter of the document is ruby, or a base character ruby is swung, identify whether nor the base character in ruby conversion means for flag is converted into a data structure composed of a Rubifuragu storage area to be stored to,
A search character storage means for memorize a search condition for searching the character or ruby the ruby is added,
The document has been converted into the data structures and search means for search according to the search condition,
Results include a table Shimesuru display means,
The converting means includes
Upon storing the characters in the character storage area, place a ruby of the base character immediately or immediately before the base character,
And a flag to be stored with the characters stored in the character storage area in the Rubifuragu storage area, and store associate with each other,
The search means includes
Comparison character position determining means for determining a character position in the document to be compared with the search condition;
A comparison means for comparing the character of the search condition with the character in the document;
If the character in the document that matches as a result of the previous comparison is ruby and the character in the document that matches as a result of the comparison in this time is attached with ruby, and the character in the document that matches as a result of the previous comparison And a comparison character position advancing means for shifting only the character position to be compared in the document without changing the search condition character position when the character in the document that matches as a result of the current comparison is ruby. A document retrieval apparatus comprising:
文書中の文字にルビが付加された文書をコンピュータの記憶手段が記憶するステップと、
前記文書を、ルビを含む文書の文字が順に格納される文字格納領域と、文書の文字がルビであるか、ルビが振られる基底文字であるか、ルビでも前記基底文字でもないかを識別するフラグが格納されるルビフラグ格納領域とからなるデータ構造にコンピュータの変換手段が変換するステップと、
前記ルビが付加された文字あるいはルビを検索するための検索条件をコンピュータの記憶手段が記憶するステップと、
前記検索条件にしたがって前記データ構造に変換された前記文書をコンピュータの検索手段が検索するステップと、
検索結果をコンピュータの表示手段が表示するステップと、をコンピュータに実行させる文書検索プログラムであって、
前記変換するステップは、
前記文字格納領域に文字を格納するに際し、前記基底文字の直後または直前に当該基底文字のルビを配置し、
前記文字格納領域に格納される文字と前記ルビフラグ格納領域に格納されるフラグとを、互いに関連つけて格納し、
前記検索するステップは、
前記検索条件と比較する前記文書内の文字位置を決定するステップと、
前記検索条件の文字と前記文書内の文字をおのおの比較するステップと、
前回比較した結果一致する前記文書内の文字がルビでありかつ今回比較した結果一致する前記文書内の文字にルビが付されている場合および、前回比較した結果一致する前記文書内の文字にルビが付されていてかつ今回比較した結果一致する前記文書内の文字がルビである場合に、前記検索条件文字位置はそのままで、前記文書内の比較する文字位置のみをずらすステップとを含むことを特徴とする、文書検索プログラム。
A step in which a storage means of a computer stores a document in which ruby is added to characters in the document;
The document, and the character storage area character of the document containing the ruby is stored sequentially, or letter of the document is ruby, or a base character ruby is swung, identify whether nor the base character in ruby The computer conversion means converts the data structure to a ruby flag storage area in which a flag to be stored is stored;
Storing a search condition for searching for the character or ruby with the ruby added, and a storage means of a computer;
A search unit of a computer searching for the document converted into the data structure according to the search condition;
A document search program for causing a computer to execute a step of displaying a search result by a display means of the computer,
The converting step includes:
Upon storing the characters in the character storage area, place a ruby of the base character immediately or immediately before the base character,
And a flag to be stored with the characters stored in the character storage area in the Rubifuragu storage area, and store associate with each other,
The searching step includes
Determining a character position in the document to be compared with the search condition;
Comparing the character of the search condition with the character in the document;
If the character in the document that matches as a result of the previous comparison is ruby and the character in the document that matches as a result of the comparison in this time is attached with ruby, and the character in the document that matches as a result of the previous comparison And when the character in the document that matches as a result of the comparison this time is ruby, the search condition character position remains unchanged, and only the character position to be compared in the document is shifted. Characteristic document search program.
請求項に記載の文書検索プログラムを記録した、コンピュータ読み取り可能な記録媒体。A computer-readable recording medium on which the document search program according to claim 5 is recorded.
JP2002136686A 2002-05-13 2002-05-13 DOCUMENT SEARCH METHOD, DOCUMENT SEARCH DEVICE, DOCUMENT SEARCH PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM Expired - Lifetime JP3933517B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002136686A JP3933517B2 (en) 2002-05-13 2002-05-13 DOCUMENT SEARCH METHOD, DOCUMENT SEARCH DEVICE, DOCUMENT SEARCH PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002136686A JP3933517B2 (en) 2002-05-13 2002-05-13 DOCUMENT SEARCH METHOD, DOCUMENT SEARCH DEVICE, DOCUMENT SEARCH PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM

Publications (2)

Publication Number Publication Date
JP2003330917A JP2003330917A (en) 2003-11-21
JP3933517B2 true JP3933517B2 (en) 2007-06-20

Family

ID=29698644

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002136686A Expired - Lifetime JP3933517B2 (en) 2002-05-13 2002-05-13 DOCUMENT SEARCH METHOD, DOCUMENT SEARCH DEVICE, DOCUMENT SEARCH PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM

Country Status (1)

Country Link
JP (1) JP3933517B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5187013B2 (en) * 2007-07-27 2013-04-24 セイコーエプソン株式会社 File search system, file search device, and file search method
JP5782841B2 (en) * 2011-05-31 2015-09-24 カシオ計算機株式会社 Chinese sentence display device and program
JP6028392B2 (en) * 2012-05-24 2016-11-16 富士通株式会社 Generation program, generation method, generation device, search program, search method, and search device
JP6028393B2 (en) * 2012-05-24 2016-11-16 富士通株式会社 Collation program, collation method and collation device

Also Published As

Publication number Publication date
JP2003330917A (en) 2003-11-21

Similar Documents

Publication Publication Date Title
JPS619753A (en) Automatic registering method of frequent phrase for document processor
JP3143345B2 (en) String search device
JP3933517B2 (en) DOCUMENT SEARCH METHOD, DOCUMENT SEARCH DEVICE, DOCUMENT SEARCH PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM
JPH08287088A (en) Method and device for information retrieval
JP2785692B2 (en) Dictionary search and display device
JP5400688B2 (en) Proposed specification creation support method, program, and proposed specification creation support device
JPH10301933A (en) Document processor, its method and recording medium
JPH10207875A (en) Tabulating device and its method
JP3537260B2 (en) Linked document search and display system
JP2002073685A (en) Method and device for supplying retrieval result
JPH06243164A (en) Character retrieving device in machine translation
JP2937634B2 (en) Document creation device
JPH1097537A (en) Translation supporting system and its recording medium
JPH0716192Y2 (en) Text processor
JPH0877206A (en) Information processor
JP2002297277A (en) Help information changing device and its program
JPH0335349A (en) Document processor with example display function
JPH07129566A (en) Kana/kanji converting processor
JP2007034962A (en) Electronic dictionary, retrieval method for electronic dictionary, and retrieval program for electronic dictionary
JPS63184864A (en) Documentation device
JPH0327469A (en) Kana/kanji converting device
JPH11338859A (en) Name input device and program recording medium
JPH0736914A (en) Document processor
JPH11195024A (en) Detection device for distribution information of concentrated appearance unsuitable expression part and its method
JPH1011466A (en) Document preparing device and dictionary information acquisition method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050225

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20060809

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20060822

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20061019

RD03 Notification of appointment of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7423

Effective date: 20061019

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20070109

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20070213

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20070306

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20070313

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

Ref document number: 3933517

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100330

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110330

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120330

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120330

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130330

Year of fee payment: 6

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130330

Year of fee payment: 6

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140330

Year of fee payment: 7

EXPY Cancellation because of completion of term