1
<?xml version="1.0" encoding="UTF-8"?>
3
* Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4
* Copyright (C) XXXX-2008 - INRIA
6
* This file must be used under the terms of the CeCILL.
7
* This source file is licensed as described in the file COPYING, which
8
* you should have received as part of this distribution. The terms
9
* are also available at
10
* http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
13
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="ja" xml:id="getrelativefilename">
15
<refname>getrelativefilename</refname>
16
<refpurpose>絶対ディレクトリおよび絶対ファイル名を指定すると,
22
<synopsis>rel_file = getrelativefilename(abs_dir,abs_file)</synopsis>
30
<para>文字列 : 絶対ディレクトリ</para>
36
<para>文字列 : 絶対ファイル名</para>
42
<para>文字列 : 相対ファイル名</para>
49
<para>絶対ディレクトリおよび絶対ファイル名を指定すると,
52
<para>例えば, カレントのディレクトが C:\scilab\bin の場合,ファイル名
53
C:\scilab\modules\helptools\readme.txt が指定されると,
54
getrelativefilename は ..\modules\helptools\readme.txt を返します.
59
<programlisting role="example"><![CDATA[
60
if getos() == "Windows" then
61
getrelativefilename('C:\program file\scilab-4.0\bin','C:\program file\scilab-4.0\modules\helptools\help.dtd')
62
getrelativefilename('C:\program file\scilab-4.0\bin\','C:\program file\scilab-4.0\modules\helptools\help.dtd')
63
getrelativefilename(SCI+'\bin',SCI+'\modules\helptools\help.dtd')
64
getrelativefilename(WSCI+'\bin',WSCI+'\modules\helptools\help.dtd')
65
getrelativefilename(pwd(),WSCI+'\bin\Wscilex')
67
getrelativefilename('/usr/local/scilab-4.0/bin','/usr/local/scilab-4.0/modules/helptools/help.dtd')
68
getrelativefilename('/usr/local/scilab-4.0/bin/','/usr/local/scilab-4.0/modules/helptools/help.dtd')
69
getrelativefilename(SCI+'/bin',SCI+'/modules/helptools/help.dtd')
70
getrelativefilename(pwd(),SCI+'/bin/scilex')
74
<refsection role="see also">
76
<simplelist type="inline">
78
<link linkend="getshortpathname">getshortpathname</link>
81
<link linkend="getlongpathname">getlongpathname</link>
84
<link linkend="pwd">pwd</link>