From 766b4b6aa046fc125fd42561a6cafc4fe82ee3ad Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Wed, 20 Aug 2014 18:42:17 -0400 Subject: v5 v6: texpdf, output, copyright & license --- lib/sisu/v6/dp.rb | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'lib/sisu/v6/dp.rb') diff --git a/lib/sisu/v6/dp.rb b/lib/sisu/v6/dp.rb index 50317108..111896d7 100644 --- a/lib/sisu/v6/dp.rb +++ b/lib/sisu/v6/dp.rb @@ -583,6 +583,34 @@ module SiSU_Param def sep(str) ' \\\\ ' end + def copyright_and_license + s=if @h['all'] then @h['all'] + else + s='' + if defined? copyright.text \ + and copyright.text \ + and not copyright.text.empty? + v=sep(copyright.text) + s +=copyright.text + v + end + if defined? copyright.license \ + and copyright.license \ + and not copyright.license.empty? + s +=copyright.license + end + if s.empty? + SiSU_Screen::Ansi.new( + @opt.act[:color_state][:set], + 'WARNING Document Rights information missing; provide @rights: :copyright:' + ).warn unless @opt.act[:quiet][:set]==:on + else + l,n=Db[:col_info_note],'rights.all' + validate_length(s,l,n) + end + s=s.gsub(/ [\\]+\s+$/,'') + end + s + end def all s=if @h['all'] then @h['all'] else -- cgit v1.2.3