summaryrefslogtreecommitdiff
path: root/Doc/Manual/Introduction.html
diff options
context:
space:
mode:
authorWilliam S Fulton <wsf@fultondesigns.co.uk>2015-12-29 19:10:57 +0000
committerWilliam S Fulton <wsf@fultondesigns.co.uk>2015-12-30 22:22:33 +0000
commit3763beb4898b89eb7021fcd4427d2944cd9bc575 (patch)
treea17f3ee4f1cc85e94b9ad39b654acb810c5cb489 /Doc/Manual/Introduction.html
parent4e67d5c7a810048d9024a699a4d5d676f5a69b82 (diff)
downloadswig-3763beb4898b89eb7021fcd4427d2944cd9bc575.tar.gz
Replace tabs with spaces in html docs
wkhtmltopdf is not expanding tabs within <pre> elements to 8 spaces as it should. Workaround the problem by converting all tabs to an appropriate number of spaces.
Diffstat (limited to 'Doc/Manual/Introduction.html')
-rw-r--r--Doc/Manual/Introduction.html19
1 files changed, 10 insertions, 9 deletions
diff --git a/Doc/Manual/Introduction.html b/Doc/Manual/Introduction.html
index 677784d9a..1c29f4760 100644
--- a/Doc/Manual/Introduction.html
+++ b/Doc/Manual/Introduction.html
@@ -158,14 +158,16 @@ following C code:
double My_variable = 3.0;
/* Compute factorial of n */
-int fact(int n) {
- if (n &lt;= 1) return 1;
- else return n*fact(n-1);
+int fact(int n) {
+ if (n &lt;= 1)
+ return 1;
+ else
+ return n*fact(n-1);
}
/* Compute n mod m */
int my_mod(int n, int m) {
- return(n % m);
+ return(n % m);
}
</pre></div>
@@ -222,8 +224,7 @@ unix &gt; <b>tclsh</b>
7.5
%
</pre></div>
- <p>
-
+<p>
The <tt>swig</tt> command produced a new file called
<tt>example_wrap.c</tt> that should be compiled along with the
<tt>example.c</tt> file. Most operating systems and scripting
@@ -245,8 +246,8 @@ any changes type the following (shown for Solaris):
<div class="shell"><pre>
unix &gt; <b>swig -perl5 example.i</b>
unix &gt; <b>gcc -c example.c example_wrap.c \
- -I/usr/local/lib/perl5/sun4-solaris/5.003/CORE</b>
-unix &gt; <b>ld -G example.o example_wrap.o -o example.so</b> # This is for Solaris
+ -I/usr/local/lib/perl5/sun4-solaris/5.003/CORE</b>
+unix &gt; <b>ld -G example.o example_wrap.o -o example.so</b> # This is for Solaris
unix &gt; <b>perl5.003
use example;
print example::fact(4), "\n";
@@ -297,7 +298,7 @@ SWIG on the C header file and specifying a module name as follows
<div class="shell"><pre>
unix &gt; <b>swig -perl5 -module example example.h</b>
unix &gt; <b>gcc -c example.c example_wrap.c \
- -I/usr/local/lib/perl5/sun4-solaris/5.003/CORE</b>
+ -I/usr/local/lib/perl5/sun4-solaris/5.003/CORE</b>
unix &gt; <b>ld -G example.o example_wrap.o -o example.so</b>
unix &gt; <b>perl5.003
use example;