diff options
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/sisu/v3/digests.rb | 4 | ||||
| -rw-r--r-- | lib/sisu/v3/epub.rb | 5 | ||||
| -rw-r--r-- | lib/sisu/v3/git.rb | 2 | ||||
| -rw-r--r-- | lib/sisu/v3/html.rb | 11 | ||||
| -rw-r--r-- | lib/sisu/v3/html_format.rb | 12 | ||||
| -rw-r--r-- | lib/sisu/v3/manifest.rb | 8 | ||||
| -rw-r--r-- | lib/sisu/v3/odf.rb | 4 | ||||
| -rw-r--r-- | lib/sisu/v3/plaintext.rb | 4 | ||||
| -rw-r--r-- | lib/sisu/v3/sysenv.rb | 210 | ||||
| -rw-r--r-- | lib/sisu/v3/texpdf.rb | 16 | ||||
| -rw-r--r-- | lib/sisu/v3/urls.rb | 99 | ||||
| -rw-r--r-- | lib/sisu/v3/xhtml.rb | 11 | ||||
| -rw-r--r-- | lib/sisu/v3/xml.rb | 10 | ||||
| -rw-r--r-- | lib/sisu/v3/xml_dom.rb | 10 | 
14 files changed, 244 insertions, 162 deletions
| diff --git a/lib/sisu/v3/digests.rb b/lib/sisu/v3/digests.rb index 38b79ae1..26e91528 100644 --- a/lib/sisu/v3/digests.rb +++ b/lib/sisu/v3/digests.rb @@ -76,12 +76,12 @@ module SiSU_Digest_view          @env,@md,@dal_array=@particulars.env,@particulars.md,@particulars.dal_array          unless @opt.cmd =~/q/            tool=(@opt.cmd =~/[MVv]/) \ -          ? "#{@env.program.text_editor} #{@env.path.output_tell}/#{@md.fnb}/#{@md.fn[:digest]}" \ +          ? "#{@env.program.text_editor} file://#{@md.file.output_path.hash_digest}/#{@md.file.base_filename.hash_digest}" \            : @opt.fns            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,"Document #{@dg} Digests",tool).green_hi_blue \            : SiSU_Screen::Ansi.new(@opt.cmd,"Document #{@dg} Digests",tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@env.path.output_tell}/#{@md.fnb}/#{@md.fn[:digest]}").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"file://#{@md.file.output_path.hash_digest}/#{@md.file.base_filename.hash_digest}").flow if @opt.cmd =~/[MV]/          end          SiSU_Digest_view::Source::Scroll.new(@particulars).songsheet          SiSU_Env::Info_skin.new(@md).select diff --git a/lib/sisu/v3/epub.rb b/lib/sisu/v3/epub.rb index 0da90712..22c42980 100644 --- a/lib/sisu/v3/epub.rb +++ b/lib/sisu/v3/epub.rb @@ -85,14 +85,13 @@ module SiSU_EPUB          @env=@particulars.env          loc=@env.path.url.output_tell          unless @opt.cmd =~/q/ -          tool=if @opt.cmd =~/z/;   "#{@env.program.epub_viewer} #{loc}/epub/#{@fnb}.epub" -          elsif @opt.cmd =~/[MVv]/; "#{@env.program.epub_viewer} #{loc}/epub/#{@fnb}.epub" +          tool=if @opt.cmd =~/[MVvz]/; "#{@env.program.epub_viewer} #{@md.file.output_path.epub}/#{@md.file.base_filename.epub}"            else                      @opt.fns            end            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'EPUB',tool).green_hi_blue \            : SiSU_Screen::Ansi.new(@opt.cmd,'EPUB',tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{loc}/epub/#{@fnb}.epub").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@md.file.output_path.epub}/#{@md.file.base_filename.epub}").flow if @opt.cmd =~/[MV]/          end          @env.path.epub_bld #(@md)          @env.path.epub_cp_images(@md) diff --git a/lib/sisu/v3/git.rb b/lib/sisu/v3/git.rb index 00cd1e67..b14645c9 100644 --- a/lib/sisu/v3/git.rb +++ b/lib/sisu/v3/git.rb @@ -71,7 +71,7 @@ module SiSU_Git        unless @md.i18n[0]==l[:c]          p "using: #{@md.i18n[0]} (@make: :language:); filename #{@md.fns} filename language: #{l[:c]}, mismatch"        end -      if @env.multilingual? +      if @env.output_dir_structure.multilingual?          m=/((.+?)(?:\~\w{2,3})?)\.((?:-|ssm\.)?sst|ssm)$/ #watch added match for sss          fnn,fnb,fnt=@opt.fns[m,1],@opt.fns[m,2],@opt.fns[m,3]        else m=/(.+?)\.((?:-|ssm\.)?sst|ssm)$/ diff --git a/lib/sisu/v3/html.rb b/lib/sisu/v3/html.rb index ade1a801..bad68cde 100644 --- a/lib/sisu/v3/html.rb +++ b/lib/sisu/v3/html.rb @@ -87,14 +87,13 @@ module SiSU_HTML          @env=@particulars.env          loc=@env.url.output_tell          unless @opt.cmd =~/q/ -          tool=if @opt.cmd =~/z/;   "#{@env.program.web_browser} #{loc}/#{@fnb}/#{@md.fn[:index]}" -          elsif @opt.cmd =~/[MVv]/; "#{@env.program.web_browser} #{loc}/#{@fnb}/#{@md.fn[:index]}" -          else                      @opt.fns +          tool=if @opt.cmd =~/[MVvz]/; "#{@env.program.web_browser} file://#{@md.file.output_path.html_seg}/#{@md.file.base_filename.html_segtoc}" +          else                          @opt.fns            end            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'HTML',tool).green_hi_blue \            : SiSU_Screen::Ansi.new(@opt.cmd,'HTML',tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@env.path.output_tell}/#{@fnb}/#{@md.fn[:index]}").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"file://#{@md.file.output_path.html_seg}/#{@md.file.base_filename.html_segtoc}").flow if @opt.cmd =~/[MV]/          end          SiSU_Env::Info_skin.new(@md).select          data=nil @@ -422,8 +421,8 @@ WOK          p_num=SiSU_HTML_Format::Paragraph_number.new(@md,ocn) if ocn          @file=SiSU_Env::SiSU_file.new(@md) if @md          txt_obj=if seg_link=~/sisu_manifest\.html/ -          man_link=if @file.by_language? \ -          or @file.by_filetype? +          man_link=if @file.output_dir_structure.by_language_code? \ +          or @file.output_dir_structure.by_filetype?              seg_link.gsub(/sisu_manifest\.html/,"../../manifest/#{@file.base_filename.manifest}")            else seg_link            end diff --git a/lib/sisu/v3/html_format.rb b/lib/sisu/v3/html_format.rb index 15345ca0..76805234 100644 --- a/lib/sisu/v3/html_format.rb +++ b/lib/sisu/v3/html_format.rb @@ -187,8 +187,8 @@ module SiSU_HTML_Format        env.widget.search_form('sisusearch',nil,nil,true)      end      def manifest -      manifest_lnk=if @file.by_language? \ -      or @file.by_filetype? +      manifest_lnk=if @file.output_dir_structure.by_language_code? \ +      or @file.output_dir_structure.by_filetype?          "#{Xx[:html_relative1]}manifest/#{@file.base_filename.manifest}"        else @file.base_filename.manifest        end @@ -651,8 +651,8 @@ WOK        nxt="#{@md.fnl[:pre]}#{@seg_name_html[@seg_name_html_tracker+1]}#{@md.fnl[:mid]}#{Sfx[:html]}#{@md.fnl[:post]}"        if nxt=~/sisu_manifest\.html/          @file=SiSU_Env::SiSU_file.new(@md) if @md -        if @file.by_language? \ -        or @file.by_filetype? +        if @file.output_dir_structure.by_language_code? \ +        or @file.output_dir_structure.by_filetype?            nxt.gsub!(/sisu_manifest\.html/,"../../manifest/#{@file.base_filename.manifest}")          end        end @@ -713,8 +713,8 @@ WOK  </td>} if f_nxt==true        if nxt =~/sisu_manifest.html/          @file=SiSU_Env::SiSU_file.new(@md) if @md -        if @file.by_language? \ -        or @file.by_filetype? +        if @file.output_dir_structure.by_language_code? \ +        or @file.output_dir_structure.by_filetype?            nxt.gsub!(/sisu_manifest\.html/,"../../manifest/#{@file.base_filename.manifest}")          end        end diff --git a/lib/sisu/v3/manifest.rb b/lib/sisu/v3/manifest.rb index c9fb8e04..58b78c76 100644 --- a/lib/sisu/v3/manifest.rb +++ b/lib/sisu/v3/manifest.rb @@ -82,9 +82,9 @@ module SiSU_Manifest          SiSU_Env::Info_skin.new(@md).select          xbrowser=@env.program.web_browser          browser=@env.program.console_web_browser -        webserv_url=@env.path.url.output_tell +#       webserv_url=@env.path.url.output_tell #fix in sysenv          unless @opt.cmd =~/q/ -          url_html="#{webserv_url}/#{@md.fnb}/#{@md.fn[:manifest]}" +          url_html="file://#{@md.file.output_path.manifest}/#{@md.file.base_filename.manifest}"            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'Manifest',"#{xbrowser} #{url_html}").green_hi_blue \            : SiSU_Screen::Ansi.new(@opt.cmd,'Manifest',@opt.fns).green_title_hi @@ -646,8 +646,8 @@ SiSU manifest: #{@md.title.full}  #{banner_table}  WOK            if @env.manifest_minitoc? -            if @env.by_language? \ -            or @env.by_filetype? +            if @env.output_dir_structure.by_language_code? \ +            or @env.output_dir_structure.by_filetype?                minitoc.gsub!(/<a href="(\S+?)"/m,%{<a href="../html/#{@md.fnb}/\\1"})                minitoc.gsub!(/<a href="\.\.\/html\/#{@md.fnb}\/(?:sisu_manifest\.html|#{@md.file.base_filename.manifest})"/m,                %{<a href="#{@md.file.base_filename.manifest}"}) diff --git a/lib/sisu/v3/odf.rb b/lib/sisu/v3/odf.rb index 8a1c5322..ce696fdd 100644 --- a/lib/sisu/v3/odf.rb +++ b/lib/sisu/v3/odf.rb @@ -86,12 +86,12 @@ module SiSU_ODF          path=@env.path.output_tell          unless @opt.cmd =~/q/            tool=(@opt.cmd =~/[MVv]/) \ -          ? "#{@env.program.odf_viewer} #{path}/#{@md.fnb}/#{opendoc}" \ +          ? "#{@env.program.odf_viewer} file://#{@md.file.output_path.odt}/#{@md.file.base_filename.odt}" \            : @opt.fns            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'Opendocument (ODF:ODT)',tool).green_hi_blue \            : SiSU_Screen::Ansi.new(@opt.cmd,'Opendocument (ODF:ODT)',tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@env.path.output_tell}/#{@md.fnb}/#{opendoc}").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"file://#{@md.file.output_path.odt}/#{@md.file.base_filename.odt}").flow if @opt.cmd =~/[MV]/          end          SiSU_ODF::Source::Scroll.new(@particulars).songsheet          SiSU_Env::Info_skin.new(@md).select diff --git a/lib/sisu/v3/plaintext.rb b/lib/sisu/v3/plaintext.rb index 004705f3..8b910642 100644 --- a/lib/sisu/v3/plaintext.rb +++ b/lib/sisu/v3/plaintext.rb @@ -84,12 +84,12 @@ module SiSU_Plaintext          unless @opt.cmd =~/q/            path=env.path.output_tell            tool=(@opt.cmd =~/[MVv]/) \ -          ? "#{env.program.text_editor} #{path}/#{md.fnb}/#{md.fn[:plain]}" \ +          ? "#{env.program.text_editor} #{md.file.output_path.txt}/#{md.file.base_filename.txt}" \            : @opt.fns            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'Plaintext',tool).green_hi_blue \            : SiSU_Screen::Ansi.new(@opt.cmd,'Plaintext',tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{path}/#{md.fnb}/#{md.fn[:plain]}").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{md.file.output_path.txt}/#{md.file.base_filename.txt}").flow if @opt.cmd =~/[MV]/          end          dal_array=SiSU_DAL::Source.new(@opt).get # dal file drawn here          wrap_width=if defined? md.make.plaintext_wrap \ diff --git a/lib/sisu/v3/sysenv.rb b/lib/sisu/v3/sysenv.rb index 00e3f030..a7105d69 100644 --- a/lib/sisu/v3/sysenv.rb +++ b/lib/sisu/v3/sysenv.rb @@ -399,30 +399,56 @@ module SiSU_Env        end        @fnn,@fnb,@fnt,@flv,@fnz=@@fnn,@@fnb,@@fnt,@@flv,@@fnz      end -    def by_language? -      x=(defined? @rc['output_structure']['by_language'] \ -      && @rc['output_structure']['by_language'] ==true) \ -      ? @rc['output_structure']['by_language'] \ -      : false -    end -    def by_filetype? -      x=if by_language? -        true -      else -        x=(defined? @rc['output_structure']['by_filetype'] \ -        && @rc['output_structure']['by_filetype'] ==true) \ -        ? @rc['output_structure']['by_filetype'] \ -        : false +    def output_dir_structure +      def by_language_code? +        x=if defined? @rc['output_dir_structure_by'] \ +        and @rc['output_dir_structure_by'] =~/language/ +          true +        else defined? @rc['output_structure']['by_language'] +          (defined? @rc['output_structure']['by_language'] \ +          && @rc['output_structure']['by_language'] ==true) \ +          ? true \ +          : false +        end        end -    end -    def multilingual? -      by_language? +      def by_filetype? +        x=if by_language_code? +          false +        elsif defined? @rc['output_dir_structure_by'] \ +        and @rc['output_dir_structure_by'] =~/filetype/ +          true +        else +          x=(defined? @rc['output_structure']['by_filetype'] \ +          && @rc['output_structure']['by_filetype'] ==true) \ +          ? true \ +          : false +        end +      end +      def by_filename? +        x=if by_language_code? +          false +        elsif by_filetype? +          false +        elsif defined? @rc['output_dir_structure_by'] \ +        and @rc['output_dir_structure_by'] =~/filename/ +          true +        elsif defined? @rc['output_structure']['by_filename'] \ +        and @rc['output_structure']['by_filename'] ==true +          true +        else +          true +        end +      end +      def multilingual? +        by_language_code? +      end +      self      end      def document_language_versions_found        @fn={}        unless (@fns.nil? \        or @fns.empty?) -        if multilingual? +        if output_dir_structure.by_language_code?            m=/((.+?)(?:\~\w{2,3})?)\.((?:-|ssm\.)?sst$)/            @fn[:b],@fn[:m],@fn[:t]=@fns[m,1],@fns[m,2],@fns[m,3]          else m=/(.+?)\.((?:-|ssm\.)?sst$)/ @@ -453,7 +479,7 @@ module SiSU_Env        @m=[]        unless (@fns.nil? \        or @fns.empty?) -        if multilingual? +        if output_dir_structure.by_language_code?            m=/((.+?)(?:\~\w{2,3})?)\.((?:-|ssm\.)?sst$)/            @fn[:b],@fn[:m],@fn[:t]=@fns[m,1],@fns[m,2],@fns[m,3]          else m=/(.+?)\.((?:-|ssm\.)?sst$)/ @@ -1909,7 +1935,7 @@ WOK          else %{(SiSU (generated sample) search form}          end        end -      def output_tell +      def output_tell                                      #BROKEN Revisit 2011-02          output_type=if defined? @rc['show_output_on'] \          and @rc['show_output_on'] =~/^(?:filesystem|webserv|(?:local|remote)(?:_webserv)?|webrick)/            @rc['show_output_on'] @@ -2068,7 +2094,7 @@ WOK          ((defined? @rc['program_select']['odf_viewer']) \          && @rc['program_select']['odf_viewer'] =~/\S\S+/) \          ? @rc['program_select']['odf_viewer'] \ -        : 'oowriter'                                                          #'odf-viewer','oowriter' +        : 'libreoffice'                                                        #'odf-viewer','oowriter'        end        def manpage_viewer          'man' @@ -2136,7 +2162,7 @@ WOK        #end        def lang_filename(l)          @lang={} -        x=if multilingual? +        x=if output_dir_structure.by_language_code?            (( defined? @rc['default']['language_file']) \            && @rc['default']['language_file'] != nil) \            ? @rc['default']['language_file'] \ @@ -2270,7 +2296,7 @@ WOK        ft=[]        if @md \        and defined? @md.fn \ -      and @md.fn        # used for multilingual? +      and @md.fn        # used for by_language_code?          if @md.cmd =~ /[hH]/            ft << @md.fn[:html]          end @@ -2850,63 +2876,72 @@ WOK      end      def path_rel_links        def html_scroll_2 -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            '../../' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            '../'          else            '../'          end        end        def html_seg_2 -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            '../../../' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            '../../'          else            '../../'          end        end        def html_scroll_1 -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            '../' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            '../'          else            '/'          end        end        def html_seg_1 -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            '../../' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            '../../'          else            '/'          end        end -      def html_scroll_css -        if @env.multilingual? +      def default_output_css +        if @env.output_dir_structure.by_language_code?            '../../' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            '../'          else            '../'          end        end +      def html_scroll_css +        default_output_css +      end +      def xhtml_css +        default_output_css +      end +      def xml_css +        default_output_css +      end        def html_seg_css -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            '../../../' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            '../../'          else            '../'          end        end        def manifest_css -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            '../../_sisu/css' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            ''          else            '../' @@ -2935,14 +2970,21 @@ WOK        ensure        end      end -    def by_language? -      @env.by_language? -    end -    def by_filetype? -      @env.by_filetype? -    end -    def multilingual? -      by_language? +    def output_dir_structure +      def by_language_code? +        @env.output_dir_structure.by_language_code? +      end +      def by_filetype? +        @env.output_dir_structure.by_filetype? +      end +      def by_filename? +        @env.output_dir_structure.by_filename? +      end +      def multilingual? +        @env.output_dir_structure.by_language_code? +        #by_language_code? +      end +      self      end      def mkdir_initialize                                                       # not used but consider using        mkdir_p(output_path.base) unless FileTest.directory?(output_path.base) @@ -3122,9 +3164,9 @@ WOK      end      def base_filename        def txt -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.txt' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + @md.fn[:plain]          else            'plain' + @md.fn[:plain] @@ -3132,9 +3174,9 @@ WOK        end        def html_scroll          #"#{@md.fnl[:pre]}scroll#{@md.fnl[:mid]}.html#{@md.fnl[:post]}" -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.html' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + @md.fn[:html]          else            'scroll' + @md.fn[:html] @@ -3142,7 +3184,7 @@ WOK        end        def html_seg_index          #"#{@md.fnl[:pre]}index#{@md.fnl[:mid]}.html#{@md.fnl[:post]}" -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            'toc.html'          else            'index' + @md.fn[:html] @@ -3150,37 +3192,37 @@ WOK        end        def html_segtoc          #"#{@md.fnl[:pre]}toc#{@md.fnl[:mid]}.html#{@md.fnl[:post]}" -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            'toc.html'          else            'toc' + @md.fn[:html]          end        end        def html_book_index -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            'book_index.html'          else            'book_index.' + @md.fn[:html]          end        end        def html_concordance -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            'concordance.html'          else            'concordance' + @md.fn[:html]          end        end        def xhtml -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.xhtml' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + '.' + @md.fn[:xhtml]          else            'scroll.' + @md.fn[:xhtml]          end        end        def epub -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.epub'          else            @md.fnb + @md.fn[:epub] @@ -3188,42 +3230,42 @@ WOK        end        def odt          #"#{@md.fnl[:pre]}#{@md.fnb}#{@md.fnl[:mid]}.odt#{@md.fnl[:post]}" -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.odt' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + @md.fn[:odf]          else            'opendocument' + @md.fn[:odf]          end        end        def xml_sax -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.sax.xml' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + '.' + @md.fn[:sax]          else            'scroll.' + @md.fn[:sax]          end        end        def xml_dom -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.dom.xml' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + '.' + @md.fn[:dom]          else            'scroll.' + @md.fn[:dom]          end        end        def pdf_p -        if @env.multilingual? \ -        or @env.by_filetype? +        if @env.output_dir_structure.by_language_code? \ +        or @env.output_dir_structure.by_filetype?            @md.fnb + '.portrait.'          else 'portrait.'          end        end        def pdf_l -        if @env.multilingual? \ -        or @env.by_filetype? +        if @env.output_dir_structure.by_language_code? \ +        or @env.output_dir_structure.by_filetype?            @md.fnb + '.landscape.'          else 'landscape.'          end @@ -3259,34 +3301,34 @@ WOK          pdf_l + @md.fn[:pdf_l_legal]        end        def manpage -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.1'          else            @md.fnb + '.' + @md.fn[:manpage]          end        end        def hash_digest -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.hash_digest.txt' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + '.' + @md.fn[:digest]          else            'digest.' + @md.fn[:digest]          end        end        def sitemap -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.sitemap.xml' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + '.' + @md.fn[:sitemap]          else            'sitemap.' + @md.fn[:sitemap]          end        end        def manifest -        if @env.multilingual? +        if @env.output_dir_structure.by_language_code?            @md.fnb + '.manifest.html' -        elsif @env.by_filetype? +        elsif @env.output_dir_structure.by_filetype?            @md.fnb + '.' + @md.fn[:manifest]          else            'sisu_' + @md.fn[:manifest] @@ -3319,23 +3361,23 @@ WOK        : @md.i18n[0]      end      def set_path_abc(ft) -      if @env.multilingual? +      if @env.output_dir_structure.by_language_code?          "#{output_path.base}/#{lang_part}/#{ft}" -      elsif @env.by_filetype? +      elsif @env.output_dir_structure.by_filetype?          "#{output_path.base}/#{ft}"        else          "#{output_path.base}/#{@md.fnb}"        end      end      def set_path_ab(ft) -      if @env.multilingual? +      if @env.output_dir_structure.by_language_code?          "#{output_path.base}/#{lang_part}/#{ft}"        else          "#{output_path.base}/#{ft}"        end      end      def set_path_ab_src(ft) -      if @env.multilingual? +      if @env.output_dir_structure.by_language_code?          "#{output_path.base}/#{ft}/#{lang_part}"        else          "#{output_path.base}/#{ft}" @@ -3844,6 +3886,18 @@ WOK      def xhtml_epub        %{  <link rel="stylesheet" href="css/xhtml.css" type="text/css" />}      end +    def epub +      xhtml_epub +    end +    def xhtml +      %{<?xml-stylesheet type="text/css" href="#{@file.path_rel_links.xhtml_css}#{@env.path.style}/#{@css.xhtml}"?>} +    end +    def xml_sax +      %{<?xml-stylesheet type="text/css" href="#{@file.path_rel_links.xml_css}#{@env.path.style}/#{@css.xml_sax}"?>} +    end +    def xml_dom +      %{<?xml-stylesheet type="text/css" href="#{@file.path_rel_links.xml_css}#{@env.path.style}/#{@css.xml_dom}"?>} +    end    end    class Create_site < Info_env      require "#{SiSU_lib}/css"                              # css.rb diff --git a/lib/sisu/v3/texpdf.rb b/lib/sisu/v3/texpdf.rb index 8b0ba8c6..e0646603 100644 --- a/lib/sisu/v3/texpdf.rb +++ b/lib/sisu/v3/texpdf.rb @@ -106,13 +106,13 @@ module SiSU_TeX          SiSU_Screen::Ansi.new(@opt.cmd,'LaTeX/PDF',@md.fns).green_title_hi unless @opt.cmd =~/q/          if @opt.cmd =~/[MVv]/            path=@env.url.output_tell -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@env.program.pdf_viewer} #{path}/#{@md.fnb}/#{@md.fn[:pdf_l]}").flow -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@env.program.pdf_viewer} #{path}/#{@md.fnb}/#{@md.fn[:pdf_p]}").flow +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@env.program.pdf_viewer} #{@md.file.output_path.pdf}/#{@md.file.base_filename.pdf_l}pdf").flow +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{@env.program.pdf_viewer} #{@md.file.output_path.pdf}/#{@md.file.base_filename.pdf_p}pdf").flow          end          @md=@particulars.md -        $flag=@md.cmd                                                         #introduced to pass 0 for no object citation numbers... to texpdf_format +        $flag=@md.cmd                                                          #introduced to pass 0 for no object citation numbers... to texpdf_format          directories -                                                                             #% needed needs to be reprogrammed !!! +                                                                               #% needed needs to be reprogrammed !!!          SiSU_Env::Info_skin.new(@md).select          dal_array=SiSU_DAL::Source.new(@opt).get # dal file drawn here          SiSU_TeX::Source::LaTeX_create.new(@particulars).songsheet @@ -231,8 +231,8 @@ module SiSU_TeX              else           pdf_p=@md.file.base_filename.pdf_p_a4;     pdf_l=@md.file.base_filename.pdf_l_a4              end              if FileTest.file?("#{@md.file.output_path.pdf}/#{pdf_p}") -              mklnk=if @md.file.by_language? \ -              or @md.file.by_filetype? +              mklnk=if @md.file.output_dir_structure.by_language_code? \ +              or @md.file.output_dir_structure.by_filetype?                  "#{@md.fnb}.portrait.pdf"                else 'portrait.pdf'                end @@ -243,8 +243,8 @@ module SiSU_TeX                ")              end              if FileTest.file?("#{@md.file.output_path.pdf}/#{pdf_l}") -              mklnk=if @md.file.by_language? \ -              or @md.file.by_filetype? +              mklnk=if @md.file.output_dir_structure.by_language_code? \ +              or @md.file.output_dir_structure.by_filetype?                  "#{@md.fnb}.landscape.pdf"                else 'landscape.pdf'                end diff --git a/lib/sisu/v3/urls.rb b/lib/sisu/v3/urls.rb index c2b694a2..5cc69e7b 100644 --- a/lib/sisu/v3/urls.rb +++ b/lib/sisu/v3/urls.rb @@ -192,54 +192,54 @@ module SiSU_urls          @u.each do |x,y|            if @opt.fns =~ @m_regular              if @opt.cmd =~/[MVv]/ -              if x=~/^([bcNwxXY])/ \ -              and @opt.cmd=~/[bcNwxXY]/ \ -              and x=~/^[#{@opt.cmd}]/ -                m=$1 -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} #{@env.url.output_tell}/#{@fnb}/#{y}").result +              if (x=~/^a/ and @opt.cmd =~/a/) \ +              or (x=~/^t/ and @opt.cmd =~/t/) +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.txt}/#{@md.file.base_filename.txt}").result                end -              if x=~/^[y]/ \ -              and @opt.cmd =~/[y]/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.manifest}/#{@md.file.base_filename.manifest}").result +              if x=~/^b/ \ +              and @opt.cmd =~/b/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.xhtml}/#{@md.file.base_filename.xhtml}").result                end -              if x=~/^[at]/ \ -              and @opt.cmd =~/[at]/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.txt}/#{@md.file.base_filename.txt}").result +#              if x=~/^[c]/ \ +#              and @opt.cmd =~/[c]/ +#                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.manifest}/#{@md.file.base_filename.manifest}").result +#              end +              if x=~/^D/ \ +              and @opt.cmd =~/D/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x} DBI psql","#{@pwd_stub}::#{@opt.fns}",y).result                end -              if x=~/^h/ \ -              and @opt.cmd =~/h/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.html_scroll}/#{@md.file.base_filename.html_scroll}").result -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.html_seg}/#{@md.file.base_filename.html_segtoc}").result +              if x=~/^d/ \ +              and @opt.cmd =~/d/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x} DBI sqlite","sqlite3 #{@env.path.output}/sisu_sqlite.db", "#{y}").result                end                if x=~/^e/ \                and @opt.cmd =~/e/                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.epub_viewer} #{@md.file.output_path.epub}/#{@md.file.base_filename.epub}").result                end -              if x=~/^o/ \ -              and @opt.cmd =~/o/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.odf_viewer} file://#{@md.file.output_path.odt}/#{@md.file.base_filename.odt}").result -              end -              if x=~/^p/ \ -              and @opt.cmd =~/p/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.pdf_viewer} #{@md.file.output_path.pdf}/#{@md.file.base_filename.pdf_p}pdf").result -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.pdf_viewer} #{@md.file.output_path.pdf}/#{@md.file.base_filename.pdf_l}pdf").result +              if x=~/^h/ \ +              and @opt.cmd =~/h/ +                if x =~/scroll/ +                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.html_scroll}/#{@md.file.base_filename.html_scroll}").result +                else +                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.html_seg}/#{@md.file.base_filename.html_segtoc}").result +                end                end                if x=~/^I/ \                and @opt.cmd =~/I/                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","cd #{@env.path.texinfo}; pinfo ./#{@fnb}.#{y}; cd -").result                end -              if x=~/^D/ \ -              and @opt.cmd =~/D/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x} DBI psql","#{@pwd_stub}::#{@opt.fns}",y).result -              end -              if x=~/^d/ \ -              and @opt.cmd =~/d/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x} DBI sqlite","sqlite3 #{@env.path.output}/sisu_sqlite.db", "#{y}").result -              end                if x=~/^i/ \                and @opt.cmd =~/i/                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.manpage_viewer} #{@env.path.manpage}/#{@fnb}.1").result                end +              if x=~/^N/ \ +              and @opt.cmd =~/N/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.hash_digest}/#{@md.file.base_filename.hash_digest}").result +              end +              if x=~/^o/ \ +              and @opt.cmd =~/o/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.odf_viewer} file://#{@md.file.output_path.odt}/#{@md.file.base_filename.odt}").result +              end                if x=~/^P/ \                and @opt.cmd =~/P/                  if @opt.fns =~/\S+?~\S{2}(?:_\S{2})?\.ss[mt]/ @@ -250,15 +250,19 @@ module SiSU_urls                  end                  #@opt.cmd.gsub!(/P/,'')                end +              if x=~/^p/ \ +              and @opt.cmd =~/p/ +                if x =~/portrait/ +                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.pdf_viewer} #{@md.file.output_path.pdf}/#{@md.file.base_filename.pdf_p}pdf").result +                else +                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.pdf_viewer} #{@md.file.output_path.pdf}/#{@md.file.base_filename.pdf_l}pdf").result +                end +              end                #if x=~/^P/ \                #and @opt.cmd =~/P/                #  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x} Profile","#{@pwd_stub}::#{@opt.fns}",y).result                #  @opt.cmd.gsub!(/P/,'')                #end -              if x=~/^s/ \ -              and @opt.cmd =~/s/ -                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.text_editor} #{@md.file.output_path.src}/#{y}").result -              end                if x=~/^S/ \                and @opt.cmd =~/S/                  zipfile=if @opt.fns =~/\.ssm\.sst$/; y.gsub(/(?:\~\S{2,3})?(\.ssm\.sst\.zip)$/,'.ssm.zip') @@ -266,6 +270,31 @@ module SiSU_urls                  end                  SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} #{@env.url.output_tell}/pod/#{y}").result                end +              if x=~/^s/ \ +              and @opt.cmd =~/s/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.text_editor} #{@md.file.output_path.src}/#{y}").result +              end +              if x=~/^w/ \ +              and @opt.cmd =~/w/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.html_concordance}/#{@md.file.base_filename.html_concordance}").result +              end +              if x=~/^X/ \ +              and @opt.cmd =~/X/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.xml_dom}/#{@md.file.base_filename.xml_dom}").result +              end +              if x=~/^x/ \ +              and @opt.cmd =~/x/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.xml_sax}/#{@md.file.base_filename.xml_sax}").result +              end +              if x=~/^Y/ \ +              and @opt.cmd =~/Y/ #BROKEN +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.sitemap}/#{@md.file.base_filename.sitemap}").result +              end + +              if x=~/^y/ \ +              and @opt.cmd =~/y/ +                SiSU_Screen::Ansi.new(@opt.cmd,"-#{x}","#{@prog.web_browser} file://#{@md.file.output_path.manifest}/#{@md.file.base_filename.manifest}").result +              end              end              urls_maintenance(@opt,x,y) if @opt.cmd =~/[MV]/            end diff --git a/lib/sisu/v3/xhtml.rb b/lib/sisu/v3/xhtml.rb index 94243c48..b1855653 100644 --- a/lib/sisu/v3/xhtml.rb +++ b/lib/sisu/v3/xhtml.rb @@ -83,14 +83,15 @@ module SiSU_XHTML          unless @opt.cmd =~/q/            path=@env.path.output_tell            loc=@env.url.output_tell -          tool=if @opt.cmd =~/[MV]/; "#{@env.program.web_browser} #{loc}/#{@md.fnb}/#{@md.fn[:xhtml]}\n\t#{@env.program.xml_viewer} #{path}/#{@md.fnb}/#{@md.fn[:xhtml]}" -          elsif @opt.cmd =~/v/; "#{@env.program.web_browser} #{loc}/#{@md.fnb}/#{@md.fn[:xhtml]}" + +          tool=if @opt.cmd =~/[MV]/; "#{@env.program.web_browser} file://#{@md.file.output_path.xhtml}/#{@md.file.base_filename.xhtml}#{path}/#{@md.fnb}/#{@md.fn[:xhtml]}\n\t#{@env.program.xml_viewer} file://#{@md.file.output_path.xhtml}/#{@md.file.base_filename.xhtml}#{path}/#{@md.fnb}/#{@md.fn[:xhtml]}" +          elsif @opt.cmd =~/v/; "#{@env.program.web_browser} file://#{@md.file.output_path.xhtml}/#{@md.file.base_filename.xhtml}"            else @opt.fns            end            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'invert','XHTML',tool).colorize \            : SiSU_Screen::Ansi.new(@opt.cmd,'XHTML',tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{path}/#{@md.fnb}/#{@md.fn[:xhtml]}").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"/#{@md.file.output_path.xhtml}/#{@md.file.base_filename.xhtml}").flow if @opt.cmd =~/[MV]/          end          SiSU_XHTML::Source::Songsheet.new(@particulars).song        rescue; SiSU_Errors::Info_error.new($!,$@,@opt.cmd,@opt.fns).error @@ -352,11 +353,11 @@ WOK          rdf=SiSU_XML_tags::RDF.new(@md)          dir=SiSU_Env::Info_env.new          @@xml[:head],@@xml[:body]=[],[] -        css=SiSU_Env::CSS_select.new(@md).xhtml +        css=SiSU_Env::CSS_stylesheet.new(@md)          encoding=(@sys.locale =~/utf-?8/i) ? '<?xml version="1.0" encoding="UTF-8" standalone="no"?>' : '<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>'          @@xml[:open] =<<WOK  #{encoding} -<?xml-stylesheet type="text/css" href="../#{@env.path.style}/#{css}"?> +#{css.xhtml}  #{rdf.comment_xml}  <document>  WOK diff --git a/lib/sisu/v3/xml.rb b/lib/sisu/v3/xml.rb index f0e62de9..a3767177 100644 --- a/lib/sisu/v3/xml.rb +++ b/lib/sisu/v3/xml.rb @@ -83,14 +83,14 @@ module SiSU_XML_SAX          unless @opt.cmd =~/q/            path=@env.path.output_tell            loc=@env.url.output_tell -          tool=if @opt.cmd =~/[MV]/; "#{@env.program.web_browser} #{loc}/#{@md.fnb}/#{@md.fn[:sax]}\n\t#{@env.program.xml_viewer} #{path}/#{@md.fnb}/#{@md.fn[:sax]}" -          elsif @opt.cmd =~/v/; "#{@env.program.web_browser} #{loc}/#{@md.fnb}/#{@md.fn[:sax]}" +          tool=if @opt.cmd =~/[MV]/; "#{@env.program.web_browser} file://#{@md.file.output_path.xml_sax}/#{@md.file.base_filename.xml_sax}\n\t#{@env.program.xml_viewer} file://#{@md.file.output_path.xml_sax}/#{@md.file.base_filename.xml_sax}" +          elsif @opt.cmd =~/v/; "#{@env.program.web_browser} file://#{@md.file.output_path.xml_sax}/#{@md.file.base_filename.xml_sax}"            else @opt.fns            end            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'invert','XML SAX',tool).colorize \            : SiSU_Screen::Ansi.new(@opt.cmd,'XML SAX',tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{path}/#{@md.fnb}/#{@md.fn[:sax]}").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"file://#{@md.file.output_path.xml_sax}/#{@md.file.base_filename.xml_sax}").flow if @opt.cmd =~/[MV]/          end          SiSU_XML_SAX::Source::Songsheet.new(@particulars).song        rescue; SiSU_Errors::Info_error.new($!,$@,@opt.cmd,@opt.fns).error @@ -392,13 +392,13 @@ WOK          rdf=SiSU_XML_tags::RDF.new(@md)          dir=SiSU_Env::Info_env.new          @@xml[:head],@@xml[:body]=[],[] -        css=SiSU_Env::CSS_select.new(@md).xml_sax +        css=SiSU_Env::CSS_stylesheet.new(@md)          encoding=if @sys.locale =~/utf-?8/i; '<?xml version="1.0" encoding="UTF-8" standalone="no"?>'          else                                 '<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>'          end          @@xml[:open] =<<WOK  #{encoding} -<?xml-stylesheet type="text/css" href="../#{dir.path.style}/#{css}"?> +#{css.xml_sax}  #{rdf.comment_xml}  <document>  WOK diff --git a/lib/sisu/v3/xml_dom.rb b/lib/sisu/v3/xml_dom.rb index b4feb949..726e48d5 100644 --- a/lib/sisu/v3/xml_dom.rb +++ b/lib/sisu/v3/xml_dom.rb @@ -81,14 +81,14 @@ module SiSU_XML_DOM          unless @opt.cmd =~/q/            path=@env.path.output_tell            loc=@env.url.output_tell -          tool=if @opt.cmd =~/[MV]/; "#{@env.program.web_browser} #{loc}/#{@md.fnb}/#{@md.fn[:dom]}\n\t#{@env.program.xml_viewer} #{path}/#{@md.fnb}/#{@md.fn[:dom]}" -          elsif @opt.cmd =~/v/; "#{@env.program.web_browser} #{loc}/#{@md.fnb}/#{@md.fn[:dom]}" +          tool=if @opt.cmd =~/[MV]/; "#{@env.program.web_browser}  file://#{@md.file.output_path.xml_dom}/#{@md.file.base_filename.xml_dom}\n\t#{@env.program.xml_viewer} file://#{@md.file.output_path.xml_dom}/#{@md.file.base_filename.xml_dom}" +          elsif @opt.cmd =~/v/; "#{@env.program.web_browser} file://#{@md.file.output_path.xml_dom}/#{@md.file.base_filename.xml_dom}"            else @opt.fns            end            @opt.cmd=~/[MVvz]/ \            ? SiSU_Screen::Ansi.new(@opt.cmd,'invert','XML DOM',tool).colorize \            : SiSU_Screen::Ansi.new(@opt.cmd,'XML DOM',tool).green_title_hi -          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"#{path}/#{@md.fnb}/#{@md.fn[:dom]}").flow if @opt.cmd =~/[MV]/ +          SiSU_Screen::Ansi.new(@opt.cmd,@opt.fns,"file://#{@md.file.output_path.xml_dom}/#{@md.file.base_filename.xml_dom}").flow if @opt.cmd =~/[MV]/          end          SiSU_XML_DOM::Source::Songsheet.new(@particulars).songsheet        rescue; SiSU_Errors::Info_error.new($!,$@,@opt.cmd,@opt.fns).error @@ -467,13 +467,13 @@ WOK        def pre          rdf=SiSU_XML_tags::RDF.new(@md)          dir=SiSU_Env::Info_env.new -        css=SiSU_Env::CSS_select.new(@md).xml_dom +        css=SiSU_Env::CSS_stylesheet.new(@md)          encoding=if @sys.locale =~/utf-?8/i; '<?xml version="1.0" encoding="UTF-8" standalone="no"?>'          else                                 '<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>'          end          @@xml[:open] =<<WOK  #{encoding} -<?xml-stylesheet type="text/css" href="../#{dir.path.style}/#{css}"?> +#{css.xml_dom}  #{rdf.comment_xml}  <document>  WOK | 
