Installation, Startup, Settings

In this chapter, the ways of installation, startup and settings for get started SMART-GS will be explained. Settings, however, may be a complicated topic for beginners, who should read sections about settings after they get used to SMART-GS. They need not read sections 3-5 in the following contents. Besides, Windows users who will not use Mac or Linux, do not need to read section 2. Read section 1 only and move on to the next chapter in that case.

Contents:

  1. Installation and Startupbasic
  2. Using the Same Data in Different OS's
  3. User Settings: Illustrated by Image Folder Settingadvanced
  4. Other Settingsadvanced
  5. Setting for Startup Fileadvanced
  6. GSX Filesadvanced

basic stands for the contents to be read by all of users, advancedfor the advanced contents.

Modification history 2011.11.10: In ``Installation and Startup'' -> ``Installation,'' the opening sentences were modified.

Installation and Startup

The ways of Installing and starting up SMART-GS are explained.

Installation

First of all, you need to download Zip file of SMART-GS on the website of SMART-GS. The distribution includes source codes, class files in JAVA, sample files and so on. After downloading SMART-GS, you need to decompress them into an arbitrary place. Installing SMART-GS has finished then.

In the following, we assume that the OS is Windows, and therefore path names of files and folders are written as such. Except that, installation, setup and settings in the cases of Mac and Linux, as a rule, can be done in the same way. That is because SMART-GS is implemented in JAVA, which does not depend on OS a lot.

Let's assume, as an example, that the downloaded archive was decompressed directly in C: drive and a new folder C:\smart-gs has been created. The C:\smart-gs is the folder for SMART-GS. Depending on versions, the name of the folder may be different from smart-gs but the difference of names does not concern use. You can rename it at your choice. In the following, the example of C:\smart-gs is used for illustration but replace it with the path name of the folder where you actually installed SMART-GS.

Startup

The distributed files include the executable file smart-gs.exe and batch file SMART-GS.bat for Windows, smart-gs.sh for Mac OS X or Linux. They are the same thing, but if you are a complete beginner using Windows, execute smart-gs.exe. It requires JAVA Runtime Environment to execute SMART-GS but when Java Runtime Environment is not installed to a machine and smart-gs.exe is executed, a browser will start up, and then the download page of JAVA will open. Download JAVA from 'Free JAVA Download' and install it. In the case that 'setting files for startup', as we will see later. needs to be done on Windows, use SMART-GS.bat.

In starting up SMART-GS for the first time, the dialog into which a user name is input appears after the splash window. Follow the explanation written on it and decide your user name and input it. The input username is recorded, then it will be used automatically in starting up afterward. Your user name can be changed in the Preference menu.

The user name is not for security but only for recording the user's activities. In the case that, for example, a large number of users divide the task of transcribing the same images of historical materials with the results shared, all the names of users who added images or annotations on images are recoded in the images or the annotations. That is the reason why an arbitrary name is permitted when you use SMART-GS alone. If you form a team and work on collaborative transcription, or you exchange files with other researchers and students, make sure that each user has a ditinct name. In the future, when SMART-GS has functions supporting collaboration via networks, it will require user authentication by password.

After Inputting a username and waiting for a moment, the following window appears. The window is called workbench, on which workings in SMART-GS are mainly done. Workbench opened, SMART-GS is enabled.

09 At ver.0.9, the arrangement of toolbar etc. were altered. See Starting Panel.

Use and Data Sharing on Linux, Mac

As SMART-GS is made in JAVA language, it is available on all of Windows, Linux and Mac. Data can be shared among these three OS's as long as you pay attention to where on the HDD etc. you store images or how you name files. It is possible, for example, that SMART-GS and its data are stored in an external memory devise such as USB flash memory or external HDD, you connect it to Mac and work with the materials at home, and the next day, bringing the disc into your office, you continue to work connecting it to Windows or Linux then.

The same datum appears on Windows XP, Mac OS X and Ubuntu. (The datum is a Tanabe Hajime material)

As a mouse right button, however, is not available on the default settings of Mac, the preparation for that is required. In the case of Linux, it depends on configurations of window systems whether SMART-GS starts up only with a click on the executable file. Then, some knowledge of each OS is required. Basic settings among different OS's will be explained in 'Tips'. Refer to it, and SMART-GS is available in almost all environments.

These problems are easy to solve but there are also some other problems which are essential. Image compiling is necessary for image search but is accepted only by Windows because Segfo2Dsc, the image processing software that is used to allow SMART-GS to do image search, is only for Windows. There are some versions of DscSearch, a software for image search, ***startup\smart-gs_on_mac.jpg, for Mac and for Linux. Data for image search do not depend on OS and, once you have compiled images on Windows, that allows you to use them on Mac or Linux in the same way.

Now, this problem of compiling images is regarded as an assignment in the future, let's explain what we can do at the moment in the following.

The biggest obstacle in the case of using SMART-GS on Mac is that you do not to have the right mouse button. One of the resolutions is to connect and use a mouse with right button. Actually, on later versions of Mac OS, there is the counterpart to the right button but it is hidden by default. Bringing it out, you do not need prepare another mouse and be able to use SMART-GS in the same way as on Windows. A lot of writings about this topic will be found when you search queries (search terms) like "Mac, right click" or "Mac, right button" in web search (e.g. http://dekiru.impress.co.jp/contents/013/01318.htm) . Some explanations say that Ctrl-left click serves as right click but that manner is not available in SMART-GS in the ordinary configuration. On SMART-GS, the same keystroke is used as a shortcut and you should turn the function off so that Ctrl + left click is for right click on SMART-GS, too. (See also)

In order to deal with that problem without any change of configuration on OS, SMRT-GS is made in such a way as to work, as a rule, with Alt + left click in the same way as with right click in the case that an operation with right click is required on SMART-GS. The function should be helpful for Window users that usually tap on a laptop instead of clicking the mouse buttons. The function, however, may have been forgotten to be put, and in that case, let our development team know that. Use the ticket functions on the SMART-GS page in sourceforge.jp when you contact us.

Those problems above do not occur on Linux, which has been developed on the common hardware to Windows, but unlike on Windows, a window system are allowed to be changed arbitrarily and remember that the startup for SMARt-GS with a click depends on window systems. The most secured way of the startup is to start up with a shell command (such as sh, bash or ash) like sh ./smart-gs08.sh after opening the terminal and moving to the directory where SMART-GS is installed. Try it first if it does not work from GUI.

The above problems are concerned to hardwares and OS, problems with so called platforms. Next some points about SMART-GS itself will be explained. Those points, however, are concerned with those who use more than one OS among Windows, Linux and Mac at the same time, but not with the users always working on the same OS.

Tips 1: ***Data Sharing with Linux or Mac

In the case of using either Linux alone or Mac alone, you do not need to remember anything special but using / on these OS's, instead of \ for Windows, as a separator of directories (the equivalent in Unix related OS's to `folders' in Windows) in specifying pathnames. There is perhaps no need for mentioning it since users must know what path separator is used on the OS that they are using. It will make difference , however, when you use the same SMART-GS on several OS's, for example, Mac at work and Windows at home. The use in such case will be explained.

Written in Java, SMART-GS enable us to store research materials in an external portable HDD, connect it to the computer at your office and work on them, and then, to bring the HDD home, connect it to your computer at home and use the same research materials. See 'Tips 2' how to use in a specific way. No problem will occur when you use the same OS with both the computer at work and the one at home. But when, for example, the computer at home is Mac and the one at work is Windows, there are two problems to be managed with some twists. In the following, the way to manage the problems will be explained.

In the case that SMRT-GS is used on different OS's, the difference between separator of directory (folder) paths to specify the places in which images or GS files are stored. \ is the standard separator for Windows, and / for Linux and Mac. Thus, you have to write ./smart-gs/images/ on Mac or Linux instead of writing .\smart-gs\images as you do on Windows.

Actually, / other than \ is available as separator on Windows and so Preference with / written on Mac or Linux is available on Windows as it is. The reverse, however, is not true. \ is not a path separator on Mac or Linux. It does not work normally when Images in Preference to specify the place of images in a Windows machine are used on Mac or Linux without changing, for example, .\smart-gs\tanabe_study_images\. In such a case, you need replace \ by / in Peference in the style of Unix. That is inconvenient in the case that various OS's are often used. So, if possible, the separator in the style of Unix should be used even on Windows. The UNIX style is used in the Preference in the distributed SMART-GS.

More troublesome than separator is the difference in the ways of naming a disc between Windows and Mac or Linux. On Linux or Mac. On Linux or Mac, what is called a mount point is determined when some storage such as an HDD or a USB disc is connected to the system. This corresponds to a drive number on Windows, that is, C: or H: as in 'Local Disc (C:)' and 'Removal Disc (H:)' , which appear when the icon of My Computer is opened. The concept of drive number does not exist on UNIX like OS's such as Mac OS X or Linux. For example, on Mac OS X, in the case of connecting HDD with the volume name HDD1, the mounting point is usually the directory /Volumes/HDD1/ (on Linux Ubuntu 11, /device/hdd1/). This is what corresponds to a drive name, and if Images in Preference is specified as "Z:\smart_gs\images\" on Windows, "Z:" needs to be replaced by the mount point and then the directory is: "/Volumes/HDD//smart_gs/images/".

That is, however, the case when a drive name is used in the specification of Images, and you do not have to care about the mount point in the case that the directory is specified using a relative path, for example, .\smart_gs\tanabe_study_images\. With separators in UNIX style, written as ./smart_gs/tanabe_study_images/, it is available for all OS's, Windows, Mac and LInux without any change.

 

User Settings: Taking the setting of the Image Folder as an example

In the section, user settings will be explained for a cleaver use of SMART-GS. It is easier for beginners of SMART-GS to use SMART-GS by default. It is recommended that they try to set up the things to be explained here after getting used to SMART-GS. Those who, however, have got used to SMART-GS a little may hope to customize SMART-GS in various ways.

For example, imagine the case that a large image archive of a writing is dealt with in a seminar of historical materials analysis. When SMART-GS runs in the default settings, as explained in 'To add and remove images' in the chapter of 'Workbench', a required image is used after it is copied in the default image folder in SMART-GS. By default, images are copied to smart_gs\images among the folders in SMART-GS, for example, C:\smart-gs\smart_gs\images. This becomes, however, troublesome as all large-volume images are copied in each C:\smart-gs\smart_gs\images folder in every student's PC. In that case, it will be useful to put an image in a shared disc on LAN like NAS and to connect students' PC to LAN in a seminar. In the case that NAS's drive name is W and an image archive on NAS is TanabeBunko, W:\TanabeBunko is required to be specified as the image folder. In that case, do as follows:

1. In order to set up the path to image files, launch SMART-GS and choose Preference in the menu bar.

2 . In the Preference menu, there are the following items:

  1. User Name
  2. IDAT Names
  3. Image Search Engine
  4. Image Search Type for Dictionary
  5. Text Type
  6. Search Size Bound
  7. Markup
  8. Data Directories & Files
  9. Resource Basket Default Save Option
  10. WebDAV
  11. Proxy
  12. Web Browser
  13. Editor (09 External Editor at SMART-GS0.9)
  14. 09 Window Display Mode (Added at SMART-GS 0.9)
  15. 09 Search Highlight Mode (Added at SMART-GS 0.9)

Here choose Data Directories & Files to set up the path for images.

3. Data Directories Settings dialogue appers as follows:

data_directories_setting.png

Write a path name for the folder in the item Images on the dialogue and the folder is set as the image folder. For example, you need either to type W:\TanabeBunko directly or to click the [select] button and choose the folder with a file chooser.

4. At the end, click the OK button in the Data Directories and Files Setting Dialog and the settings are saved, but the saved settings will not work unless SMART-GS is rebooted in the next time. Because of that, after the following dialogue appears, click the ***consent button.

 

Note1. Default: ***what are standard states without any change.

Other Settings

Among the functions in Preference on the menu bar, Set Directory Path has been explained by the example of image folder path setting. Other items will be explained in order.

  1. User Name
  2. IDAT Names
  3. Image Search Engine
  4. Image Search Type for Dictionary
  5. Text Type
  6. Search Size Bound
  7. Markup
  8. Data Directories & Files
  9. Resource Basket Default Save Option
  10. WebDAV
  11. Proxy
  12. Web Browser
  13. Editor (09External Editor in SMART-GS 0.9)

``User Name'' is used to register the user name, which is recorded in ExplanatoryNotes and Markups. The user name is also registered when you first boot SMART-GS with the user name register dialog. For ExplanatoryNotes, see Creating and Displaying a Link in 4. Workbench in this document. For Markups, see Marking Up an Image in the same section.

``IDAT Names'' is used to change IDAT names. Selet this menu, and the dialog ``IDAT Name Setting'' will appear. You can change names for First IDAT, Second IDAT and Third IDAT. By default, they are named Note1, Note2 and Note3 respectively.

``Image Saerch Engine'' is used to choose whether you use the image search function internal to SMART-GS or DSCSearch, an exernal application. If you choose the former, check External; otherwise check Internal. The search speed is in general faster when you use DSCSearch. So you should select External if possible. The internal search is possible, but it is slower because it is executed in Java programs.

``Image Search Type for Dictionary'' is used to choose an Image Search type within the Dictionary function. This is still experimental. Users are recommended to use TYPE1.

``Search Type'' is used to choose the image search type from Default, DTW_1 and DTW_2. The accuracy becomes higher in this order, while the time the search takes becomes longer. Default is chosen 標準の状態ではDefaultになっています。 イメージサーチについては、5. イメージサーチを参照してください。

091 「Text Type」は、画像ファイルとして読み込んだ文献が縦書き(vartical)か横書き(horizontal)かを指定します。 これはSMART-GS0.9でのDSCファイル作成時の行切り出しやイメージサーチを行う際に必要になりますが、 SMART-GS0.9.1では無意味になりました。091 での取り扱いについては、こちらを、 DSCファイルについては、4. ワークベンチ のなかの「DSCファイルの作成」を参照してください。

Search Size Bound」は、イメージサーチの調整用です。一般ユーザーは設定しないで空白のままにしておいてください。 イメージサーチについては、5. イメージサーチを参照してください。

Markup」は イメージのマークアップ に関連したいくつかの設定を行います。

「Data Directories & Files」は先の例の画像フォルダの様に、 SMART-GS を利用する際に有用なデータファイルやそのフォルダの設定を行ないます。項目は次のとおりです。

相対パスでの指定する場合のカレントフォルダ(カレントディレクトリ)は、SMART-GSが起動されるフォルダになります。これは特に設定を変えていなければ、起動バッチファイル smart_gs.bat のあるフォルダ、つまり、SMART-GSを実装したフォルダになります。

Resource Basket Default Save Option」は Resource Basket の保存に関するデフォルト・オプションを選択します。

WebDAV」は、ファイルを保存するサーバへのアクセス設定を行います。 WebDAVを利用することで、SMART-GSで使用するgsxファイルなどをネットワーク上で共有することが可能になります。 WebDAVの使い方については、4.ワークベンチのなかの「GSXファイルの保存、読み込み」を参照してください。 このメニューを選択すると「WebDAV Setting」というダイアログが表示されます。 このダイアログの「server path」には、gsxファイルを保存するサーバのurlを記入します。 また、「user id」、「password」にはそれぞれ、server path で指定したサーバに接続するためのユーザーIDとパスワードをします。

Proxy」では、インターネットに接続する際の Proxy を設定します。 Proxy の address と port を入力します。

Web Browser」は、SMART-GSから呼び出すWebブラウザの指定を行います。 利用したいWebブラウザの実行ファイルを指定します。 これはWWWへのリンクが指定されているときに、そのリンク先を表示するために使われます。

Editor」は、SMART-GSで利用するエディタの指定を行います。 User's Note を編集するときSMART-GSのエディタではなく、外部のテキストエディタやHTML、XMLエディタを使ってソースを編集することができます。そのときに使用したいエディタの実行ファイルのパスを指定します。 09SMART-GS0.9では、この項目は External Editor と改名されています。変更は名前のみです。

09 Window Display Mode」は、SMART-GS 0.9 で追加されたPreference 項目で、画像がテキスト(IDAT)に対してどの位置にあるかを指定します。位置は Top, Bottom, Left, Right の四つで、たとえば Top を選択すると 0.8 と同様に画像がテキストの上に表示されますが、Bottom を選ぶと画像が下に表示されます。横書きの資料の場合、Left か Right を選びテキスト画像と翻刻を横に並べて表示すると作業がやりやすくなります。また縦書きの場合も、Left, Right にすると縦が短い通常のディスプレイでもテキスト画像の1行全体を表示しやすくなります。Preference でモードを選ぶと、その場で表示位置が変更され、SMART-GS 終了時のモードが Preference として記録され次回起動時に使用されます。

09 Search Highlight Mode」は、SMART-GS 0.9 で追加されたPreference 項目で、 All と Off の2モードがあります。All モードにすると、テキストのサーチを行った際に見つかったすべての箇所が一斉にハイライトされますが、Off ですとハイライトされるのは最初の箇所だけになり、後は順次表示していくことになります。Default は All です。

起動用ファイルの設定

この項の起動用ファイル(起動用バッチファイル)の設定は上級者向けです。 設定を間違うと起動しなくなることがありますので注意してください。 もし変更して、起動できなくなった場合は、起動ファイルをインストール時のものに戻してください。 SMART-GSを再度ダウンロードし、使っているSMART-GSのフォルダとは別の場所に展開し、起動ファイルのみコピーしてくればもとに戻ります。。

以下で、起動用ファイルの簡単な編集により SMART-GS をより便利に使う方法を説明しましょう。

典型的な起動ファイルの中身は次のようになっています:
set classpath=.\bin;.\lib
java -Xmn160m -Xmx480m -Xms480m smart_gs.SmartGS -p project1_preference.xml

一行目はJavaの起動のためのクラスパスの設定です。 二行目の先頭で java を呼び出しています。

java の最初の三つの引数 -Xmn160m -Xmx480m -Xms480m は、Java の起動オプションで、Java が使用するメモリ(ヒープ)のサイズを設定するものです。 詳しくはたとえば、http://www.atmarkit.co.jp/fjava/rensai3/javavm02/javavm02_2.htmlの解説を参考にしてください。 問題がなければ、インストール時の値から変更する必要はありませんが、画像の数が多く、またPCも十分に高性能である場合には、三つの設定値を換えてみるのも良いかもしれません。 変更する場合は Xmx と Xms を同一にすることを薦めます。

4番目の引数 smart_gs.SmartGS は、SMART-GSを起動するクラスの名称でこれを変えると起動しなくなりますので注意してください。

5番目の引数 -p project1_preference.xml は、SMART-GS に与えるオプションで、-p の後に Preference で指定した初期設定の値が保存されるXMLファイルを指定します。 このオプションを指定しない場合は、SMART-GSはデフォルトの初期設定ファイル preference.xml を使用します。

なお、SMART-GS の配布物に含まれている Windows 用の実行ファイル smart-gs.exe は Java の .jar ファイルから、launch4jというユーティリティを用いて作成しています。 実行ファイルを作成する際に、上述の java の引数を設定することができます。 配布物に含まれている smart-gs.exe では特に引数を設定していませんが、必要な場合は、一緒に配布されている launch4j の設定ファイルを参照の上、設定して下さい。 上述の java に渡すオプションは、launch4j の [JRE] タブの [JVM options] で、SMART-GS に渡すオプションは、[Basic] タブの [Command line args] で指定することができます。 なお、後者の SMART-GS に渡すオプションは、生成された smart-gs.exe に直接指定することもできます。 詳しい使い方は、launch4j のページを参考にして下さい。

便利な使い方2:SMART-GSを持ち歩く

USBディスク、SDカード、ポータブルHDDなどに SMART-GS と同時に Java もインストールしておくと、ディスクをPCに差し込むだけで、SMART-GSを使えるようにできるので便利です。画像ファイルの大きさと、実行速度のことを考えると、SDカードかポータブルHDDを使うべきですが、値段と携帯性を考えるとUSBディスクも悪い選択ではありません。しかし、立ち上がりなどの速度が遅くなるという欠点はあります。

たとえば、ドライブ番号ZのポータブルHDDのフォルダ Z:\smart-gs\ にSMART-GSがインストールされているとします。このとき、Z:\jre6 に java をインストールし、java.exe  のパスが Z:\jre6\bin\java.exe だったとします。このとき起動ファイル Z:\SMARTGS\SMART-GS.bat の内容を
..\jre6\bin\java.exe -classpath "bin;lib\*" -Xmn160m -Xmx480m -Xms480m smart_gs.SmartGS
にしておくと、Windows PCにHDDを接続するだけでSMART-GSを起動できるようになります。

HDDのドライブ名は環境によって変わってしまいますので、こういう使い方をする場合には、Preference のパスはなるべく相対パスで指定すべきです。たとえば画像フォルダ(Images項目)がZ:\SMARTGS\smart_gs\images(デフォルト値)、GSファイルフォルダ(GS Files項目)が Z:\SMARTGS\smart_gs\gs(デフォルト値)、デフォルトのGSファイル(Default GS Files項目)がZ:\SMARTGS\smart_gs\gs\S09LectureNotes.gsx である場合、Preference を次のように指定します。

また、これは Windows  の場合ですが、Mac, Linux の場合も同様にすることがでます。ただし、Java の実行環境 JRE は、OS ごとにちがうので、もし、自前で Java を持とうとすると、使うOSすべての Java をインストールしておかないといけないことになります。

便利な使い方3:複数の研究を行う

SMART-GSによる翻刻などの研究結果を保存するGSファイルを起動時に直接 SMART-GS に指示することはできず、起動した後でGSファイルを指定して読み込む必要があります。これは、一度に二つの研究を同時に進め、そのためにそれぞれの研究ごとにGSファイルも別にする場合などには不便ですが、次のようにすれば、この問題を解消することがでます。たとえば、S09LectureNotes.gsx とS10LectureNotes.gsx という二つのGSファイルのそれぞれに対して、その内容が次のような二つの Preference ファイルを作ります。

s09_preference.xml

s10_preference.xml

09_preference.xml を作るには、Preference menu で設定を行い、SMART-GS を終了させた後に、preference.xml を s09_preference.xml にコピーするという方法が一番確実ですが、XML ファイルなので、テキストエディタで開いて直接編集する方が簡単です。

そして、起動用ファイル s09LectureNotes.bat と s10LectureNotes.bat を次のような内容でつくります。

s09LectureNotes.bat
 set classpath=.\bin;.\lib
 java -Xmn160m -Xmx480m -Xms480m smart_gs.SmartGS -p s09_preference.xml

s10LectureNotes.bat
 set classpath=.\bin;.\lib
 java -Xmn160m -Xmx480m -Xms480m smart_gs.SmartGS -p s010_preference.xml

これにより、s09LectureNotes.batを起動すれば S09LectureNotes.gsx を、s10LectureNotes.batを起動すれば S10LectureNotes.gsx を使うことができるようになります。

GSX ファイル

バージョン 0.8 から SMART-GS の保存形式はそれまでの GS ファイルから GSX ファイルに変更されました。 このファイルは SMART-GS 関連の XML ファイルを ZIP 形式で圧縮したものになっています。 現在、内部的には以下のような構造になっています。

spread.xml
SMART-GS の本体の保存形式。 画像ファイルの位置やマークアップの情報などが保存されています。
dictionary/default.xml
辞書ファイル。 将来的には、複数の辞書を切り替えて使うことができるようになる予定です。

0.8以降のSMART-GSではGSファイルは利用できません。そのためGSファイルはGSXファイルに変換する必要があります。GS ファイルは、メニューの [File] -- [Convert GS File to GSX File and Open] で、GSX ファイルに変換することができます。

[Convert GS File to GSX File and Open]を選択するとファイル選択用のウィンドウが開くので、そこからGSXファイルに変換したいGSファイルを選択します。すると同じフォルダにGSXファイルに変換されたファイルが作成されます。元のGSファイルが「xxx.gs」という名前だとすると、変換されたGSXファイルの名前は「xxx.gs_converted.gsx」になります。SMART-GSは直ちにそのGSXファイルを読み込んで開いた状態になります。もとのGSファイルはそのまま同じフォルダに残されます。変換にエラーがある可能性もあるので、GSファイルは残しておくことをお勧めします。

 


SMART-GSの初期画面 トップへ戻る ワークベンチ