aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v4/texpdf.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sisu/v4/texpdf.rb')
-rw-r--r--lib/sisu/v4/texpdf.rb18
1 files changed, 16 insertions, 2 deletions
diff --git a/lib/sisu/v4/texpdf.rb b/lib/sisu/v4/texpdf.rb
index c52b0641..f5c90cf5 100644
--- a/lib/sisu/v4/texpdf.rb
+++ b/lib/sisu/v4/texpdf.rb
@@ -731,8 +731,22 @@ WOK
else "\n\\author{#{@copymark} \\textnormal{#{author}}}"
end
end
- @tex_file << unless @md.fnb =~/^mail\s*$/; @tex_ml.site
- else '\date'
+ if defined? @md.make.cover_image \
+ and not @md.make.cover_image.nil? \
+ and @md.make.cover_image[:cover] =~/\S+/
+ x={}
+ dir=SiSU_Env::InfoEnv.new(@md.fns)
+ x[:l] =<<WOK
+\\titlepic{\\includegraphics[width=0.3\\textwidth]{#{dir.path.image_source_include}/#{@md.make.cover_image[:cover]}}}
+WOK
+ x[:p] =<<WOK
+\\titlepic{\\includegraphics[width=0.6\\textwidth]{#{dir.path.image_source_include}/#{@md.make.cover_image[:cover]}}}
+WOK
+ @tex_file << x
+ x=nil
+ end
+ @tex_file << unless @md.fnb =~/^mail\s*$/ then @tex_ml.site
+ else '\date'
end
@tex_file <<<<WOK
\\pagenumbering{roman}\\maketitle