日本語のReadmeは英文のあとにあります ====================================== HTML format tuning tool; On
tug html document,it makes a short segment chractors line is moved arround the left side of fixed center style not on the browser's edge side. 'Please donot walk on the center of the big avenue.' Ver0.01 Copy Right MIYAMA. 2011 http://www.geocities.jp/kaz_kimijima kaz_kimijima@yahoo.co.jp ====================================== //Introduction I suppose that a needs may be to exist the demand to HTML-ization from normal memorandam text file. If one has a small kowledge of html format grammer, it is not difficult. One way of it is to use a method of the tug
. The tug is able to 
realise it without 
tug for carridge-return function correcly on the whole each lines. On the concreate example, 1 to add nexts to the document text file, new headline
 new tailline 
2 to change files' extension to html or htm from txt. Only using it, it is capable to realise to view from html net browser. But probablly, it is a limit to study for html grammer- biginners. The image expression and the anchor tug method may be more difficult for common level. Off cource,it is not bad problem at all. Many people are busy for daily work or life, they cannot get a enough hour to study those complex matter without any profit. Any wonk nard can not has any disapointing for them on this meaning. Practically, some productional package software as the html editor may be needed for the higher level html functional demand. But it is a enough way only to view document contents using pre tug. Then, I used this pre tug way through some long time, but I was noticed a bitter one problem. This pre tug way makes our fatigue when one reads more long sentences as a manual or long novel document on the browser, because the way makes whole the document line to be moved the critical left edge of browser view window. In this past time, I remembered the being the
tug that makes all document line are moved to the center zone for the view window. but I was noticed a little disapointment. Some small segment of charactor's lines are also agree around to the center tug command order with purely shinsere sinmetry. For example, one sentences on the source text as the next, ---------------------------------------- the snow white lived on the house with 7 dowarfs. ---------------------------------------- it will display on center mode, ---------------------------------------- the snow white lived on the house with 7 dowarfs. ---------------------------------------- It is a poor funny result. Though it can be readed it, it is no suitable for formal purpose. and it may also makes us more fatigue to read long document. Then, I thought the way that can desolve this bad fenomina. I tried for this 'dowarfs', to say donot walk on the center of the cities' big street. Hi-HO! woodmen! The program mechanisum is only simple. It adds enough mass of the space charactors to the tail of the short words line. Off cource, always any charactor is true charactor on the PC system code. then, also space charactor is sure. Although it show only vacant for editor or any viewer of the browser, it has a same width of another charactor. The HTML viewer system recognizes it is a long sentences if any program adds enough length of the space charactors sequences. Then, I made it as sure. This tool adds spaces after the 'dowarfs', and dowarfs will be leaded by those spaces to the avenues left side. ... Excuse me, where is the snow white? the one of the dowarfs asked the police men for traffic patrol. The police man said, I donot know, my job is only for cars and walkmen's safty, if you quest any girl, it is well to visit our police office of this town. Thanks, by the way your figure is sometimes trans lucent vacant, it is near the charactor, the 1 byte space. Probablly , are you a famous space police man?? He lauphed, No, No I am not a member of the famous people. //Permission to use it is a free ware. All any one can use and send to others. //No responciblity This program author donot have any responclibility for any lost profit or pc bad condition. //Machine envilonment of the PC. It can act only the windows PC with internet explore ver 4.0. It cannot act on the machntosh because it uses windows mechanical inner program libruary. //Method to use /Melting The archiver is zip style. Please melt it by any suit archiver. Next is extract files list. ReadmeCH.TXT this now readme document. CentHTML.HTM actual execute html script file. Please click execute script icon, then next window will be appeared. ------------------------------------_[]X Input box source text filename [file direct conference button] [go action execute] Input box sum charactors number box per line. [Language choice button Eng/Jpn] :default is English mode ----- HTML tuning the bigth of all charactors back ground color default is ffffff :white text fore color default is 000000 :black ---------------------------------------- /Operation The operation may be a simple, but any attentional matters are there. Main operational steps are only next 2 stage. 1 Source filename inputation 2 And push down execute key button. /Source text filename input One way manual direct filename input or using direct conference guide button are there. Practically, manual input can only search file to the surface of the pc desktop. If one can use the expression .\ or c:\ as the relative or absolute conference, the manual filename methode may be more useful, but it is only acrobat. please use conference button generally. But prpbablly for protection of the irregual web attack, at least the explore does not permit by the keyboard's key down only on this button. Please use to click by mouse or any physical pointing device. My program logic is permit extensional style for suorce files only the txt. If one choice other extensional file types, then the after process will checks it and returns error. /Sum charactors number per one line. For english user, please use it on the english mode as the default. Japanese mode for only 2 byte charactors document. This number's default is 60. This tuning makes for all short length line, they have 60 charactors compleatly using to add space charactors. If one short line has only : 7 dwarfs ,then , the program adds 52 pieces spaces charactors after this. On the other hands, on this example tuning, program acts no action for the lines having over 60 charctors. Then, please input more big number to this number-window, when those fenomina occured. This number requires that it is being max charactors number or not average. And this logical permission renge from 1 to 1 thousand. /Mode changing button The mode chinging donot change the logical core action. Changing points are next, 1 input chractors length width by the rules of 1 byte or 2. 2 action message language changing. This program has two mode:English and Japanese. Many language on PC have to use 2 byte code as the extended one. On fixed picth display mode of many editors or viewers not with proportional mode, The 2 byte charactors have two times of width the 1 byte one. /Output File The result output file will be maden to the Desktop holder, as the name : OutputCH.HTM. It is the result document. Please copy as another different name avoid for miss-overwriting. For the demand to use more complex html tug on those result, please use more high-classed html editor as the package product. /Tuning HTML style This tool tunes only color and charactors bigth. The color tuning for bacck ground and text fore color. The words' bigth tuning for html tug 's property. The number is permitted as its value, from 1 to 6. 1 is big and 6 is most small size. //Attention This tool puts many spaces into a line. Then, because output file's contents has many spaces charactors with all visual vacant zone,this result output is not suit to the purpose to edit again. Please do content-editing on the original source text file. //Appendex The color tuning has a style RGB256 style. Examples ffffff white 000000 black ff0000 vivid red 00ff00 vivid green 0000ff vivid blue -------------------------------------- the next is japanese readme; ====================  センター表示書式で、行を左寄せに調整す るHTMLツール  「まんなかを歩かないでください」 Ver0.01 CopyRight MIYAMA. 2011 http://www.geocities.jp/kaz_kimijima kaz_kimijima@yahoo.co.jp ==================== 1はじめに  普通、いそがしい日常のなかでは、文書と 言うものはちょこちょこと書き付けた書式に とらわれないメモがもっともおおいと推測し ます  またそれはPC上もたぶんそうであり、文書 とはテキスト形式のメモがもっとも点数が多 いとも想います  そのような素でベタ打ちされたテキスト文 書をHTML化し、オンラインやイントラネット で共有公開したいという動機はニーズとして また多いことでしょう  そのためには専用のHTMLエディタが必要と 先入観を持っている人は多いのかもしれませ んが、多少のHTMLの知識があれば簡便な形式 でよければメモ帳でそれは可能です  HTML文法のなかでは、テキスト表示を遵守 して表示するすることを命令する
タグ
というものがあり、これをふくんだ形式でフ
ァイル冒頭と末尾各一行にこの文書がHTML文
書であることを宣言してやればブラウザで閲
覧することは可能です

 具体的には

 1ー1 テキスト文書の冒頭と末尾に

 冒頭 
 末尾 
を追加してやり、  1−2 ファイルの拡張子を.txtから.htm ないし.htmlに変更する  だけで可能です  画像表示やリンクの埋め込みは残念ながら 多忙氏の余暇で習得は難しいので、それはや はり製品版のHTMLエディタが必要になるのは いたしかたありません  自分もしばらくはこの書式を使用してきま したが、この形式では、ながい文章(マニュ アルやオンライン創作など)を読むときには 多少疲れることに気がつきました  preタグ書式では、画面が左に寄りすぎて しまうのです  それならば、と文章の中央表示命令タグ  
 を用い、文書をブラウザ中央に表示させる ことをこころみましたが、とんでもない現象 があらわれることに気付かされました  たとえば ーーーーーーーーーーーーーーーーーーーー  むかしむかしうらしまはたすけたかめに、 のせられて ーーーーーーーーーーーーーーーーーーーー という文章は、center命令表示では ーーーーーーーーーーーーーーーーーーーー  むかしむかしうらしまはたすけたかめに、         のせられて ーーーーーーーーーーーーーーーーーーーー と表示されてしまいます  読めないことはないのでしょうが、ちょっ と滑稽でフォーマルな実務には使えません  普通はここであきらめてしまうものなので しょうが、今回center命令を使用したまま、 上記の前者のように表示できないかと、試行 錯誤をしてみました  そこそこの結果ができましたので上梓いた します  ・動作原理  「のせられて」の文言に「まんなかをある かないでください」といえばよいのですが、 プログラム的にはどう実装したらよいでしょ うか  ここで空白文字列を使用することにしまし た。半角全角を問わずスペース文字は表示上 ではみえませんが、ブラウザシステムはやは り幅のある文字として扱います  上記の前者のように表示させるためには、 のせられて の前の行 かしうらしまはたすけたかめに、 <---------------------------> の幅だけの空白文字列を用意し、 「のせられて」のあとに追加してやれば、見 かけ上の表示はcenter命令下でも、目論見ど おり表示されます  プログラム上では、この追加空白を状況に 応じて増減して柔軟に追加する実装が求めら れます  具体的には原本を読み込む時点で、その行 が文字数にして何文字あるかということを逐 次読んでいけばいいのですが、今回はウィン ドウズライブラリに用意されている文字数判 断関数ではなくて、文字数と同時にその半角 全角を区別して文字列部分の幅を算出する簡 単な関数を自作してそれを利用しました  このため、数式があるような全角半角混在 のような文書も処理ができます  用意されている文字数関数では、半角も全 角も一文字として数えてしまうので表示幅を 取得する目的のためには使えません  過去のおぼろげな記憶から、ライブラリに そのような関数があったような気もしますが、 手元に資料がないので、自作しました  興味のあるかたはコードを見てください  全角文字のアスキーコードは負値であるこ とを利用しています 2使用許認可条件  使用配布ともに制限はありません 3免責  作者はこのツールを使用することによって おこるあらゆる不利益不具合に何ら責任を負 いません 4動作機械条件  インターネットエクスプローラ4.0以上 が動作するウィンドウズマシンで動作します  マッキントッシュでは動作しません 5使用方法  ・解凍  アーカイブCentHTML.ZIPを解凍ソフトで 展開してください  README以外に実行スクリプトファイル  CentHTML.HTM がでてきます  このファイルをクリックすると操作画面が 表示されます ーーーーーーーーーーーーーーーーー_ロX 原本テキスト名入力窓 参照ボタン 実行ボタン 一行あたりの設定文字数  日本語モード初期値は31文字です 英語日本語切り替えボタン  初期値は英語モードです ーーーーー HTML属性設定 文字の大きさ 初期値は小さ目の3値です 背景色    初期値は白色 ffffff 文字色    初期値は黒色 000000 ーーーーーーーーーーーーーーーーーーーー  操作そのものはシンプルですが若干の注意 点があります  起動時は英語モードです  メッセージが英文になりますので、ボタン をクリックして日本語モードに切り替えてく ださい  操作はテキスト名入力窓にファイル名を入 れ、実行ボタンを押し下すのみです  ・原本テキストファイル名入力窓  ボックスに直接ファイル名を入れるか、参 照ボタンでファイルを選択します  エクスプローラの性質により、参照ボタン はマウスでしかクリックできません  この窓は拡張子txtのファイルしか入力は できません  厳密には選択はできますが、つぎのプロセ スが拡張子のチェックをおこないますので、 違う場合はエラーが表示されます  このボックスは、素朴にファイル名だけを 手打ちで入力した場合、デスクトップ上のフ ァイルを探します  相対参照もできますが、選択ボタンで参照 したほうが実際的でしょう  ・一行あたりの文字数入力窓  一行あたりの文字数を入力します  起動時は英語モードになっていますので、 モードボタンで日本語に直してください  モードがちがうと文字数の初期値も変わり ます  これは、英語モードでは文字を半角の幅で 換算、逆に日本語モードでは全角幅で換算し ているためです  初期値は英語モード半角60字、日本語モ ード全角31字になっています  日本語モード文字数が一文字多いのは禁則 処理への配慮です  文書によって適宜文字数幅の最適な数値を 入力してください  ここで注意すべきことは、たとえば設定が 31文字の場合、対象行が35文字や40文 字など設定よりも多い場合は、プログラムは 空白を追加しません  ですから、出力のセンター表示属性が乱れ ますので、設定はもとの文書の一行平均文字 数ではなく、最大文字数を入力してください  もしはなはだしく行の文字数がそろってい ない場合は、第一手前味噌として拙作の「羊 羹の型」で整形できます  最大設定文字数は全半角とも1000文字 です  ・モード選択ボタン  上記でも述べましたが、文字換算が半角全 角あつかいの切り替え、またメッセージが英 語か日本語かの切り替えをおこないます  ・出力ファイル  出力はデスクトップにOutputCH.HTMとし て出力されます。あやまって上書きしないよ う、動作毎に別名保存をしてください  さらに編集したい場合は市販のHTMLエディ タなどを使用してください  ・HTML書式設定  複雑な設定はできませんが、文字、背景の 色彩、ならびに文字の大きさは設定できます  文字の大きさは1から6まで指定でき、数 がおおきいほど逆に文字は小さくなります 6注意事項  このツールはファイルのすべての行余白に 空白文字を埋め込みます  ですから表示的にはなにもみえなくとも、 そこにはぎっしりと空白文字がならんでいま すので、出力ファイルの文書内容をさらに推 敲する目的にはむきません  文書推敲はかならず原本でおこなってくだ さい 7備考  ・禁則処理について  行末の「、」「。」が行尾にはみ出す形式 処理をおこないたい場合は、たとえば全角3 0字/行の場合は一文字追加して31文字に してください  都合31字である行末句読点行に、それ以 外の行が従うので表示がそろいます  ・色彩値について  文字と背景の色彩値はRGB256進です  具体的な説明は書籍やサイトで調べてみて ください  例  ffffff 白  000000 黒  ff0000 赤  00ff00 緑  0000ff 青  上記の例はビビッドカラーです  第二手前味噌ですが「かぎりなく白色に近 いブルー」で色彩パレット値調整ができ、ま た同梱のreadmeに色彩理論の簡単な解説があ ります 8あとがき  今回、ツールのニックネームを最初の構想 名から変更しました  今回のニックネームについて若干補足した いと想います  車道のどまんなかをあるくのはもちろん危 険ですが、運転手氏の立場から見れば、車の 中から見えないようなところをいわばこそこ そあるくのもまた、本当は危ないのです  今回のツール名の最初は、景気のいいころ のある流行語でした  ただ、現在の深刻な経済の不可逆的な収縮 期 :約20年間若い世代に職業訓練としての就 業機会を与えなかった結果、リアルな価値観 や現実的な労働感覚がまる一世代育っていな いので、付加価値をあたえる輸出産業がじき に維持できなくなり、輸出で外貨を稼げなく なり、過剰5000万人分の糊口食料を輸入 することができなくなります  いづれ事実上の人身売買に農村の小作とし て安く売られるかれらは、2011年現在、 携帯をふくめたネットか、スロットの前に座 っています において、その一種明るい流行語を使うこと は自分の感覚からいって、抵抗がありました ので、文言をいれかえることにしたのです  とはいえ、以下のくだりを読めばそれがな んであるかは、勘のするどい方ならすぐにわ かってしまうことでしょう  私は芸能や漫画の引用はしないことにして います  ですから、今回のツールの動作の特徴をそ の流行語がいかに的確に表現していたとして も、それを名前として、使用することにも抵 抗がありました  なぜそれらのジャンルのことに触れないか というと、ひとえにその業界が大変な世界で あることに起因しています  もちろんそれはかならずしも褒め言葉では ありません  たとえば漫画の形式の例でいえば、それは いっけん華やかですが、冷静に点検してみれ ば活字に比べて可能な表現の可能性がかなり せまく、また版下を仕上げるための巨大な手 間を考えれば、内容を推敲したり綿密に取材 することは現実ほとんど不可能です  かれらのなかから長者番付が過去多く出た のは、それはメディアミックスという付加価 値のからくりがあったからで、それはあくま でも世の中がある程度の好景気に沸いている ことを必要としています  そうでなければ、枠の取得を因数として積 算する手間も考えれば、かれらの生業は本来 すずめのなみだです  また、からくりと広告で売る手法から見れ ば、あえていえばつぼさえおさえておけば、 内容はどうだっていいのです  取材や推敲が事実上不可能と言う意味を含 め、たとえば漫画ではその内容が問われるこ とはあまりありません  芸能の世界も似たようなものでしょう  もともとこのような世界というものは、団 十郎のむかしから、最終的なクライアントの 立場からみれば別になくとも生活になんら支 障のない扶桑の生業です  当然、不況の直撃にはとても弱いです  まともな親御さんであれば、それは自分の 子供が使い捨てにされて路頭に迷いかねない 世界ですから、一般論、芸能や漫画の世界の 親御さんの半分ぐらいはたぶん馬鹿者なんだ ろうなあ、と個人的には思っています  一家丸ごとゆるい田舎者に、東京人である 自分の方角からは見えるのです  当人達に、生き残りの危機意識があれば、 あんなゆるいなれなれしいペーソスで営業は しないだろうなあ、という人ほど、おだてら れたあげくに使い捨てにされるものじゃない んでしょうか  江戸文化にはそのような意識がつねにあり ますから(大飢饉のたびに流人が流入し、ま たかれらのあいだでも仕事の奪い合いから、 餓死の危険は実は都会のなかでも無縁ではな い)芸のまえに、実業で手に職をつける、ま たどうしても扶桑芸でやっていくのであれば、 他人の批評にはずかしくないほどの上達が義 務である、という一種の悲壮感が背景にあり ました  たかが流行語ですが、よくもわるくも無責 任ということが景気の浮遊感覚のなかでゆる されていたあの時代が、  たぶん二度とはふたたびこないことを切実 に感じるからこそ、そのことばは今回ツール の題にもつかえなかったのです  それは、痛い、です  本人氏の名誉のために書きますが、ながい 不遇を経験してきた氏は、たぶん今回の全体 的な状況には免疫ができているのですくなく とも今日明日の意味ではこたえてはいないと おもいますが、しかし自分をもふくめ、この 経済が崩壊してしまえばそんなこともたわご とになるかもしれません  すくなくとも、豊かすぎた昭和後期にでて きた一部の世代を別にすれば、不遇経験とい うものはリアルの感覚を学ぶという意味でも すべての職業において芸のこやしとして必須 のもののようですね  MIYAMA. ーーーーーーーーーーーーーーーーーーーー