Merge branch 'newspaper-layout'
jump to
@@ -1,43 +1,40 @@
h2. H3RALD Web Site -<span class="dropcap">T</span>his is a _minimalist_ web site: I do not care about fancy graphics or nitfy effects. I do care, however, about content and I want you to read what I write comfortably. As you can see, this site has no sidebars: it only has a header, a main column and a footer, exactly where you expect them to be. The source code of this site follows W3C's XHTML 1.1 and CSS 2.1 standard. - -As of version 8, h3rald.com is a completely static web site, except for a few AJAX calls. All the files are generated automatically thanks to the "Nanoc":http://nanoc.stoneship.org/ publishing system, an ingenious creation of "Denis Defreyne":http://www.stoneship.org/. Nanoc can be used to easily create static web sites using Ruby, as explained in "this article":http://www.h3rald.com/articles/creating-static-web-sites-with-nanoc. +H3RALD.com was created in 2004 by Fabio Cevasco, a technical writer, programmer and IT enthusiast. It features over a hundred "articles":/articles/ covering a wide range of topics, from programming to writing, productivity and even traveling. + +As of version 8, H3RALD.com is a completely static web site, except for a few AJAX calls. All the files are generated automatically thanks to the "nanoc":http://nanoc.stoneship.org/ publishing system, an ingenious creation of "Denis Defreyne":http://www.stoneship.org/. Nanoc can be used to easily create static web sites using Ruby, as explained in "this article":http://www.h3rald.com/articles/take-back-your-site-with-nanoc/. + + +h3. Licensing + +The "articles":/archives/ and all the content published on this web site is licensed under the _Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 United States License_. For other uses, please "contact us":/contact/. + +<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/"><img alt="Creative Commons License" src="http://i.creativecommons.org/l/by-nc-nd/3.0/us/88x31.png" /></a> + +The source code of this web site, such as its layout, SASS/CSS stylesheets, custom rake tasks and code is licensed under the terms of the <em><a href="http://creativecommons.org/licenses/MIT/">MIT License</a></em> and it is available on "GitHub":http://github.com/h3rald/h3rald. + h3. Requirements -The following ruby libraries (gems) have been used to create this web site: +The following ruby libraries (gems) are used to compile this web site: * *"nanoc":http://rubygems.org/gems/nanoc*, to generate the entire web site * *"extlib":http://rubygems.org/gems/extlib*, in some custom Rake tasks * *"bb-ruby":http://rubygems.org/gems/bb-ruby*, for the BBCode filter * *"builder":http://rubygems.org/gems/builder/*, to create RSS and ATOM feeds * *"haml":http://rubygems.org/gems/haml/*, for the SASS filter +* *"coderay":http://rubygems.org/gems/coderay/*, for syntax highlighting * *"glyph":http://rubygems.org/gems/glyph*, for the Glyph filter Additionally, the following gems were necessary to migrate from the previous version of this web site, powered by "Typo":http://www.typosphere.org: * *"mysql":http://rubyforge.org/projects/mysql/* * *"sequel":http://rubyforge.org/projects/sequel/* -Besides Ruby-related dependencies, the following was also necessary: - -* *"pygments":http://pygments.org/*, a Python library for code highlighting. -* *"prince":http://www.princexml.com*, a program to generate PDF files from HTML. -* A cron job to fetch backtype comments, delicious bookmarks, tweets, and github commits in JSON format and save them to the @/output/data@ folder. - -h3. Licensing - -My "articles":/archives/ and all content published on this web site is licensed under the <em>Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 United States License</em>. For other uses, contact me. - -<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/"><img alt="Creative Commons License" src="http://i.creativecommons.org/l/by-nc-nd/3.0/us/88x31.png" /></a> - -The source code of this web site, such as its layout, SASS/CSS stylesheets, Nanoc tasks and code is licensed under the terms of the <em><a href="http://creativecommons.org/licenses/BSD/">BSD License</a></em> and it is available on "GitHub":http://github.com/h3rald/h3rald. h3. Credits -I'd like to thank the following people for their work, which made this web site possible: +Special thanks to the following people, who made this web site possible: -* "Denis Defreyne":http://www.stoneship.org/, for creating the wonderful "Nanoc":http://nanoc.stoneship.org/ site publishing system. +* "Denis Defreyne":http://www.stoneship.org/, for creating the wonderful "nanoc":http://nanoc.stoneship.org/ site publishing system. * "David J.Perry":http://scholarsfonts.net/, who designed the "Cardo font":http://scholarsfonts.net/cardofnt.html I used for the H3RALD logo and the navigation buttons. -* The staff of "Archive.org":http://www.archive.org, for scanning the first edition of "A Complete Guide to Heraldry":http://www.archive.org/details/completeguidetoh00foxduoft, and making it available to the public. All the images featuring heraldic monsters are taken from this book. -As of version 8, h3rald.com is a completely static web site, except for a few AJAX calls. All the files are generated automatically thanks to the "Nanoc":http://nanoc.stoneship.org/ publishing system, an ingenious creation of "Denis Defreyne":http://www.stoneship.org/. Nanoc can be used to easily create static web sites using Ruby, as explained in "this article":http://www.h3rald.com/articles/creating-static-web-sites-with-nanoc. +* The creators of the free "Gentium":http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=gentium font, used throughout the web site.
@@ -1,34 +1,35 @@
#!/usr/bin/env ruby -compile /^\/archives\// do - rep.filter :erb +compile /^\/(archives|home)\// do + filter :erb layout 'default' end -compile /^\/(home|projects|about)/ do - rep.filter :erb - rep.filter :redcloth +compile /^\/(projects|about)/ do + filter :erb + filter :redcloth layout 'default' end compile /(rss|atom)/ do - rep.filter :erb + filter :erb unless rep.binary? # e.g. rss.png image end -compile '/css/*' do - filter :sass, { - :load_paths => [Dir.pwd+"/content/css"], - :full_exception => true, - :line_numbers => true - } -end +compile '/styles/_*/' do +end compile '/styles/*' do - # do nothing + if item[:extension] == "scss" && item.identifier.match(/style\/$/) then + filter :sass, { + :load_paths => [Dir.pwd+"/content/styles"], + :syntax => :scss, + :style => :compact + } + end end compile "sitemap" do - rep.filter :erb + filter :erb end compile /^\/(js\/.+?)/ do@@ -42,57 +43,26 @@
compile '*' do if item[:filters_pre] && !item[:filters_pre].empty? then item[:filters_pre].each do |f| - rep.filter f.to_sym + filter f.to_sym end layout 'default' else unless rep.binary? then case item[:extension] when 'textile' then - rep.filter :redcloth + filter :redcloth layout 'default' when 'md','markdown' then - rep.filter :bluecloth + filter :bluecloth layout 'default' when 'bbcode' then - rep.filter :bbcode + filter :bbcode layout 'default' when 'glyph' then pdf_file = Pathname.new "#{Dir.pwd}/output#{item.identifier.gsub(/\/$/, '')}.pdf" - unless pdf_file.exist? then - # Create the PDF file - f = Pathname.new "#{Dir.pwd}/output#{item.identifier.gsub(/\/$/, '')}.glyph" - f.parent.mkpath - doc = %{ - include[#{f.parent.parent.parent}/lib/data] - h3rald_article[ - @identifier[#{item.identifier}] - @content[section[#{item.raw_content}]] - ] - } - # Write the new raw file using Glyph's file_write method - file_write f, doc - # Now compile the PDF (works if Prince is installed) - target = Glyph['document.output'] - Glyph['document.output'] = 'pdf' - Glyph['document.author'] = "Fabio Cevasco" - Glyph['output.pdf.generator'] = "prince" - Glyph['site.root'] = ".." - Glyph['document.date'] = item[:date].strftime "%A, %d %B %Y" - Glyph['document.title'] = item[:title] - Glyph['document.subtitle'] = "" - Glyph.compile f.to_s - begin - f.unlink - Pathname.new(f.to_s.gsub(/\.glyph$/, '.html')).unlink - rescue - end - end - Glyph['site.root'] = "" - # Filter text rep - rep.filter :glyph - layout 'default' - Glyph.reset + glyph_config @item + glyph_pdf_for @item unless pdf_file.exist? + glyph_article_for @item end end end@@ -110,6 +80,10 @@ route '/css/*' do
item.identifier.chop + '.css' end +route '/styles/_*/' do + nil +end + route '/styles/*' do item.identifier.chop + '.css' end@@ -118,8 +92,16 @@ route '/glyph/book/' do
'/glyph/book/index.html' end +route '/glyph/book/images/glyph/*' do + item.identifier.chop + ".#{item[:extension]}" +end + route '/glyph/book/*' do item.identifier.chop+'.html' +end + +route '/home/' do + "/index.html" end route '/sitemap' do@@ -136,6 +118,10 @@ end
route '/js/*' do item.identifier.chop + '.js' +end + +route '/fonts/*' do + item.identifier.chop + '.ttf' end route '*' do
@@ -21,6 +21,7 @@ - xml
- textile - bbcode - glyph +- scss output_dir: output base_url: "http://www.h3rald.com" author_name: "Fabio Cevasco"
@@ -1,51 +1,43 @@
----- permalink: about -filters_pre: -- erb -- redcloth title: About type: page ----- -!>/images/theme/heraldry/unicorn.png! +H3RALD.com was created in 2004 by Fabio Cevasco, a technical writer, programmer and IT enthusiast. It features over a hundred "articles":/articles/ covering a wide range of topics, from programming to writing, productivity and even traveling. + +As of version 8, H3RALD.com is a completely static web site, except for a few AJAX calls. All the files are generated automatically thanks to the "nanoc":http://nanoc.stoneship.org/ publishing system, an ingenious creation of "Denis Defreyne":http://www.stoneship.org/. Nanoc can be used to easily create static web sites using Ruby, as explained in "this article":http://www.h3rald.com/articles/take-back-your-site-with-nanoc/. + + +h3. Licensing + +The "articles":/archives/ and all the content published on this web site is licensed under the _Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 United States License_. For other uses, please "contact us":/contact/. - <span class="dropcap">T</span>his is a _minimalist_ web site: I do not care about fancy graphics or nitfy effects. I do care, however, about content and I want you to read what I write comfortably. As you can see, this site has no sidebars: it only has a header, a main column and a footer, exactly where you expect them to be. The source code of this site follows W3C's XHTML 1.1 and CSS 2.1 standard. - -As of version 8, h3rald.com is a completely static web site, except for a few AJAX calls. All the files are generated automatically thanks to the "Nanoc":http://nanoc.stoneship.org/ publishing system, an ingenious creation of "Denis Defreyne":http://www.stoneship.org/. Nanoc can be used to easily create static web sites using Ruby, as explained in "this article":http://www.h3rald.com/articles/take-back-your-site-with-nanoc/. +<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/"><img alt="Creative Commons License" src="http://i.creativecommons.org/l/by-nc-nd/3.0/us/88x31.png" /></a> + +The source code of this web site, such as its layout, SASS/CSS stylesheets, custom rake tasks and code is licensed under the terms of the <em><a href="http://creativecommons.org/licenses/MIT/">MIT License</a></em> and it is available on "GitHub":http://github.com/h3rald/h3rald. + h3. Requirements -The following ruby libraries (gems) have been used to create this web site: +The following ruby libraries (gems) are used to compile this web site: * *"nanoc":http://rubygems.org/gems/nanoc*, to generate the entire web site * *"extlib":http://rubygems.org/gems/extlib*, in some custom Rake tasks * *"bb-ruby":http://rubygems.org/gems/bb-ruby*, for the BBCode filter * *"builder":http://rubygems.org/gems/builder/*, to create RSS and ATOM feeds * *"haml":http://rubygems.org/gems/haml/*, for the SASS filter +* *"coderay":http://rubygems.org/gems/coderay/*, for syntax highlighting * *"glyph":http://rubygems.org/gems/glyph*, for the Glyph filter Additionally, the following gems were necessary to migrate from the previous version of this web site, powered by "Typo":http://www.typosphere.org: * *"mysql":http://rubyforge.org/projects/mysql/* * *"sequel":http://rubyforge.org/projects/sequel/* -Besides Ruby-related dependencies, the following was also necessary: - -* *"pygments":http://pygments.org/*, a Python library for code highlighting. -* *"prince":http://www.princexml.com*, a program to generate PDF files from HTML. -* A cron job to fetch backtype comments, delicious bookmarks, tweets, and github commits in JSON format and save them to the @/output/data@ folder. - -h3. Licensing - -My "articles":/archives/ and all content published on this web site is licensed under the <em>Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 United States License</em>. For other uses, contact me. - -<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/"><img alt="Creative Commons License" src="http://i.creativecommons.org/l/by-nc-nd/3.0/us/88x31.png" /></a> - -The source code of this web site, such as its layout, SASS/CSS stylesheets, Nanoc tasks and code is licensed under the terms of the <em><a href="http://creativecommons.org/licenses/BSD/">BSD License</a></em> and it is available on "GitHub":http://github.com/h3rald/h3rald. h3. Credits -I'd like to thank the following people for their work, which made this web site possible: +Special thanks to the following people, who made this web site possible: -* "Denis Defreyne":http://www.stoneship.org/, for creating the wonderful "Nanoc":http://nanoc.stoneship.org/ site publishing system. +* "Denis Defreyne":http://www.stoneship.org/, for creating the wonderful "nanoc":http://nanoc.stoneship.org/ site publishing system. * "David J.Perry":http://scholarsfonts.net/, who designed the "Cardo font":http://scholarsfonts.net/cardofnt.html I used for the H3RALD logo and the navigation buttons. -* The staff of "Archive.org":http://www.archive.org, for scanning the first edition of "A Complete Guide to Heraldry":http://www.archive.org/details/completeguidetoh00foxduoft, and making it available to the public. All the images featuring heraldic monsters are taken from this book. -As of version 8, h3rald.com is a completely static web site, except for a few AJAX calls. All the files are generated automatically thanks to the "Nanoc":http://nanoc.stoneship.org/ publishing system, an ingenious creation of "Denis Defreyne":http://www.stoneship.org/. Nanoc can be used to easily create static web sites using Ruby, as explained in "this article":http://www.h3rald.com/articles/creating-static-web-sites-with-nanoc. +* The creators of the free "Gentium":http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=gentium font, used throughout the web site.
@@ -0,0 +1,38 @@
+----- +permalink: archives +filters_pre: +- erb +title: Archives +type: page +----- +<% + tags = sorted_site_tags +%> +<section> + <header> + <h1>Articles by Topic</h1> + </header> + <table id="taglist"> + <% c = 0 + tags.each do |t| + c = c+1 %> + <%= "<tr>" if c%5 == 1 %> + <td><%= tag_link_with_count(t[0], t[1]) %></td> + <%= "</tr>" if c%5 == 0 %> + <% end %></tr> + </table> +</section> +<section> + <header> + <h1>Articles by Month</h1> + </header> + <table id="timeline"> + <% c = 0 + articles_by_month.each do |m| + c = c+1 %> + <%= "<tr>" if c%5 == 1 %> + <td><%= month_link_with_count(m[0], m[1].length) %></td> + <%= "</tr>" if c%5 == 0 %> + <% end %></tr> + </table> +</section>
@@ -1,35 +0,0 @@
------ -permalink: archives -filters_pre: -- erb -title: Archives -type: page ------ -<% - tags = sorted_site_tags -%> - <div id="search_form"></div> - <div id="search_results"></div> -<p style="margin: auto; text-align: center"> -<img src="/images/theme/heraldry/phoenix.png" /> -</p> - <h3>Articles by Topic</h3> - <table id="taglist"> - <% c = 0 - tags.each do |t| - c = c+1 %> - <%= "<tr>" if c%5 == 1 %> - <td><%= tag_link_with_count(t[0], t[1]) %></td> - <%= "</tr>" if c%5 == 0 %> - <% end %></tr> - </table> - <h3>Articles by Month</h3> - <table id="timeline"> - <% c = 0 - articles_by_month.each do |m| - c = c+1 %> - <%= "<tr>" if c%5 == 1 %> - <td><%= month_link_with_count(m[0], m[1].length) %></td> - <%= "</tr>" if c%5 == 0 %> - <% end %></tr> - </table>
@@ -5,6 +5,7 @@ permalink: 10-programming-languages
filters_pre: - redcloth title: 10 programming languages worth checking out +subtitle: A quick comparison of 10 non-mainstream programming languages comments: - :date: :author: Nikhil@@ -309,10 +310,15 @@ tags:
- programming type: article toc: true +intro: | + If you program for fun or profit, chances are that you know C, C++, Java, PHP, Perl, Python or Ruby. These programming languages are all widely known, and, to a different degree, used in commercial applications. At least some of them can safely be considered _mainstream_, even if that word has become so overused and misused that has almost lost its original meaning, if it ever had one. + +extended_intro: | + If you are earning your living by coding, it's often one of these languages that pays the bills. Nevertheless, true hackers frequently meander in other directions, exploring and discovering different paradigms and methodologies, sometimes to the most "esoteric":http://esolangs.org/wiki/Main_Page extremes. ----- If you program for fun or profit, chances are that you know C, C++, Java, PHP, Perl, Python or Ruby. These programming languages are all widely known, and, to a different degree, used in commercial applications. At least some of them can safely be considered _mainstream_, even if that word has become so overused and misused that has almost lost its original meaning, if it ever had one. -If you are earning your living by coding, it's often one of these languages that pays the bills. Nevertheless, true hackers frequently meander in other directions, exploring and discovering different paradigms and methodologies, sometimes to the most ["esoteric":http://esolangs.org/wiki/Main_Page] extremes. +If you are earning your living by coding, it's often one of these languages that pays the bills. Nevertheless, true hackers frequently meander in other directions, exploring and discovering different paradigms and methodologies, sometimes to the most "esoteric":http://esolangs.org/wiki/Main_Page extremes. bq. "The most obvious common 'personality' characteristics of hackers are high intelligence, consuming curiosity, and facility with intellectual abstractions. Also, most hackers are 'neophiles', stimulated by and appreciative of novelty (especially intellectual novelty). Most are also relatively individualistic and anti-conformist."
@@ -1,11 +1,11 @@
----- -summary: "Ten possible reasons to learn the Ruby Programming Language. Mostly related to the language's syntax and most useful idioms." +subtitle: "Ten possible reasons to learn the Ruby Programming Language" popular: true permalink: 10-reasons-to-learn-ruby filters_pre: - erb - redcloth -title: 10 Reasons to Learn Ruby +title: "10 Reasons to Learn Ruby" comments: - :date: 2007-09-05 17:33:43 +02:00 :author: Joel Moss@@ -309,6 +309,10 @@ tags:
- ruby type: article toc: true +intro: | + I discovered Ruby fairly recently, through the excellent Ruby on Rails framework. Although I don't consider myself a Ruby expert by any means, I read the PickAxe[2], I've coded a few utilities for my personal use in Ruby and I'm currently developing with Rails during my free time. +extended_intro: | + Ruby is currently my programming language of choice; I started off with Turbo Pascal in high school, discovered C and C++ at university, did my thesis in Java and learned PHP from scratch because I wanted to learn how to make websites quickly and easily. I guess I feel compelled to code sometimes, more as a form of entertainment than anything else. Rather dissatisfied with what I tried language-wise, I was determined to start learning either Python or Ruby. I chose the latter because I didn't want incorrect indentation to break my code, and here I am, heaping praise upon it. ----- h3. Preamble
@@ -6,10 +6,16 @@ - books
- ruby permalink: distributed-programming-with-ruby-review title: "Book Review: Distributed Programming with Ruby" +subtitle: Just what you need to get started with the right tools to build large and scalable applications in Ruby toc: true pdf: true -summary: "A review of Mark Bates' Distributed Programming with Ruby. Just what you need to get started with the right tools to build large and scalable applications in Ruby." date: 2010-06-22 13:30:00.000000 +02:00 +intro: | + Back when I read <em>"Programming Ruby":http://www.pragprog.com/titles/ruby/programming-ruby</em> for the first time, I distinctly remember a short reference to "dRb":http://ruby-doc.org/stdlib/libdoc/drb/rdoc/index.html, the <strong>D</strong>istributed <strong>R</strong>u<strong>b</strong>y library included in the Standard Library. + + _"Cool!"_ -- I thought + + ...and that was pretty much it. The documentation for DRb was pretty much nonexistent (at the time), I didn't need it, so I pretty much forgot about it altogether until this book came out. ----- &:[book|_Distributed Programming with Ruby_] &:[author|Mark Bates]@@ -18,26 +24,20 @@ &:[linkedbook|=>[&[url]|&[book]]]
&:[image|$[site.root]/img/pictures/distributed-programming-with-ruby.jpg] &:[drb|=>[http://ruby-doc.org/stdlib/libdoc/drb/rdoc/index.html|DRb]] &:[rinda|=>[http://ruby-doc.org/stdlib/libdoc/rinda/rdoc/index.html|Rinda]] -&:[pickaxe|=>[#unkwnown#|_Programming Ruby_]] +&:[pickaxe|=>[http://www.pragprog.com/titles/ruby/programming-ruby|_Programming Ruby_]] rw:[pt| section[@title[Part {{0}}: {{1}}] txt[{{2}}] ] ] --[--------------------------------------------------] -textile[ -Back when I read &[pickaxe] for the first time, I distinctly remember a short reference to &[drb], the strong[D]istributed strong[R]u\.strong[b]y library included in the Standard Library. - -_"Cool!"_ -- I thought +$[document.intro] +txt[ +<em>"Distributed Programming with Ruby":http://www.informit.com/store/product.aspx?isbn=0321638360</em> fills a very particular niche of the Ruby programming world: _distributed_ programming. Moreover, this book is somehow _justified_ by the scarce documentation on the subject: -...and that was pretty much it. The documentation for DRb was pretty much nonexistent (at the time), I didn't need it, so I pretty much forgot about it altogether until this book came out. +bq. Although these libraries \[DRb and rinda\] have been included with Ruby for many years now, they have received little or no attention (or documentation). This has led to a lot of FUD (fear, uncertainty, and doubt) about what these libraries can and cannot do, and when they are appropriate to use (if at all). -&[linkedbook] fills a very particular niche of the Ruby programming world: _distributed_ programming. Moreover, this book is somehow _justified_ by the scarce documentation on the subject: - -bq. Although these libraries \[DRb and rinda\] have been included with Ruby for many years now, they have received little or no attention (or documentation). This has led to a lot of FUD -(fear, uncertainty, and doubt) about what these libraries can and cannot do, and when they are appropriate to use (if at all). - -p(((((. -- &[author], &[book] +p((((. -- Mark Bates, <em>"Distributed Programming with Ruby":http://www.informit.com/store/product.aspx?isbn=0321638360</em> But there's more. This book gives the reader a complete overview of what's out there, in the Ruby world, to support distributed programming. This includes quite a few gems and libraries besides the ones provided in the standard library. ]
@@ -1,5 +1,5 @@
----- -summary: "An in-depth review of the Opera browser, with the eyes of a Firefox enthusiast. A useful comparison of the two browsers, whether you're planning to _switch_ or not." +subtitle: "An in-depth review of the Opera browser, with the eyes of a Firefox enthusiast" popular: true permalink: firefox-lovers-guide-to-opera filters_pre:@@ -223,6 +223,10 @@ - opera
- firefox type: article toc: true +intro: | + I am a Firefox fan. I've been using Firefox since it was named "Firebird" and calling it "stable" was a big overstatement. Firefox dragged me out of Internet Explorer, and that was definitely one of its biggest achievements. + + Because I'm addicted to trying out new tools, however, I always kept testing new browsers I discovered here and there. K-Meleon, Flock, Sleipnir... When Safari came out for Windows I immediately installed it and used it for about 2 hours, only to realize that it wasn't – and it still isn't – usable at all, mainly due to sporadic crashes. ----- bq. *Note:* This article can be considered a sequel for "An IE Lover's Guide to Firefox":http://www.h3rald.com/articles/ie-lovers-guide-to-firefox, which described Firefox through the eyes of an Internet Explorer fan. Similarly, this article describes Opera's features from the point of view of a user – myself – who has been using Firefox for years and is now considering another browser switch.
@@ -6,10 +6,14 @@ - ruby
- opensource :permalink: glyph-020-released :title: "Glyph 0.2.0 Released" -:summary: "The second release of Glyph is out! Featuring single-file compilation, programmatic usage and auto-regeneration, as well as plenty of bugfixes and stability improvements." +:subtitle: Featuring single-file compilation, programmatic usage and auto-regeneration, and more :toc: true :pdf: true :date: 2010-05-09 17:00:00.099000 +02:00 +:intro: | + I am very pleased to announce the second release of the "Glyph Document Authoring Framework":/glyph/. For those who don't know, Glyph is a pure-Ruby, extensible solution to author documents like books or articles using a simple, fully-customizable markup language. + + Since the "first release":/articles/introducing-glyph/, came out, last month, a lot happened. Plenty of bugs were fixed and new features implemented, as shown by the "changelog":http://github.com/h3rald/glyph/blob/master/CHANGELOG.textile. Here's a brief rundown of the most notable changes. ----- &:[G|Glyph] textile[
@@ -6,13 +6,19 @@ - ruby
- opensource :permalink: glyph-030-released :title: "Glyph 0.3.0 Released" -:summary: "The third release of the Glyph Authoring Framework features dramatic speed improvements, the new 'glyph outline' command, alternative XML syntax, macro attributes, and more." +:subtitle: The third release of the Glyph Authoring Framework features dramatic speed improvements, and much more :toc: true :pdf: true :date: 2010-06-13 14:10:00.000000 +02:00 +:intro: | + The third release of "Glyph":/glyph/ is out! + + For those checking it out for the first time, Glyph is a _Rapid Document Authoring Framework_ focused on extensibility and content reuse. For an example of what Glyph can do, have a look at Glyph's "free PDF book":http://github.com/downloads/h3rald/glyph/glyph.pdf. + + This release brings more stability to Glyph, more speed, and features affecting Glyph's core functionality. As a consequence, some "incompatibilities":http://github.com/h3rald/glyph/issues/closed#issue/121 had to be introduced – but after all, better now than later. ----- &:[yardoc|http://yardoc.org/docs/h3rald-glyph] -&:[book|http://github.com/h3rald/glyph/raw/master/book/output/pdf/glyph.pdf] +&:[book|http://github.com/downloads/h3rald/glyph/glyph.pdf] p[The third release of =>[$[site.root]/glyph/|Glyph] is out!]
@@ -6,12 +6,13 @@ - ruby
- opensource :permalink: glyph-040-released :title: "Glyph 0.4.0 Released" -:summary: "Glyph 0.4.0 is out! Featuring web output, HTML5 support, stats, wkhtmltopdf, enhanced customization and much more." +:subtitle: Featuring web output, HTML5 support, stats, wkhtmltopdf, and much more :toc: true :pdf: true :date: 2010-09-03 19:45:00.000000 +02:00 +:intro: This new release of Glyph introduces an unusually large number of features, improvements and bugfixes. Not so much in terms of new macros maybe (no index or bibliography support for now, but it will come, don't worry!), but rather... pretty much everything else! ----- -txt[This new release of Glyph introduces an unusually large number of features, improvements and bugfixes. Not so much in terms of new macros maybe (no index or bibliography support for now, but it will come, don't worry!), but rather... pretty much everything else!] +$[document.intro] section[ @title[Web Output]
@@ -0,0 +1,62 @@
+----- +:title: H3RALD.com v8.1 Released +:subtitle: Featuring a a brand new newspaper-like design, powered by HTML5 and CSS3 +:type: article +:toc: true +:date: 2010-09-15 14:24:25.052000 +02:00 +:permalink: h3rald-81 +:pdf: true +:tags: +- website +- webdevelopment +:intro: | + Just "over a year ago":/articles/take-back-your-site-with-nanoc I released the 8th version of this web site. The biggest change then was abandoning the Rails-powered "Typo":http://wiki.github.com/fdv/typo/ blogging platform in favor of "nanoc":http://nanoc.stoneship.org/, arguably the most versatile static site generator out there. + + A year later, I am still very happy with nanoc, hence there's no need for another major release. Nonetheless, I decided to improve the site's overall design and image, making it (hopefully) easier to use and more pleasant to the eye. +:extended_intro: | + I always had a problem finding the right theme for my web site. I always wanted to find something related to the word _herald_, so in the last release I went for a herandry-oriented theme. For this release, I decided to go for a newspaper-style layout: after all, the word _herald_ is often used in newspaper titles, and I picked the name "h3rald" after the "International Herald Tribune":http://global.nytimes.com/?iht. + + Also, I was desperate to try out the new features offered by HTML3 and CSS3, and a newspaper layout seemed a good excuse to use columns. +----- +$[document.intro] +section[ + @title[Browser Compatibility] + txt[ +Although I shouldn't really say this, the site is meant to be viewed with a WebKit-based browser, really. It works in other (modern) browsers (read: no IE6), and it degrades more or less gracefully if a particular feature is not supported. + +That being said: +* IE7 and IE8 just barely render it (Javascript is used to "patch" the DOM with the new HTML5 elements) +* Firefox 3+ renders pretty much everything right. +* Safari and Chrome render the site as it is actually meant to be rendered + +Nobody ever died from not being able to see CSS3 rounded corners anyhow. The most important thing about this site is its content, and I made sure that whatever browser you're using you can still read it. + ] +] +section[ + @title[Columns and hyphenation] + txt[ +As I previously stated, I couldn't wait to try out CSS3 columns so I kinda went crazy on the home page, but just there. Some may argue that they are not suitable for web use of course, but I think they contribute to give the site layout a unique feeling. + +The problem with having columns is of course text alignment: justified text looks good, but unless you hyphenate text properly it shows a lot of blank space. Luckily, I discovered "hyphenator.js":http://code.google.com/p/hyphenator/, which solved the problem nicely. + ] +] +section[ + @title[CSS and layout improvements] + txt[ +I made a point out of improving the old stylesheet to make the site easier to read and generally prettier. Beauty is in the eye of the beholder, but still, I think the new stylesheet brings some improvements, especially concerning text (the "Gentium":http://scripts.sil.org/gentium font is used throughout the site) and syntax highlighting. + +Moreover, I worked on streamlining navigations across different sections of the site, in particular on article pages: + +!=/img/pictures/h3rald_81_article.png! + ] +] +section[ + @title[Under the hood] + txt[ +Besides appearence, the new site also features some improvements in its underlying business logic. In particular: +* Better nanoc "Rules":http://github.com/h3rald/h3rald/blob/master/Rules +* Improved "Glyph":/glyph/ integration, by extending nanoc "RuleContext":http://github.com/h3rald/h3rald/blob/master/lib/glyph_context.rb +* Minor updates to the custom "Rake tasks":http://github.com/h3rald/h3rald/blob/master/tasks/site.rake +* "Disqus":http://disqus.com/overview/ comments + ] +]
@@ -1,5 +1,5 @@
----- -summary: "My very own VIM color scheme. Featuring 256, 16 and 8 color support, high readability and... pretty colors!" +subtitle: "My very own VIM color scheme. Featuring 256, 16 and 8 color support, high readability and... pretty colors!" permalink: herald-vim-color-scheme filters_pre: - redcloth@@ -74,8 +74,17 @@ - vim
type: article toc: true popular: true +intro: | + I use "Vim":http://www.vim.org a lot. It's my editor of choice when I code (mainly in Ruby), and also when I write my blog post and articles (mainly in Textile). + + One thing I always liked about Vim was it powerful syntax highlighting: there's probably a syntax highlighting file for every programming language ever created, even the new ones ("Nimrod":http://force7.de/nimrod/index.html? Sure, "here":http://www.vim.org/scripts/script.php?script_id=2632!). +extended_intro: | + Furthermore, Vim allows you to create color schemes, and that's surprisingly easy to do. Everything you need to do is in the "docs":http://vimdoc.sourceforge.net/htmldoc/syntax.html, but that may put you off, so you can just start by editing an existing one -- that's what I did.h3. InfiniteRed Black + + I've been using the "ir_black":http://blog.infinitered.com/entries/show/8 color scheme for near enough a year. It's an excellent color scheme, recommended especially for writing Ruby code: ----- I use "Vim":http://www.vim.org a lot. It's my editor of choice when I code (mainly in Ruby), and also when I write my blog post and articles (mainly in Textile). + One thing I always liked about Vim was it powerful syntax highlighting: there's probably a syntax highlighting file for every programming language ever created, even the new ones ("Nimrod":http://force7.de/nimrod/index.html? Sure, "here":http://www.vim.org/scripts/script.php?script_id=2632!). Furthermore, Vim allows you to create color schemes, and that's surprisingly easy to do. Everything you need to do is in the "docs":http://vimdoc.sourceforge.net/htmldoc/syntax.html, but that may put you off, so you can just start by editing an existing one -- that's what I did.h3. InfiniteRed Black
@@ -1,6 +1,5 @@
----- -summary: "A comprehensive review of the free editor from ActiveState, and why it's a very interesting alternative to more complex and heavy IDEs." -popular: true +subtitle: "A comprehensive review of the free editor from ActiveState" permalink: komodo-edit-review filters_pre: - redcloth@@ -108,6 +107,12 @@ - programming
- software type: article toc: true +intro: | + _What's your favorite code editor?_ + + This is a common question which still keeps popping up on community boards, mailing lists, comments, etc. Every programmer who writes code in some programming language normally has an editor of choice. Being realistic, most of the times it's not only one program but several, depending on the language and on the features needed at the time. + + Yes, great, but how do you choose your favorite editor? ----- <a href="http://digg.com/programming/A_closer_look_at_Komodo_Edit"> <img src="http://digg.com/img/badges/180x35-digg-button.png" width="180" height="35" alt="Digg!" />
@@ -1,5 +1,5 @@
----- -summary: "A roundup of six different PHP frameworks inspired by Ruby on Rails. Each with essential details, comments, pros and cons." +subtitle: "A roundup of six different PHP frameworks inspired by Ruby on Rails" popular: true permalink: rails-inspired-php-frameworks filters_pre:@@ -77,6 +77,7 @@ - cakephp
- rails type: article toc: true +intro: There are various articles online examining many PHP frameworks, providing short reviews or comparative charts, but I could not find yet an article examining the so called _"Rails-inspired frameworks"_ anywhere on the web, so I decided to write my own... ----- There are various articles online examining many PHP frameworks, providing short reviews or comparative charts, but I could not find yet an article examining the so called _"Rails-inspired frameworks"_ anywhere on the web, so I decided to write my own...
@@ -0,0 +1,13 @@
+----- +:type: page +:permalink: contact +:title: "Contact" +----- +You can contact me using the form below or by sending an email to <a href='mailto:h3rald@h3rald.com'>h3rald@h3rald.com</a>. + +<section class="center"> + <script type="text/javascript" src="http://www.formstack.com/forms/js.php?1003418-bMy6M2wC0u-v2"></script> + <noscript><a href="http://www.formstack.com/forms/?1003418-bMy6M2wC0u" title="Contact">Contact</a></noscript> + <section style="font-size:x-small;"><a href="http://www.formstack.com/" title="Web Form Builder">Formstack - Web Form Builder</a></section> +</section> +
@@ -1,62 +0,0 @@
-@import definitions - -.highlight, .code, pre.lazy - +code_font - border: 1px solid #cccccc - background: #dedede - padding: 5px - margin: 5px 0 - font-size: 90% - overflow: auto - - -code - +code_font - font-size: 90% - -.highlight - .hll - background-color: #ffffcc - - .c - color: #008000 - - .err - border: 1px solid #FF0000 - - .k - color: #0000ff - - .cm - color: #008000 - - .cp - color: #0000ff - - .c1, .cs - color: #008000 - - .ge - font-style: italic - - .gh, .gp, .gs, .gu - font-weight: bold - - .kc, .kd, .kn, .kp, .kr - color: #0000ff - - .kt - color: #2b91af - - .s - color: #a31515 - - .nc - color: #2b91af - - .ow - color: #0000ff - - .sb, .sc, .sd, .s2, .se, .sh, .si, .sx, .sr, .s1, .ss - color: #a31515 -
@@ -1,27 +0,0 @@
-// Variables -$red: #a4282d -$gray: #555555 - -// Mixins -=default_border - border: 1px solid $gray - -=button_img($img) - background: url(../images/theme/buttons/#{$img}.png) - -=title_font - font-family: "Palatino Linotype", "Palatino", "Book Antiqua", "Serif" - -=body_font - font-family: "Georgia", "Serif" - -=title - +title_font - font-variant: small-caps - margin: 1em 0 0 0 - -=code_font - font-family: "Consolas", "Monaco", "Monospace" - -=darkbg_font - color: #cacaca
@@ -1,380 +0,0 @@
-@import definitions - -#content img - margin: 0 5px - padding: 2px - -#content - li, dd - margin-left: 30px - line-height: 1.5em - dt - margin-top: 1em - font-weight: bold - dd - font-style: italic - p - line-height: 1.5em - margin: 1em 0 - -blockquote, .note - color: $gray - font-style: italic - padding: 0 0 0 33px - margin: 5px - -blockquote - background: url(../images/theme/quote.png) no-repeat top left - -.note .note-title - font-style: normal - font-weight: bold - padding-right: 1em - -.hidden - display: none - -.preload - background-position: -9999px -9999px - -#navigation a - display: block - -#nav-about - width: 115px - height: 52px - +button_img(about) - &:hover - +button_img(about_h) - -.nav-about - +button_img(about_h) - -#nav-other - width: 130px - height: 52px - +button_img(other) - &:hover - +button_img(other_h) - -.nav-other - +button_img(other_h) - -#nav-projects - width: 127px - height: 52px - +button_img(projects) - &:hover - +button_img(projects_h) - -.nav-projects - +button_img(projects_h) - -#nav-archives - width: 155px - height: 52px - +button_img(archives) - &:hover - +button_img(archives_h) - -.nav-archives - +button_img(archives_h) - -#services li - margin-left: 0 - -#services h3 - display: block - text-align: center - a - margin: auto - display: block - -#s-opinions - width: 192px - height: 52px - +button_img(opinions) - &:hover - +button_img(opinions_h) - -.s-opinions - +button_img(opinions_h) - -#s-tweets - width: 183px - height: 52px - +button_img(tweets) - &:hover - +button_img(tweets_h) - -.s-tweets - +button_img(tweets_h) - -#s-bookmarks - width: 197px - height: 52px - +button_img(bookmarks) - &:hover - +button_img(bookmarks_h) - -.s-bookmarks - +button_img(bookmarks_h) - -.spacer-20 - display: block - height: 20px - -.spacer-50 - display: block - height: 50px - -.spacer-100 - display: block - height: 100px - -.spacer-200 - display: block - height: 200px - -.feed-item - list-style-type: none - margin: 0.8em 0.3em - -.feed-item-text, .feed-item-date - display: block - -.feed-item-text - margin-top: 0.3em - margin-left: 1em - font-style: italic - -.left-column - float: left - width: 400px - -.right-column - float: right - width: 400px - -.clearleft - clear: both - -.article-item - padding: 0.5em 0 - display: block - -.article-meta - font-size: 0.8em - -.tag - font-weight: bold - -.project-data - border-left: 1px dashed $gray - padding: 0 1em 1em 1.5em - margin: 0 0 0 1.5em - height: 300px - -ul - overflow: hidden - &.article-meta - list-style-type: none - &.article-buttons - text-align: center - list-style-type: none - display: block - margin: auto - border: 1px solid $gray - background: white - padding: 5px 0 - -#toc - float: right - width: 250px - padding: 10px - margin: 0 0 10px 15px - +default_border - ol - li - margin-left: 1.5em - li - margin-left: 1.5em - li - margin-left: 1.5em - li - margin-left: 1.5em - li - margin-left: 1.5em - li - line-height: 1.2em - -#toctitle - font-variant: small-caps - font-weight: bold - -.toc-top-link - font-size: 13px - margin-left: 15px - -.contents > #toc - display: none - -.contents ol li - list-style-type: none - -div.navigation - display: block - margin: auto - text-align: center - margin: 2em 0 - -div.navigation a - font-weight: bold - font-variant: small-caps - margin-left: 3em - margin-right: 3em - -#content .article-buttons li - font-family: "Arial", "Sans-serif" - font-size: 0.8em - font-weight: bold - display: inline - margin-left: 0 - vertical-align: top - -#content .article-meta li - margin-left: 0 - -.inner-border img - margin-top: 7px - -#legacy-comments, #intensedebate - max-width: 800px - margin: auto - -.legacy-comment - padding: 5px 0 - -.lc-header - display: block - height: 20px - border: 1px solid #232323 - background: #121212 - padding: 5px - -table - margin: 10px auto - +default_border - -tr - border-bottom: 1px solid $gray - -#search_form tr, #timeline tr, #taglist tr - border-bottom: none - -table - &#timeline, &#taglist - border: none - -tr, td, th - padding: 5px - -td - border-left: 1px solid $gray - border-right: 1px solid $gray - -th - background: #cecece - +default_border - -#taglist, #timeline - width: 100% - border-bottom: none - margin: 20px 0 - -#taglist tr, #timeline tr - padding: 2px - width: 100% - -#taglist td, #timeline td - padding: 2px - border-left: none - border-right: none - -#content input - &[type=submit] - color: #333333 - border: 2px solid $gray - background: #cccccc - outline: none - padding: 0.1em 0.3em - vertical-align: middle - &:hover - border: 2px solid #cf282d - background: #eeeeee - color: #121212 - &:active - background: #aaaaaa - outline: none - &[type=text] - color: #333333 - border: 2px solid #333333 - background: white - outline: none - text-align: left - height: 21px - vertical-align: middle - &:hover, &:focus, &:active - border: 2px solid #cf282d - -#search_form - clear: both - -.gsc-resultsHeader, .gs-visibleUrl, .gsc-trailing-more-results, .gs-watermark - display: none - -.gsc-result - padding: 0.5em 0 - -table.gsc-search-box - height: 25px - margin: auto - margin-top: 20px - -.gsc-control, .gsc-resultsRoot - width: 850px - -.gsc-search-box - border: none - td - border: none - -.gsc-input - width: 400px - -.gsc-branding - color: black - font-style: italic - font-size: 80% - border: none - margin: auto - padding: 0 - -td.gsc-branding-img - text-align: left - -div.gsc-clear-button - background: transparent url("../images/theme/icons/close.png") no-repeat center 50% - width: 10px - height: 10px - &:hover - cursor: pointer - -.gsc-cursor-page - display: inline - padding-right: 7px - &:hover - cursor: pointer - -.gsc-cursor-current-page - font-weight: bold
@@ -1,25 +0,0 @@
-#gallery - padding: 1em - width: 750px - ul - list-style: none - li - float: left - margin-left: 2px - padding-left: 0 - img - border: 5px solid #dedede - a:hover - color: white - img - border: 5px solid #cccccc - color: white - a - border-bottom: none - -#fancy_content - a - border-bottom: none - -#fancy_title td, #fancy_title tr, #fancy_title table - border: none
@@ -1,245 +0,0 @@
-html, body - height: 100% - -div#fancy_overlay - position: fixed - top: 0 - left: 0 - width: 100% - height: 100% - background-color: #666666 - display: none - z-index: 30 - -* html div#fancy_overlay - position: absolute - height: 580px - -div - &#fancy_wrap - text-align: left - &#fancy_loading - position: absolute - height: 40px - width: 40px - cursor: pointer - display: none - overflow: hidden - background: transparent - z-index: 100 - div - position: absolute - top: 0 - left: 0 - width: 40px - height: 480px - background: transparent url("/images/fancybox/fancy_progress.png") no-repeat - &#fancy_loading_overlay - position: absolute - background-color: white - z-index: 30 - &#fancy_loading_icon - position: absolute - background: url("/images/fancybox/fancy_loading.gif") no-repeat - z-index: 35 - width: 16px - height: 16px - &#fancy_outer - position: absolute - top: 0 - left: 0 - z-index: 90 - padding: 18px 18px 33px 18px - margin: 0 - overflow: hidden - background: transparent - display: none - &#fancy_inner - position: relative - width: 100% - height: 100% - border: 1px solid #bbbbbb - background: white - &#fancy_content - margin: 0 - z-index: 100 - position: absolute - &#fancy_div - background: black - color: white - height: 100% - width: 100% - z-index: 100 - -img#fancy_img - position: absolute - top: 0 - left: 0 - border: 0 - padding: 0 - margin: 0 - z-index: 100 - width: 100% - height: 100% - -div#fancy_close - position: absolute - top: -12px - right: -15px - height: 30px - width: 30px - background: url("/images/fancybox/fancy_closebox.png") top left no-repeat - cursor: pointer - z-index: 181 - display: none - -#fancy_frame - position: relative - width: 100% - height: 100% - display: none - -#fancy_ajax - width: 100% - height: 100% - overflow: auto - -a - &#fancy_left, &#fancy_right - position: absolute - bottom: 0px - height: 100% - width: 35% - cursor: pointer - z-index: 111 - display: none - outline: none - &#fancy_left - left: 0px - &#fancy_right - right: 0px - -span - &.fancy_ico - position: absolute - top: 50% - margin-top: -15px - width: 30px - height: 30px - z-index: 112 - cursor: pointer - display: block - &#fancy_left_ico - left: -9999px - background: transparent url("/images/fancybox/fancy_left.png") no-repeat - &#fancy_right_ico - right: -9999px - background: transparent url("/images/fancybox/fancy_right.png") no-repeat - -a - &#fancy_left:hover, &#fancy_right:hover - visibility: visible - &#fancy_left:hover span - left: 20px - &#fancy_right:hover span - right: 20px - -.fancy_bigIframe - position: absolute - top: 0 - left: 0 - width: 100% - height: 100% - background: transparent - -div - &#fancy_bg - position: absolute - top: 0 - left: 0 - width: 100% - height: 100% - z-index: 70 - border: 0 - padding: 0 - margin: 0 - &.fancy_bg - position: absolute - display: block - z-index: 70 - border: 0 - padding: 0 - margin: 0 - &.fancy_bg_n - top: -18px - width: 100% - height: 18px - background: transparent url("/images/fancybox/fancy_shadow_n.png") repeat-x - &.fancy_bg_ne - top: -18px - right: -13px - width: 13px - height: 18px - background: transparent url("/images/fancybox/fancy_shadow_ne.png") no-repeat - &.fancy_bg_e - right: -13px - height: 100% - width: 13px - background: transparent url("/images/fancybox/fancy_shadow_e.png") repeat-y - &.fancy_bg_se - bottom: -18px - right: -13px - width: 13px - height: 18px - background: transparent url("/images/fancybox/fancy_shadow_se.png") no-repeat - &.fancy_bg_s - bottom: -18px - width: 100% - height: 18px - background: transparent url("/images/fancybox/fancy_shadow_s.png") repeat-x - &.fancy_bg_sw - bottom: -18px - left: -13px - width: 13px - height: 18px - background: transparent url("/images/fancybox/fancy_shadow_sw.png") no-repeat - &.fancy_bg_w - left: -13px - height: 100% - width: 13px - background: transparent url("/images/fancybox/fancy_shadow_w.png") repeat-y - &.fancy_bg_nw - top: -18px - left: -13px - width: 13px - height: 18px - background: transparent url("/images/fancybox/fancy_shadow_nw.png") no-repeat - &#fancy_title - position: absolute - bottom: -33px - left: 0 - width: 100% - z-index: 100 - display: none - div - color: white - font: bold 12px Arial - padding-bottom: 3px - table - margin: 0 auto - td - padding: 0 - vertical-align: middle - -td - &#fancy_title_left - height: 32px - width: 15px - background: transparent url(/images/fancybox/fancy_title_left.png) repeat-x - &#fancy_title_main - height: 32px - background: transparent url(/images/fancybox/fancy_title_main.png) repeat-x - &#fancy_title_right - height: 32px - width: 15px - background: transparent url(/images/fancybox/fancy_title_right.png) repeat-x
@@ -1,160 +0,0 @@
-@import definitions - -* - font-family: inherit - font-style: inherit - font-size: 100% - border: none - padding: 0 - margin: 0 - -html, body - height: 100% - line-height: 1.2 - background: #121212 - -p, ol, ul - margin: 0.5em 0 - -table - border-collapse: collapse - border-spacing: 0 - -body - margin: 0 - padding: 0 - -=button_img($img) - background: url(../images/theme/#{$img}.png) - -#logo - display: block - width: 313px - height: 75px - +button_img(logo) - &:hover - +button_img(logo_h) - -.logo - +button_img(logo_h) - -#header - width: 100% - padding: 5px 0 - height: 70px - -#header-container, #footer-container - margin: auto - width: 900px - -#header-left - float: left - width: 300px - -#header-right - float: right - text-align: right - width: 600px - -#navigation li - float: left - list-style-type: none - padding-left: 10px - -#ie-warning - border-bottom: 1px solid #f5b800 - background-color: #ffe38f - padding: 1em - margin-top: -5px - margin-bottom: 5px - font-weight: bold - -#container - padding: 5px 15px - margin: auto - width: 900px - height: 100% - -.ribbon - height: 19px - background: url(../images/theme/ribbon.png) repeat-x - -#main - background: white url(../images/theme/main.jpg) - -#content - text-align: justify - padding: 0 1em - -#content-body - clear: both - -#content-footer - text-align: center - margin: auto - -#wrapper - min-height: 100% - margin-bottom: -40px - -#border-bottom - clear: both - height: auto - padding: 0 - width: 100% - +darkbg_font - -#services - margin: auto - width: 1000px - -#footer - position: relative - height: 40px - width: 100% - font-size: 0.8em - text-align: center - padding-top: 1em - +darkbg_font - -.clearfooter - height: 40px - clear: both - -.footer-left, .footer-right, .footer-center - float: left - text-align: left - font-size: 90% - display: block - height: 600px - -.footer-left, .footer-right - width: 30% - -.footer-center - width: 40% - -.footer-div - clear: both - font-size: 95% - color: #cacaca - -.share - clear: both - margin: auto - padding: 5px - text-align: center - table, td, tr - border: none - -#page-links - text-align: right - img - vertical-align: text-bottom - -#page-links span - padding: 0 5px - -#comments - width: 900px - margin: auto
@@ -1,71 +0,0 @@
-@import definitions - -/* TEXT - -body - color: black - +body_font - font-size: 0.9em - -h2 - font-size: 2.3em - +title - margin: 0 - -h3 - font-size: 1.7em - +title - -h4 - font-size: 1.3em - +title - -.dropcap - +title_font - float: left - font-size: 4.2em - line-height: 0.75em - margin-top: 0.15em - padding-right: 0.25em - text-transform: uppercase - -p.first-p:first-line - font-variant: small-caps - -#services h3 - text-align: center - -em - font-style: italic - -/**** Article Lists *** - -.article-list h3, .left-column h3, .right-column h3 - text-align: center - -.article-item h4 - margin: 0 - padding: 0 - -.article-tags - font-size: 90% - padding-left: 1em - -.article-summary - padding-left: 1em - font-style: italic - -/******* LINKS ****** - -a, a.gs-title - text-decoration: none - outline: none - -h4 a - text-decoration: none - -a, a.gs-title, .gsc-cursor-page - color: $red - -a:hover, a.gs-title:hover, .gsc-cursor-page:hover - color: #cf282d
@@ -1,6 +0,0 @@
-@import layout.sass -@import elements.sass -@import text.sass -@import code.sass -@import fancybox.sass -@import fancybox-gallery.sass
@@ -3,35 +3,30 @@ permalink: glyph
filters_pre: - erb - redcloth -title: "Project: Glyph" +title: "Glyph" +subtitle: "A Rapid Document Authoring Framework" type: project github: glyph links: - "Repository": http://www.github.com/h3rald/glyph/ -- "Bug Tracking": http://www.github.com/h3rald/glyph/issues -- "Development Wiki": http://wiki.github.com/h3rald/glyph - "Download": http://www.rubygems.org/gems/glyph -- "Book (PDF)": http://github.com/downloads/h3rald/glyph/glyph.pdf -- "Book (Web)": http://www.h3rald.com/glyph/book/ -- "Docs": http://rubydoc.info/gems/glyph/ +- "Documentation": /glyph/book/ - "User Group": http://groups.google.com/group/glyph-framework status: Active -version: 0.4.0 +version: 0.4.1 ----- <%= render 'project_data', :tag => 'glyph' %> -<div class="section"> +<section class="section"> Glyph is a _Rapid Document Authoring Framework_. With Glyph, creating and maintaining any kind of document becomes as easy as... _programming_. Glyph enables you to minimize text duplication, focus on content rather than presentation, manage references seamlessly and automate tedious tasks through a simple but effective macro language, specifically geared towards customization and extensibility. - <br style="clear:both" /> - - <div class="section"> -<h3 id="h_1">Main Features</h3> -<div class="section"> -<h4 id="h_2">Command Line Interface</h4> + <section class="section"> +<header><h1 id="h_1">Main Features</h1></header> +<section class="section"> +<header><h1 id="h_2">Command Line Interface</h1></header> Glyph is 100% command line. Its interface resambles <a href="http://git-scm.com/">Git's</a> for its simplicity and power (thanks to the <a href="http://github.com/davetron5000/gli">gli</a> gem). Here are some example commands: * @glyph init@ -- to initialize a new Glyph project in the current (empty) directory.@@ -43,10 +38,10 @@ * @glyph compile readme.glyph@ -- to compile a _readme.glyph_ located in the current directory into a single HTML file.
* @glyph outline -l 2@ -- Display the document outline, up to second-level headers. * @glyph stats@ -- Display project statistics. -</div> +</section> - <div class="section"> -<h4 id="h_3">Minimalist Syntax</h4> + <section class="section"> +<header><h1 id="h_3">Minimalist Syntax</h1></header> Glyph syntax rules can be explained using Glyph itself: <div class="code">@@ -106,10 +101,10 @@ </code>
</pre> </div> -</div> +</section> - <div class="section"> -<h4 id="h_4">Content Reuse</h4> + <section class="section"> +<header><h1 id="h_4">Content Reuse</h1></header> Finding yourself repeating the same sentence over an over? Glyph allows you to create snippets. Within snippets. Within other snippets (and so on, for a long long time...) as long as you don't define a snippet by defining itself, which would be kinda nasty (and Glyph would complain!): <div class="code">@@ -134,42 +129,42 @@ </pre>
</div> If yourself dreaming about _parametric_ snippets, just create your own macros (see the <a href="http://github.com/h3rald/glyph/blob/master/book/text/changelog.glyph">source</a> of Glyph's changelog, just to have an idea). -</div> - <div class="section"> -<h4 id="h_5">Automation of Common Tasks</h4> +</section> + <section class="section"> +<header><h1 id="h_5">Automation of Common Tasks</h1></header> If you're writing a book, you shouldn't have to worry about pagination, headers, footers, table of contents, section numbering or similar. Glyph understands you, and will take care of everything for you (with a little help from CSS3, sometimes). -</div> - <div class="section"> -<h4 id="h_6">Reference Validation</h4> +</section> + <section class="section"> +<header><h1 id="h_6">Reference Validation</h1></header> Feel free to add plenty of links, snippets, bookmarks, ... if Glyph doesn't find something, it will definitely complain. Broken references are a thing on the past, and you don't need to worry about it. -</div> - <div class="section"> -<h4 id="h_7">Extreme Extensibility</h4> +</section> + <section class="section"> +<header><h1 id="h_7">Extreme Extensibility</h1></header> * You miss a <code>!!!</code> macro to format really, _really_ important things? Create it. In under 3 seconds, in Ruby or Glyph itself. And yes, you can use special characters, too. * You want your own, very special special @glyph create --everything@ command to create all _you_ need in a Glyph project? You can do it. Using your own Rake tasks, too. * You want Glyph to output ODF files? You can do it, and you'll be able to run @glyph generate -f odf@. This would probably require a little more time, but it's trivial, from a technical point of view. -</div> - <div class="section"> -<h4 id="h_8">Convention over Configuration</h4> +</section> + <section class="section"> +<header><h1 id="h_8">Convention over Configuration</h1></header> Put your text files in @/text@, your images in @/images@, add custom macros in a @macro@ folder within your @/lib@ folder... you get the picture: Glyph has its special places. Nonetheless, you also have 1 (_one_) configuration file to customize to your heart's content (with smart defaults). -</div> - <div class="section"> -<h4 id="h_9">Free and Open Source</h4> +</section> + <section class="section"> +<header><h1 id="h_9">Free and Open Source</h1></header> Glyph is 100% Open Source Software, developed using the Ruby Programming Language and licensed under the very permissive terms of the <a href="http://www.opensource.org/licenses/mit-license.php">MIT License</a>. If you have Ruby installed, just run @gem install glyph@. That's all it takes. -</div> +</section> -</div> - <div class="section"> -<h3 id="h_10">Resources</h3> +</section> + <section class="section"> +<header><h1 id="h_10">Resources</h1></header> * Home Page: <a href="http://www.h3rald.com/glyph/">http://www.h3rald.com/glyph/</a> * Repository: <a href="http://www.github.com/h3rald/glyph/">http://www.github.com/h3rald/glyph/</a> * Bug Tracking: <a href="http://www.github.com/h3rald/glyph/issues">http://www.github.com/h3rald/glyph/issues</a>@@ -180,8 +175,8 @@ * Book (Web): <a href="http://www.h3rald.com/glyph/book/">http://www.h3rald.com/glyph/book/</a>
* Reference Documentation: <a href="http://rubydoc.info/gems/glyph/">http://rubydoc.info/gems/glyph/</a> * User Group: <a href="http://groups.google.com/group/glyph-framework">http://groups.google.com/group/glyph-framework</a> -</div> +</section> -</div> +</section> <%= render 'project_updates', :tag => 'glyph' %>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Acknowledgements</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Acknowledgements – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Acknowledgements</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Acknowledgements</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/license.html">License ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/create_project.html">→ Creating your first Glyph Project</a></div> + <nav><a href="/glyph/book/license.html">License ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/create_project.html">→ Creating your first Glyph Project</a></nav> <p>Glyph was designed and developed by <a href="http://www.h3rald.com">Fabio Cevasco</a> (h3rald).</p> <p>Special thanks to the following individuals who contributed to Glyph by reporting and fixing issues and/or proposing and implementing new features:</p> <ul>@@ -68,86 +70,64 @@ <li><a href="http://balcone.eveel.ru">Dmitry A. Ustalov</a> (eveel)</li>
<li><a href="http://www.stuartellis.eu">Stuart Ellis</a> (stuartellis)</li> </ul> - <div class="navigation"><a href="/glyph/book/license.html">License ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/create_project.html">→ Creating your first Glyph Project</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_2.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/license.html">License ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/create_project.html">→ Creating your first Glyph Project</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,73 +1,102 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Changelog</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Changelog – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Changelog</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Changelog</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/config/output.html">output.* ←</a><a href="/glyph/book/index.html">Contents</a></div> + <nav><a href="/glyph/book/config/output.html">output.* ←</a><a href="/glyph/book/index.html">Contents</a></nav> - <div class="section"> -<h3 id="h_231">v0.4.0 – September 3th 2010</h3> -<div class="section"> -<h4 id="h_232">13 Features Implemented</h4> + <section class="section"> +<header><h1 id="h_231">v0.4.1 – September 23th 2010</h1></header> +<section class="section"> +<header><h1 id="h_232">5 Bugs Fixed</h1></header> +<table><tr><th>ID</th> + <th>Description</th></tr> + + + <tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/169">#169</a></td> + <td><p>*.scss files are now supported by the <a href="/glyph/book/macros/macros_structure.html#m_style"><code>style</code></a> macro.</p></td></tr> + + <tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/170">#170</a></td> + <td><p>Improved default CodeRay stylesheet.</p></td></tr> + + <tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/171">#171</a></td> + <td><p><span class="caps">SCSS</span> now used internally by Glyph to generate default <span class="caps">CSS</span> files.</p></td></tr> + + <tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/173">#173</a></td> + <td><p>Consecutive escape sequences are now interpreted correctly in topics.</p></td></tr> + + <tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/174">#174</a></td> + <td><p>Fixed error causing broken images in web5/html5 output.</p></td></tr></table> + +</section> + +</section> + + <section class="section"> +<header><h1 id="h_233">v0.4.0 – September 3th 2010</h1></header> +<section class="section"> +<header><h1 id="h_234">13 Features Implemented</h1></header> <table><tr><th>ID</th> <th>Description</th></tr>@@ -111,11 +140,11 @@
<tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/148">#148</a></td> <td><p>It is now possible to create custom tasks and commands to extend Glyph functionality.</p></td></tr></table> -</div> +</section> - <div class="section"> -<h4 id="h_233">7 Bugs Fixed</h4> + <section class="section"> +<header><h1 id="h_235">7 Bugs Fixed</h1></header> <table><tr><th>ID</th> <th>Description</th></tr>@@ -141,14 +170,14 @@
<tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/167">#167</a></td> <td><p>Fixed <span class="caps">PDF</span> book download links.</p></td></tr></table> -</div> +</section> -</div> +</section> - <div class="section"> -<h3 id="h_234">v0.3.0 – June 13th 2010</h3> -<div class="section"> -<h4 id="h_235">13 Features Implemented</h4> + <section class="section"> +<header><h1 id="h_236">v0.3.0 – June 13th 2010</h1></header> +<section class="section"> +<header><h1 id="h_237">13 Features Implemented</h1></header> <table><tr><th>ID</th> <th>Description</th></tr>@@ -192,11 +221,11 @@
<tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/130">#130</a></td> <td><p>A new “safe mode” has been implemented to explicitly forbid certain potentially unsafe macros.</p></td></tr></table> -</div> +</section> - <div class="section"> -<h4 id="h_236">3 Bugs Fixed</h4> + <section class="section"> +<header><h1 id="h_238">3 Bugs Fixed</h1></header> <table><tr><th>ID</th> <th>Description</th></tr>@@ -210,14 +239,14 @@
<tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/125">#125</a></td> <td><p>Warning messages have been streamlined.</p></td></tr></table> -</div> +</section> -</div> +</section> - <div class="section"> -<h3 id="h_237">v0.2.0 – May 9th 2010</h3> -<div class="section"> -<h4 id="h_238">11 Features Implemented</h4> + <section class="section"> +<header><h1 id="h_239">v0.2.0 – May 9th 2010</h1></header> +<section class="section"> +<header><h1 id="h_240">11 Features Implemented</h1></header> <table><tr><th>ID</th> <th>Description</th></tr>@@ -255,11 +284,11 @@
<tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/108">#108</a></td> <td><p>It is now possible to define Glyph macros within Glyph source files using the <a href="/glyph/book/macros/macros_core.html#m_macro_"><code>macro:</code></a> macro.</p></td></tr></table> -</div> +</section> - <div class="section"> -<h4 id="h_239">8 Bugs Fixed</h4> + <section class="section"> +<header><h1 id="h_241">8 Bugs Fixed</h1></header> <table><tr><th>ID</th> <th>Description</th></tr>@@ -288,95 +317,73 @@
<tr><td><a href="http://github.com/h3rald/glyph/issues/closed#issue/107">#107</a></td> <td><p>Added the possibility to encode (using the <code>encode</code> macro) and decode (using the <code>decode</code> macro) macros so that they can be interpreted later.</p></td></tr></table> -</div> +</section> -</div> +</section> - <div class="section"> -<h3 id="h_240">v0.1.0 – April 8th 2010</h3> + <section class="section"> +<header><h1 id="h_242">v0.1.0 – April 8th 2010</h1></header> Initial release. -</div> - <div class="navigation"><a href="/glyph/book/config/output.html">output.* ←</a><a href="/glyph/book/index.html">Contents</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_57.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/config/output.html">output.* ←</a><a href="/glyph/book/index.html">Contents</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Compiling a project</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Compiling a project – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Compiling a project</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Compiling a project</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/conditionals.html">Conditional Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/lite_mode.html">→ Compiling single Glyph files</a></div> + <nav><a href="/glyph/book/text_editing/conditionals.html">Conditional Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/lite_mode.html">→ Compiling single Glyph files</a></nav> <p>By default, a Glyph project can be “compiled” into an <span class="caps">HTML</span> document. Additionally, Glyph can also be used to produce documents in the following formats:</p> <ul> <li>HTML5</li>@@ -66,8 +68,8 @@ <li><span class="caps">PDF</span> (generated from <span class="caps">HTML</span> using a third-party generator like <a href="http://www.princexml.com/">Prince</a> or <a href="http://code.google.com/p/wkhtmltopdf/">wkhtmltopdf</a>)</li>
<li>Web (i.e. multiple <span class="caps">HTML</span> files)</li> <li>Web5 (i.e. multiple HTML5 files)</li> </ul> -<div class="section"> -<h4 id="h_41">HTML/HTML5 output</h4> +<section class="section"> +<header><h1 id="h_41">HTML/HTML5 output</h1></header> <p>To compile a Glyph project to an HTML document, use the <a href="/glyph/book/ref_commands.html#c_compile"><code>compile</code></a> command within your Glyph project folder. Glyph parses the <code>document.glyph</code> file (and all included files and snippets); if no errors are found, Glyph creates an HTML document in the <code>/output/html</code> folder.</p> <p>The name of the HTML file can be set in the configuration (<a href="/glyph/book/config/document.html#s_document_filename"><code>document.filename</code></a> setting).</p> <p>To create an HTML5 file instead, you must specify it explicitly like this:</p>@@ -75,9 +77,9 @@ <p>
<code>glyph compile -f html5</code> </p> -</div> -<div class="section"> -<h4 id="h_42">PDF Output</h4> +</section> +<section class="section"> +<header><h1 id="h_42">PDF Output</h1></header> <p>To generate a PDF document, you must specify <code>pdf</code> as format, like this:</p> <p> <code>glyph compile -f pdf</code>@@ -89,18 +91,18 @@ <li><a href="http://www.princexml.com/">Prince</a> (version 7.0 or higher) — a commercial generator that can be used freely for personal use. Prince produces high-quality <span class="caps">PDF</span> files and implement most of the new features introduced in CSS3, used heavily in Glyph’s <a href="/glyph/book/text_editing/stylesheets.html#default_stylesheets"><code>pagination.css</code></a> default stylesheet.</li>
<li><a href="http://code.google.com/p/wkhtmltopdf/">wkhtmltopdf</a> (version 1.0 beta4 or higher) — an open source generator that uses the WebKit rendering engine to transform <span class="caps">HTML</span> files into <span class="caps">PDF</span>. Although not as advanced as Prince, it produces very satisfactory results.</li> </ul> <p>By default, Glyph attempts to use wkhtmltopdf. To change this, set the <a href="/glyph/book/config/output.html#s_output_pdf_generator"><code>output_pdf_generator</code></a> setting to <code>prince</code>.</p> - <div class="note"> + <aside class="note"> <span class="note-title">Note</span>Glyph expects PDF generators to be installed on the local machine and callable via command line using the <code>wkhtmltopdf</code> or the <code>prince</code> commands. Just install them as you would with any other program, depending on your operating system (yes, they both offer Windows installers). -</div> - <div class="tip"> +</aside> + <aside class="tip"> <span class="note-title">Tip</span>Glyph's default CSS file use the free <em>Gentium</em> font for all text. You can download it from <a href="http://www.sil.org/~gaultney/gentium/">here</a>. -</div> +</aside> -</div> -<div class="section"> -<h4 id="web_output">Web/Web5 Output</h4> +</section> +<section class="section"> +<header><h1 id="web_output">Web/Web5 Output</h1></header> <p>To generate a Web or Web5 output, specify <code>web</code> or <code>web5</code> as format. These two output formats behave different way from the others, and require that your project uses <a href="/glyph/book/text_editing/topics.html#topics">topics</a> and <a href="/glyph/book/extending/layouts.html#layouts">layouts</a>.</p> <p>Basically, here’s what happens when you compile your project in web or web5 format:</p> <ol>@@ -109,96 +111,74 @@ <li>Separate topic files are generated according to the <code>@src</code> attributes of your sections</li>
<li>The <code>document.glyph</code> (or whatever file you’re using as document source) is <em>not</em> rendered. Instead, an <code>index.html</code> file will be created in the output folder based on the contents of your <a href="/glyph/book/extending/layouts.html#index_layout">index layout</a>.</li> </ol> -</div> -<div class="section"> -<h4 id="auto_regeneration">Auto Regeneration</h4> +</section> +<section class="section"> +<header><h1 id="auto_regeneration">Auto Regeneration</h1></header> <p>You can also call the <a href="/glyph/book/ref_commands.html#c_compile"><code>compile</code></a> command with a <code>--auto</code> switch. If you do so, your project will be recompiled automatically every time any source file is changed.</p> - <div class="note"> + <aside class="note"> <span class="note-title">Note</span>Auto regeneration requires the <a href="http://rubygems.org/gems/directory_watcher">directory_watcher</a> gem to be installed. -</div> +</aside> -</div> - <div class="navigation"><a href="/glyph/book/text_editing/conditionals.html">Conditional Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/lite_mode.html">→ Compiling single Glyph files</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/compile.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/text_editing/conditionals.html">Conditional Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/lite_mode.html">→ Compiling single Glyph files</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,72 +1,74 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Compiling single Glyph files</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Compiling single Glyph files – Glyph Documentation</title> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>Compiling single Glyph files</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/compiling/compiling.html">Compiling a project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/programmatic_usage.html">→ Using Glyph programmatically</a></div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Compiling single Glyph files</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/compiling/compiling.html">Compiling a project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/programmatic_usage.html">→ Using Glyph programmatically</a></nav> <p>Glyph's primary goal is to author complex documents like books or manuals. In order to do so, a Glyph project is required to keep everything organized and automated via a set of predefined conventions, exactly like Ruby on Rails or other similar frameworks do.</p> <p>If you want to write a one-page article or a short draft, however, creating and managing Glyph projects can be an unnecessary burden. Luckily, you don't have to: you can use Glyph to compile single files containing Glyph code, by adding one parameter (or two if you want to specify a custom destination file) to the <a href="/glyph/book/ref_commands.html#c_compile"><code>compile</code></a> command, like this:</p> <p> <code>glyph compile source.glyph destination.htm</code> </p> <p>This command will process a file called <code>source.glyph</code> and produce an HTML file called <code>destination.htm</code>.</p> - <div class="section"> -<h4 id="lite_limitations">Limitations</h4> + <section class="section"> +<header><h1 id="lite_limitations">Limitations</h1></header> <p>This sort of “lite” mode comes with a few minor limitations:</p> <ul> <li>Snippets can only be defined inside the source file, using the <a href="/glyph/book/macros/macros_core.html#m_snippet_"><code>snippet:</code></a> macro.</li>@@ -77,87 +79,65 @@ <li>Stylesheets must be referenced with their absolute path, or a path relative to the current directory, or the name of an existing Glyph <a href="/glyph/book/text_editing/stylesheets.html#default_stylesheets">system stylesheet</a>.</li>
<li>The files included through the <a href="/glyph/book/macros/macros_core.html#m_include"><code>include</code></a> macro must be referenced with their absolute path, or a path relative to the current directory.</li> </ul> -</div> - <div class="navigation"><a href="/glyph/book/compiling/compiling.html">Compiling a project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/programmatic_usage.html">→ Using Glyph programmatically</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/lite_mode.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/compiling/compiling.html">Compiling a project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/programmatic_usage.html">→ Using Glyph programmatically</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Using Glyph programmatically</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Using Glyph programmatically – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Using Glyph programmatically</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Using Glyph programmatically</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/compiling/lite_mode.html">Compiling single Glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/stats.html">→ Using the stats command</a></div> + <nav><a href="/glyph/book/compiling/lite_mode.html">Compiling single Glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/stats.html">→ Using the stats command</a></nav> <p>Besides using Glyph from the command line, you can also use it straight from your code. Glyph’s public <a href="http://yardoc.org/docs/glyph/Glyph"><span class="caps">API</span></a> is simple and can be used to:</p> <ul> <li>Retrieve and update configuration settings (using <code>Glyph[]</code> and <code>Glyph[]=</code>)</li>@@ -66,16 +68,16 @@ <li>Filter text to <span class="caps">HTML</span> (using <code>Glyph#filter</code>)</li>
<li>Compile Glyph source files into <span class="caps">HTML</span> or <span class="caps">PDF</span> files (using <code>Glyph#compile</code>)</li> </ul> <p>That’s pretty much it. Of course, both the <code>filter</code> and <code>compile</code> method cause Glyph to run in <a href="/glyph/book/compiling/lite_mode.html#lite_mode"><em>lite</em> mode</a>, so the same <a href="/glyph/book/compiling/lite_mode.html#lite_limitations">limitations</a> apply.</p> - <div class="tip"> + <aside class="tip"> <span class="note-title">Tip</span><p>For an example on how to use Glyph programmatically (specifically in conjunction with the <a href="http://nanoc.stoneship.org/">nanoc</a> static site generator), see <a href="http://github.com/h3rald/h3rald">h3rald.com source code</a>, in particular:</p> <ul> <li><a href="http://github.com/h3rald/h3rald/blob/master/lib/glyph_filter.rb">lib/glyph_filter.rb</a> — using the <code>Glyph#filter</code> method.</li> - <li><a href="http://github.com/h3rald/h3rald/blob/master/Rules">Rules</a> — using the <code>Glyph#compile</code> method to generate <span class="caps">PDF</span> files.</li> + <li><a href="http://github.com/h3rald/h3rald/blob/master/lib/glyph_context.rb">lib/glyph_context.rb</a> — using the <code>Glyph#compile</code> method to generate <span class="caps">PDF</span> files.</li> </ul> -</div> - <div class="section"> -<h4 id="modes">Modes</h4> +</aside> + <section class="section"> +<header><h1 id="modes">Modes</h1></header> <p>It is possible to specify some flags (or "modes") to make Glyph behave slightly different than normal, as shown in the following table (by default, none of these is used).</p> <table><tr><th>Name</th> <th>Writer Method</th>@@ -133,87 +135,65 @@ <li><a href="/glyph/book/macros/macros_core.html#m_rewrite_"><code>rewrite:</code></a> macro</li>
<li><a href="/glyph/book/macros/macros_core.html#m_config_"><code>config:</code></a> macro</li> </ul></td></tr></table> -</div> - <div class="navigation"><a href="/glyph/book/compiling/lite_mode.html">Compiling single Glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/stats.html">→ Using the stats command</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_24.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/compiling/lite_mode.html">Compiling single Glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/stats.html">→ Using the stats command</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - document.*</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>document.* – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>document.*</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>document.*</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/macros/macros_structure.html">Structure Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/filters.html">→ filters.*</a></div> + <nav><a href="/glyph/book/macros/macros_structure.html">Structure Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/filters.html">→ filters.*</a></nav> The following configuration settings are related to the current Glyph document. Therefore, you should update them right after creating a project. <table><tr><th>Name</th>@@ -121,86 +123,64 @@ <code>document.title</code> <a id="s_document_title"></a>
</td> <td><p>The title of the document, displayed using the <a href="/glyph/book/macros/macros_block.html#m_title"><code>title</code></a> macro.</p></td> <td><code>""</code></td></tr></table> - <div class="navigation"><a href="/glyph/book/macros/macros_structure.html">Structure Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/filters.html">→ filters.*</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/cfg_document.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/macros/macros_structure.html">Structure Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/filters.html">→ filters.*</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - filters.*</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>filters.* – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>filters.*</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>filters.*</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/config/document.html">document.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/options.html">→ options.*</a></div> + <nav><a href="/glyph/book/config/document.html">document.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/options.html">→ options.*</a></nav> These settings are used to configure some special options related to output filters and highlighters. <table><tr><th>Name</th>@@ -101,86 +103,64 @@ <code>filters.ultraviolet.theme</code> <a id="s_filters_ultraviolet_theme"></a>
</td> <td><p>The theme used by the <a href="http://ultraviolet.rubyforge.org/">Ultraviolet</a> highlighter.</p></td> <td><code>"lazy"</code></td></tr></table> - <div class="navigation"><a href="/glyph/book/config/document.html">document.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/options.html">→ options.*</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/cfg_filters.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/config/document.html">document.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/options.html">→ options.*</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - options.*</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>options.* – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>options.*</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>options.*</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/config/filters.html">filters.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/output.html">→ output.*</a></div> + <nav><a href="/glyph/book/config/filters.html">filters.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/output.html">→ output.*</a></nav> The following configuration settings are used to enable or disable specific Glyph functionalities and behaviors. <table><tr><th>Name</th>@@ -67,7 +69,7 @@ <th>Default</th></tr>
<tr><td> <code>options.filters_by_file_extension</code> <a id="s_options_filters_by_file_extension"></a> </td> - <td><p>If set to <code>true</code>, a filter macro is applied to included files, based on their extensions (<span class="fmi">for more information on including files, see <a href="/glyph/book/text_editing/inclusions.html#incl">Including Files and Snippets</a></span>).</p></td> + <td><p>If set to <code>true</code>, a filter macro is applied to included files, based on their extensions (<span class="fmi">for more information on <mark>including files</mark>, see <a href="/glyph/book/text_editing/inclusions.html#incl">Including Files and Snippets</a></span>).</p></td> <td><code>nil</code></td></tr> <tr><td> <code>options.macro_set</code> <a id="s_options_macro_set"></a>@@ -82,7 +84,7 @@ <td><code>"glyph"</code></td></tr>
<tr><td> <code>options.safe_mode</code> <a id="s_options_safe_mode"></a> </td> - <td><p>Enables Safe Mode (<span class="fmi">for more information on Glyph modes, see <a href="/glyph/book/compiling/programmatic_usage.html#modes">Modes</a></span>).</p></td> + <td><p>Enables Safe Mode (<span class="fmi">for more information on <mark>Glyph modes</mark>, see <a href="/glyph/book/compiling/programmatic_usage.html#modes">Modes</a></span>).</p></td> <td><code>false</code></td></tr> <tr><td> <code>options.url_validation</code> <a id="s_options_url_validation"></a>@@ -99,86 +101,64 @@ <code>options.xml_fallback</code> <a id="s_options_xml_fallback"></a>
</td> <td><p>If set to true, any unknown macro name will considered an <span class="caps">XML</span> element (see <a href="/glyph/book/document.html#other_elements">Other <span class="caps">HTML</span> Elements</a>).</p></td> <td><code>true</code></td></tr></table> - <div class="navigation"><a href="/glyph/book/config/filters.html">filters.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/output.html">→ output.*</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/cfg_options.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/config/filters.html">filters.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/output.html">→ output.*</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - output.*</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>output.* – Glyph Documentation</title> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>output.*</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/config/options.html">options.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/changelog.html">→ Changelog</a></div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>output.*</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/config/options.html">options.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/changelog.html">→ Changelog</a></nav>@@ -70,8 +72,8 @@
These settings are used to configure output-specific options. -<div class="section"> -<h4 id="h_225">output.pdf.*</h4> +<section class="section"> +<header><h1 id="h_225">output.pdf.*</h1></header> <table><tr><th>Name</th> <th>Description</th> <th>Default</th></tr>@@ -101,9 +103,9 @@ </td>
<td><p>If set to <em>true_, the document will be rendered in multiple files, according to the specified </em>editing/topics.html#topics">topics</a>.</p></td> <td><code>false</code></td></tr></table> -</div> -<div class="section"> -<h4 id="h_226">output.html.*</h4> +</section> +<section class="section"> +<header><h1 id="h_226">output.html.*</h1></header> <table><tr><th>Name</th> <th>Description</th> <th>Default</th></tr>@@ -128,9 +130,9 @@ </td>
<td><p>If set to <em>true_, the document will be rendered in multiple files, according to the specified </em>editing/topics.html#topics">topics</a>.</p></td> <td><code>false</code></td></tr></table> -</div> -<div class="section"> -<h4 id="h_227">output.html5.*</h4> +</section> +<section class="section"> +<header><h1 id="h_227">output.html5.*</h1></header> <table><tr><th>Name</th> <th>Description</th> <th>Default</th></tr>@@ -155,9 +157,9 @@ </td>
<td><p>If set to <em>true_, the document will be rendered in multiple files, according to the specified </em>editing/topics.html#topics">topics</a>.</p></td> <td><code>false</code></td></tr></table> -</div> -<div class="section"> -<h4 id="h_228">output.web.*</h4> +</section> +<section class="section"> +<header><h1 id="h_228">output.web.*</h1></header> <table><tr><th>Name</th> <th>Description</th> <th>Default</th></tr>@@ -202,9 +204,9 @@ </td>
<td><p>If set to <em>true_, the document will be rendered in multiple files, according to the specified </em>editing/topics.html#topics">topics</a>.</p></td> <td><code>true</code></td></tr></table> -</div> -<div class="section"> -<h4 id="h_229">output.web5.*</h4> +</section> +<section class="section"> +<header><h1 id="h_229">output.web5.*</h1></header> <table><tr><th>Name</th> <th>Description</th> <th>Default</th></tr>@@ -249,87 +251,65 @@ </td>
<td><p>If set to <em>true_, the document will be rendered in multiple files, according to the specified </em>editing/topics.html#topics">topics</a>.</p></td> <td><code>true</code></td></tr></table> -</div> - <div class="navigation"><a href="/glyph/book/config/options.html">options.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/changelog.html">→ Changelog</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/cfg_output.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/config/options.html">options.* ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/changelog.html">→ Changelog</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,155 +1,137 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Bookmarks and Headers</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Bookmarks and Headers – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Bookmarks and Headers</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Bookmarks and Headers</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/params_attrs.html">Parameters and Attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/placeholders.html">→ Using Placeholders</a></div> + <nav><a href="/glyph/book/extending/params_attrs.html">Parameters and Attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/placeholders.html">→ Using Placeholders</a></nav> <p>The <a href="http://yardoc.org/docs/h3rald-glyph/Macro"><code>Glyph::Macro</code></a> class also includes a few methods to check and store bookmarks and headers. Consider for example the following source code for the <a href="/glyph/book/macros/macros_inline.html#m_anchor"><code>anchor</code></a> macro:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> macro <span class="Constant"><span class="Constant">:</span>anchor</span> <span class="Keyword">do </span> -<span class="line-numbers"> 2 </span> ident, title <span class="Keyword">=</span> <span class="Variable"><span class="Variable">@</span>params</span> -<span class="line-numbers"> 3 </span> macro_error <span class="String"><span class="String">"</span>Bookmark '<span class="String"><span class="String">#{</span>ident<span class="String">}</span></span>' already exists<span class="String">"</span></span> <span class="Keyword">if</span> bookmark? ident -<span class="line-numbers"> 4 </span> bookmark <span class="Constant"><span class="Constant">:</span>id</span> => ident, <span class="Constant"><span class="Constant">:</span>title</span> => title -<span class="line-numbers"> 5 </span> <span class="String"><span class="String">%{</span><a id="<span class="String"><span class="String">#{</span>ident<span class="String">}</span></span>"><span class="String"><span class="String">#{</span>title<span class="String">}</span></span></a><span class="String">}</span></span> -<span class="line-numbers"> 6 </span> <span class="Keyword">end</span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> macro <span class="sy">:anchor</span> <span class="r">do</span> +<span class="no">2</span> ident, title = <span class="iv">@params</span> +<span class="no">3</span> macro_error <span class="s"><span class="dl">"</span><span class="k">Bookmark '</span><span class="il"><span class="idl">#{</span>ident<span class="idl">}</span></span><span class="k">' already exists</span><span class="dl">"</span></span> <span class="r">if</span> bookmark? ident +<span class="no">4</span> bookmark <span class="sy">:id</span> => ident, <span class="sy">:title</span> => title +<span class="no">5</span> <span class="s"><span class="dl">%{</span><span class="k"><a id="</span><span class="il"><span class="idl">#{</span>ident<span class="idl">}</span></span><span class="k">"></span><span class="il"><span class="idl">#{</span>title<span class="idl">}</span></span><span class="k"></a></span><span class="dl">}</span></span> +<span class="no">6</span> <span class="r">end</span></pre></div> +</div> + <p>The <code>bookmark?</code> method can be used to check the existance of a particular ID within the whole document, while the <code>bookmark</code> method is used to store bookmark IDs and titles. In a similar way, you can use <code>header?</code> and <code>header</code> methods to check the existance of headers within the documents or store new ones.</p> - <div class="navigation"><a href="/glyph/book/extending/params_attrs.html">Parameters and Attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/placeholders.html">→ Using Placeholders</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_33.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/extending/params_attrs.html">Parameters and Attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/placeholders.html">→ Using Placeholders</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,190 +1,175 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Defining Custom Commands</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Defining Custom Commands – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Defining Custom Commands</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Defining Custom Commands</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/output_format.html">Custom Output Formats ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_generic.html">→ Generic Errors</a></div> + <nav><a href="/glyph/book/extending/output_format.html">Custom Output Formats ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_generic.html">→ Generic Errors</a></nav> <p>Glyph relies on <a href="http://davetron5000.github.com/gli/"><span class="caps">GLI</span></a> for defining commands. This useful library provides a high-level framework for creating command-line interface similar to <a href="http://git-scm.com/">Git</a>, its <span class="caps">DSL</span> takes care of pretty much everything, from managing command line arguments and options to providing an interactive help system.</p> -<div class="section"> -<h5 id="h_96">Creating a 'glyph generate' command</h5> +<section class="section"> +<header><h1 id="h_96">Creating a 'glyph generate' command</h1></header> <p>Consider the custom task defined in <a href="/glyph/book/extending/task.html#custom_generate_task">Creating a ‘custom:generate’ task</a>. Creating a custom command to call it is fairly straightforward.</p> <p>First of all, create a <code>lib/commands</code> folder in your project directory. Then, create a <code>.rb</code> file within it, e.g. <code>commands.rake</code>.</p> <p>Finally, here’s the source of the command:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="Variable">GLI</span>.<span class="Entity">desc</span> <span class="String"><span class="String">'</span>Generates a specific file required for Glyph releases<span class="String">'</span></span> -<span class="line-numbers"> 2 </span> arg_name <span class="String"><span class="String">"</span>file_name<span class="String">"</span></span> -<span class="line-numbers"> 3 </span> command <span class="Constant"><span class="Constant">:</span>generate</span> <span class="Keyword">do </span>|<span class="Variable">c</span>| -<span class="line-numbers"> 4 </span> c.<span class="Entity">action</span> <span class="Keyword">do </span>|<span class="Variable">global_options</span>,<span class="Variable">options</span>,<span class="Variable">args</span>| -<span class="line-numbers"> 5 </span> <span class="Keyword">if</span> args.<span class="Entity">blank?</span> <span class="Keyword">then</span> -<span class="line-numbers"> 6 </span> <span class="Keyword">raise</span> <span class="Variable">RuntimeError</span>, <span class="String"><span class="String">"</span>You must specify a file to generate<span class="String">"</span></span> -<span class="line-numbers"> 7 </span> <span class="Keyword">else</span> -<span class="line-numbers"> 8 </span> <span class="Support">Glyph</span>.<span class="Entity">run</span> <span class="String"><span class="String">'</span>custom:generate<span class="String">'</span></span>, args[<span class="Constant">0</span>] -<span class="line-numbers"> 9 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 10 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 11 </span> <span class="Keyword">end</span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> <span class="co">GLI</span>.desc <span class="s"><span class="dl">'</span><span class="k">Generates a specific file required for Glyph releases</span><span class="dl">'</span></span> +<span class="no"> 2</span> arg_name <span class="s"><span class="dl">"</span><span class="k">file_name</span><span class="dl">"</span></span> +<span class="no"> 3</span> command <span class="sy">:generate</span> <span class="r">do</span> |c| +<span class="no"> 4</span> c.action <span class="r">do</span> |global_options,options,args| +<span class="no"> 5</span> <span class="r">if</span> args.blank? <span class="r">then</span> +<span class="no"> 6</span> raise <span class="co">RuntimeError</span>, <span class="s"><span class="dl">"</span><span class="k">You must specify a file to generate</span><span class="dl">"</span></span> +<span class="no"> 7</span> <span class="r">else</span> +<span class="no"> 8</span> <span class="co">Glyph</span>.run <span class="s"><span class="dl">'</span><span class="k">custom:generate</span><span class="dl">'</span></span>, args[<span class="i">0</span>] +<span class="no"> 9</span> <span class="r">end</span> +<span class="no"><strong>10</strong></span> <span class="r">end</span> +<span class="no">11</span> <span class="r">end</span></pre></div> +</div> + <p>That’s it. If you try to run <code>glyph help</code> within your project directory, notice that there’s a new entry for the generate command:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> $ glyph help -<span class="line-numbers"> 2 </span> ===================================== -<span class="line-numbers"> 3 </span> Glyph v.0.4.0 -<span class="line-numbers"> 4 </span> ===================================== -<span class="line-numbers"> 5 </span> usage: glyph command [options] -<span class="line-numbers"> 6 </span> -<span class="line-numbers"> 7 </span> Options: -<span class="line-numbers"> 8 </span> -d, --debug - Enable debugging -<span class="line-numbers"> 9 </span> -<span class="line-numbers"> 10 </span> Commands: -<span class="line-numbers"> 11 </span> add - Add a new text file to the project -<span class="line-numbers"> 12 </span> compile - Compile the project -<span class="line-numbers"> 13 </span> config - Get/set configuration settings -<span class="line-numbers"> 14 </span> generate - Generates a specific file required for Glyph releases -<span class="line-numbers"> 15 </span> help - Shows list of commands or help for one command -<span class="line-numbers"> 16 </span> init - Create a new Glyph project -<span class="line-numbers"> 17 </span> outline - Display the document outline -<span class="line-numbers"> 18 </span> stats - Display statistics -<span class="line-numbers"> 19 </span> todo - Display all project TODO items -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> $ glyph help +<span class="no"> 2</span> ===================================== +<span class="no"> 3</span> Glyph v.0.4.1 +<span class="no"> 4</span> ===================================== +<span class="no"> 5</span> usage: glyph command [options] +<span class="no"> 6</span> +<span class="no"> 7</span> Options: +<span class="no"> 8</span> -d, --debug - Enable debugging +<span class="no"> 9</span> +<span class="no"><strong>10</strong></span> Commands: +<span class="no">11</span> add - Add a new text file to the project +<span class="no">12</span> compile - Compile the project +<span class="no">13</span> config - Get/set configuration settings +<span class="no">14</span> generate - Generates a specific file required for Glyph releases +<span class="no">15</span> help - Shows list of commands or help for one command +<span class="no">16</span> init - Create a new Glyph project +<span class="no">17</span> outline - Display the document outline +<span class="no">18</span> stats - Display statistics +<span class="no">19</span> todo - Display all project TODO items</pre></div> +</div> + <p>You can now run the Glyph command as expected:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> $ glyph -d generate changelog -<span class="line-numbers"> 2 </span> -- Generating CHANGELOG... -<span class="line-numbers"> 3 </span> -- Done. -</pre> - + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> $ glyph -d generate changelog +<span class="no">2</span> -- Generating CHANGELOG... +<span class="no">3</span> -- Done.</pre></div> </div> - <div class="navigation"><a href="/glyph/book/extending/output_format.html">Custom Output Formats ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_generic.html">→ Generic Errors</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/custom_command.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + +</section> + <nav><a href="/glyph/book/extending/output_format.html">Custom Output Formats ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_generic.html">→ Generic Errors</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,72 +1,74 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Defining Custom Commands and Tasks</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Defining Custom Commands and Tasks – Glyph Documentation</title> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>Defining Custom Commands and Tasks</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/further_reading.html">Further Reading ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/task.html">→ Defining Custom Tasks</a></div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Defining Custom Commands and Tasks</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/extending/further_reading.html">Further Reading ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/task.html">→ Defining Custom Tasks</a></nav> <p>In most cases, you can extend Glyph just by creating your own <a href="/glyph/book/extending/macro_def.html#macro_def">custom macros</a>. In some cases though, you may want to further customize Glyph to fit the needs of your project, in terms of creating <a href="/glyph/book/extending/command.html#custom_command">custom commands</a> and <a href="/glyph/book/extending/task.html#custom_task">custom tasks</a>.</p> <p>Glyph’s modular architecture (and the Ruby language itself) lets you to add <em>arbitrary</em> functionality to its core, simply by creating a few Ruby files and putting them in the right places.</p> -<div class="section"> -<h4 id="cmd_tasks_arch">How Commands and Tasks work</h4> +<section class="section"> +<header><h1 id="cmd_tasks_arch">How Commands and Tasks work</h1></header> <p>Before creating custom Glyph commands and tasks, you should have a basic understanding on how they work, and which commands — or better, which tasks — are already available.</p> <p>The following diagram outlines the relationships between commands and tasks:</p> - <div class="figure"><img alt="-" src="/glyph/book/images/glyph/commands_tasks.png" /> - <div class="caption">Glyph default commands and tasks</div></div> + <figure><img alt="-" src="/glyph/book/images/glyph/commands_tasks.png" /> + <figcaption>Glyph default commands and tasks</figcaption></figure> <p>As you can see:</p> <ul> <li>All commands call at at least one task.</li>@@ -77,7 +79,7 @@ <li><code>load:</code> — used to load all kinds of files.</li>
<li><code>generate:</code> — used to generate files or copy files from source to output directories</li> </ul></li> </ul> - <div class="box"> + <aside class="box"> <div class="box-title">Example</div> <p>Suppose you want to generate a <span class="caps">PDF</span> file by issuing the <code>glyph compile -f pdf</code> command. Under the hood, Glyph calls the following tasks:</p> <ol>@@ -94,89 +96,67 @@ <li><code>generate:html</code> — Generate a standalone <span class="caps">HTML</span> file</li>
<li><code>generate:pdf</code> — Generate a <span class="caps">PDF</span> file from a standalone <span class="caps">HTML</span> file</li> </ol> -</div> +</aside> -</div> - <div class="navigation"><a href="/glyph/book/extending/further_reading.html">Further Reading ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/task.html">→ Defining Custom Tasks</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_39.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/extending/further_reading.html">Further Reading ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/task.html">→ Defining Custom Tasks</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Further Reading</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Further Reading – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Further Reading</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Further Reading</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/layouts.html">Layouts ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/commands_tasks.html">→ Defining Custom Commands and Tasks</a></div> + <nav><a href="/glyph/book/extending/layouts.html">Layouts ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/commands_tasks.html">→ Defining Custom Commands and Tasks</a></nav> <p>For more examples on how to create more complex macros, have a look at the <a href="http://github.com/h3rald/glyph/tree/master/macros/">source code</a> of the existing ones.</p> <p>To gain a deeper understanding on how macros are executed, have a look at the following Glyph classes:</p> <ul>@@ -68,86 +70,64 @@ <li><a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Interpreter"><code>Glyph::Interpreter</code></a></li>
<li><a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Document"><code>Glyph::Document</code></a></li> <li><a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Macro"><code>Glyph::Macro</code></a></li> </ul> - <div class="navigation"><a href="/glyph/book/extending/layouts.html">Layouts ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/commands_tasks.html">→ Defining Custom Commands and Tasks</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_38.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/extending/layouts.html">Layouts ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/commands_tasks.html">→ Defining Custom Commands and Tasks</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,218 +1,205 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - A quick look at Glyph's internals</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>A quick look at Glyph's internals – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>A quick look at Glyph's internals</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>A quick look at Glyph's internals</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/stats/links.html">Link Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/macro_def.html">→ Defining Custom Macros</a></div> + <nav><a href="/glyph/book/stats/links.html">Link Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/macro_def.html">→ Defining Custom Macros</a></nav> <p>If you plan on extending Glyph, knowing how it works inside helps. It is not mandatory by any means, but it definitely helps, especially when creating complex macros.</p> <p>What happens behind the scenes when you call <code>glyph compile</code>? Glyph's code is parsed, analyzed and then translated into text, and here's how:</p> - <div class="figure"><img alt="-" src="/glyph/book/images/glyph/document_generation.png" /> - <div class="caption">A sequence diagram for document generation</div></div> + <figure><img alt="-" src="/glyph/book/images/glyph/document_generation.png" /> + <figcaption>A sequence diagram for document generation</figcaption></figure> <p>From the diagram, it is possible to divide the document generation process into three phases:</p> <ul> <li>The <em>Parsing Phase</em> starts when a chunk of Glyph code is passed (by the <code>generate:document</code> Rake task, for example) to a <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Interpreter"><code>Glyph::Interpreter</code></a>. The interpreter initializes a <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Parser"><code>Glyph::Parser</code></a> that parses the code and returns an <em>Abstract Syntax Tree</em> (<span class="caps">AST</span>) of <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/SyntaxNode"><code>Glyph::SyntaxNode</code></a> objects.</li> <li>The <em>Analysis Phase</em> (Processing) starts when the interpreter method calls the <code>analyze</code> method, instantiating a new <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Document"><code>Glyph::Document</code></a>. The <code>Glyph::Document</code> object evaluates the <span class="caps">AST</span> expanding all macro nodesth (that’s when macros are executed) and generates string.</li> <li>The <em>Finalization Phase</em> (Post-Processing) starts when the interpreter calls the <code>finalyze</code> method, causing the <code>Glyph::Document</code> object to perform a series of finalizations on the string obtained after analysis, i.e. it replaces escape sequences and placeholders.</li> </ul> - <div class="section"> -<h4 id="h_73">Example: A short note</h4> + <section class="section"> +<header><h1 id="h_73">Example: A short note</h1></header> <p>As an example, consider the following Glyph code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> fmi[something|#test] -<span class="line-numbers"> 2 </span> ... -<span class="line-numbers"> 3 </span> section[ -<span class="line-numbers"> 4 </span> @title[Test Section] -<span class="line-numbers"> 5 </span> @id[test] -<span class="line-numbers"> 6 </span> ... -<span class="line-numbers"> 7 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> fmi[something|#test] +<span class="no">2</span> ... +<span class="no">3</span> section[ +<span class="no">4</span> @title[Test Section] +<span class="no">5</span> @id[test] +<span class="no">6</span> ... +<span class="no">7</span> ]</pre></div> +</div> + <p>This simple snippet uses the <a href="/glyph/book/macros/macros_inline.html#m_fmi"><code>fmi</code></a> macro to link to a section later on in the document. When parsed, the produced AST is the following:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:"</span>--<span class="Constant">"</span></span>} -<span class="line-numbers"> 2 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:</span>fmi</span>, <span class="Constant"><span class="Constant">:</span>escape</span>=><span class="Constant">false</span>} -<span class="line-numbers"> 3 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:"</span>0<span class="Constant">"</span></span>} -<span class="line-numbers"> 4 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span>something<span class="String">"</span></span>} -<span class="line-numbers"> 5 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:"</span>1<span class="Constant">"</span></span>} -<span class="line-numbers"> 6 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span>#test<span class="String">"</span></span>} -<span class="line-numbers"> 7 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\n</span><span class="String">"</span></span>} -<span class="line-numbers"> 8 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\</span>[<span class="String">"</span></span>, <span class="Constant"><span class="Constant">:</span>escaped</span>=><span class="Constant">true</span>} -<span class="line-numbers"> 9 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span>...<span class="String">"</span></span>} -<span class="line-numbers"> 10 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\</span>]<span class="String">"</span></span>, <span class="Constant"><span class="Constant">:</span>escaped</span>=><span class="Constant">true</span>} -<span class="line-numbers"> 11 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\n</span><span class="String">"</span></span>} -<span class="line-numbers"> 12 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:</span>section</span>, <span class="Constant"><span class="Constant">:</span>escape</span>=><span class="Constant">false</span>} -<span class="line-numbers"> 13 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:"</span>0<span class="Constant">"</span></span>} -<span class="line-numbers"> 14 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\n</span><span class="Constant">\t</span><span class="String">"</span></span>} -<span class="line-numbers"> 15 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\n</span><span class="Constant">\t</span><span class="String">"</span></span>} -<span class="line-numbers"> 16 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\n</span><span class="String">"</span></span>} -<span class="line-numbers"> 17 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\</span>[<span class="String">"</span></span>, <span class="Constant"><span class="Constant">:</span>escaped</span>=><span class="Constant">true</span>} -<span class="line-numbers"> 18 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span>...<span class="String">"</span></span>} -<span class="line-numbers"> 19 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\</span>]<span class="String">"</span></span>, <span class="Constant"><span class="Constant">:</span>escaped</span>=><span class="Constant">true</span>} -<span class="line-numbers"> 20 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span><span class="Constant">\n</span><span class="String">"</span></span>} -<span class="line-numbers"> 21 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:</span>title</span>, <span class="Constant"><span class="Constant">:</span>escape</span>=><span class="Constant">false</span>} -<span class="line-numbers"> 22 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span>Test Section<span class="String">"</span></span>} -<span class="line-numbers"> 23 </span> {<span class="Constant"><span class="Constant">:</span>name</span>=><span class="Constant"><span class="Constant">:</span>id</span>, <span class="Constant"><span class="Constant">:</span>escape</span>=><span class="Constant">false</span>} -<span class="line-numbers"> 24 </span> {<span class="Constant"><span class="Constant">:</span>value</span>=><span class="String"><span class="String">"</span>test<span class="String">"</span></span>} -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> {<span class="sy">:name</span>=><span class="sy"><span class="sy">:</span><span class="dl">"</span><span class="k">--</span><span class="dl">"</span></span>} +<span class="no"> 2</span> {<span class="sy">:name</span>=><span class="sy">:fmi</span>, <span class="sy">:escape</span>=><span class="pc">false</span>} +<span class="no"> 3</span> {<span class="sy">:name</span>=><span class="sy"><span class="sy">:</span><span class="dl">"</span><span class="k">0</span><span class="dl">"</span></span>} +<span class="no"> 4</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="k">something</span><span class="dl">"</span></span>} +<span class="no"> 5</span> {<span class="sy">:name</span>=><span class="sy"><span class="sy">:</span><span class="dl">"</span><span class="k">1</span><span class="dl">"</span></span>} +<span class="no"> 6</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="k">#test</span><span class="dl">"</span></span>} +<span class="no"> 7</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\n</span><span class="dl">"</span></span>} +<span class="no"> 8</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\</span><span class="k">[</span><span class="dl">"</span></span>, <span class="sy">:escaped</span>=><span class="pc">true</span>} +<span class="no"> 9</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="k">...</span><span class="dl">"</span></span>} +<span class="no"><strong>10</strong></span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\</span><span class="k">]</span><span class="dl">"</span></span>, <span class="sy">:escaped</span>=><span class="pc">true</span>} +<span class="no">11</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\n</span><span class="dl">"</span></span>} +<span class="no">12</span> {<span class="sy">:name</span>=><span class="sy">:section</span>, <span class="sy">:escape</span>=><span class="pc">false</span>} +<span class="no">13</span> {<span class="sy">:name</span>=><span class="sy"><span class="sy">:</span><span class="dl">"</span><span class="k">0</span><span class="dl">"</span></span>} +<span class="no">14</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\n</span><span class="ch">\t</span><span class="dl">"</span></span>} +<span class="no">15</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\n</span><span class="ch">\t</span><span class="dl">"</span></span>} +<span class="no">16</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\n</span><span class="dl">"</span></span>} +<span class="no">17</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\</span><span class="k">[</span><span class="dl">"</span></span>, <span class="sy">:escaped</span>=><span class="pc">true</span>} +<span class="no">18</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="k">...</span><span class="dl">"</span></span>} +<span class="no">19</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\</span><span class="k">]</span><span class="dl">"</span></span>, <span class="sy">:escaped</span>=><span class="pc">true</span>} +<span class="no"><strong>20</strong></span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="ch">\n</span><span class="dl">"</span></span>} +<span class="no">21</span> {<span class="sy">:name</span>=><span class="sy">:title</span>, <span class="sy">:escape</span>=><span class="pc">false</span>} +<span class="no">22</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="k">Test Section</span><span class="dl">"</span></span>} +<span class="no">23</span> {<span class="sy">:name</span>=><span class="sy">:id</span>, <span class="sy">:escape</span>=><span class="pc">false</span>} +<span class="no">24</span> {<span class="sy">:value</span>=><span class="s"><span class="dl">"</span><span class="k">test</span><span class="dl">"</span></span>}</pre></div> +</div> + <p>This output is produced by calling the <code>inspect</code> method on the AST. Each <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/SyntaxNode"><code>Glyph::SyntaxNode</code></a> object in the tree is basically an ordinary Glyph Hash with a parent and 0 or more chidren, so the code snippets above shows how the syntax nodes are nested.</p> <p>The AST contains information about macro, parameter and attribute names, and escaping, and raw text values (the nodes without a <code>:name</code> key), but nothing more.</p> <p>When the AST is analyzed, the resulting textual output is the following:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">span</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>fmi<span class="String">"</span></span><span class="MetaTag">></span></span>for more information on something, see ‡‡‡‡‡PLACEHOLDER ¤ 1‡‡‡‡‡ -<span class="line-numbers"> 2 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">span</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> [...] -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>section<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 5 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">h2</span> <span class="MetaTag"><span class="MetaTag">id</span><span class="MetaTag">=</span><span class="String"><span class="String">"</span><span class="String">test</span><span class="String">"</span></span></span><span class="MetaTag">></span></span>Test Section<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">h2</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 6 </span> [...] -<span class="line-numbers"> 7 </span> -<span class="line-numbers"> 8 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> <span class="ta"><span</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">fmi</span><span class="dl">"</span></span><span class="ta">></span>for more information on something, see ‡‡‡‡‡PLACEHOLDER ¤ 1‡‡‡‡‡ +<span class="no">2</span> <span class="ta"></span></span> +<span class="no">3</span> \.[...\.] +<span class="no">4</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">section</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no">5</span> <span class="ta"><h2</span> <span class="an">id</span>=<span class="s"><span class="dl">"</span><span class="k">test</span><span class="dl">"</span></span><span class="ta">></span>Test Section<span class="ta"></h2></span> +<span class="no">6</span> \.[...\.] +<span class="no">7</span> +<span class="no">8</span> <span class="ta"></div></span></pre></div> +</div> + <p>This looks almost perfect, except that:</p> <ul><li>There's a nasty placeholder instead of a link: this is due to the fact that when the link is processed, there is no <code>#text</code> anchor in the document, but there may be one afterwards (and there will be).</li> <li>There are some escaped brackets.</li></ul> <p>Finally, when the document is finalized, placeholders and escape sequences are removed and the final result is the following:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">span</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>fmi<span class="String">"</span></span><span class="MetaTag">></span></span>for more information on something, -<span class="line-numbers"> 2 </span> see <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">a</span> <span class="MetaTag">href</span>=<span class="String"><span class="String">"</span>#test<span class="String">"</span></span><span class="MetaTag">></span></span>Test Section<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">a</span><span class="MetaTag">></span></span><span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">span</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> [...] -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>section<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 5 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">h2</span> <span class="MetaTag"><span class="MetaTag">id</span><span class="MetaTag">=</span><span class="String"><span class="String">"</span><span class="String">test</span><span class="String">"</span></span></span><span class="MetaTag">></span></span>Test Section<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">h2</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 6 </span> [...] -<span class="line-numbers"> 7 </span> -<span class="line-numbers"> 8 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -</pre> - + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> <span class="ta"><span</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">fmi</span><span class="dl">"</span></span><span class="ta">></span>for more information on something, +<span class="no">2</span> see <span class="ta"><a</span> <span class="an">href</span>=<span class="s"><span class="dl">"</span><span class="k">#test</span><span class="dl">"</span></span><span class="ta">></span>Test Section<span class="ta"></a></span><span class="ta"></span></span> +<span class="no">3</span> [...] +<span class="no">4</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">section</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no">5</span> <span class="ta"><h2</span> <span class="an">id</span>=<span class="s"><span class="dl">"</span><span class="k">test</span><span class="dl">"</span></span><span class="ta">></span>Test Section<span class="ta"></h2></span> +<span class="no">6</span> [...] +<span class="no">7</span> +<span class="no">8</span> <span class="ta"></div></span></pre></div> </div> - <div class="navigation"><a href="/glyph/book/stats/links.html">Link Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/macro_def.html">→ Defining Custom Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_30.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + +</section> + <nav><a href="/glyph/book/stats/links.html">Link Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/macro_def.html">→ Defining Custom Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,75 +1,79 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Interpreting Glyph Code</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Interpreting Glyph Code – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Interpreting Glyph Code</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Interpreting Glyph Code</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/validators.html">Using Validators ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/layouts.html">→ Layouts</a></div> + <nav><a href="/glyph/book/extending/validators.html">Using Validators ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/layouts.html">→ Layouts</a></nav> <p>What if you need to evaluate some Glyph code <em>within</em> a macro? Say for example you want to transform a parameter in a link, and you want to make sure that link gets validated exactly like the others, in this case, you can use the <code>interpret</code> method, as follows:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> macro <span class="Constant"><span class="Constant">:</span>fmi</span> <span class="Keyword">do</span> -<span class="line-numbers"> 2 </span> topic, href <span class="Keyword">=</span> <span class="Variable"><span class="Variable">@</span>params</span> -<span class="line-numbers"> 3 </span> link <span class="Keyword">=</span> placeholder <span class="Keyword">do </span>|<span class="Variable">document</span>| -<span class="line-numbers"> 4 </span> interpret <span class="String"><span class="String">"</span>link[<span class="String"><span class="String">#{</span>href<span class="String">}</span></span>]<span class="String">"</span></span> -<span class="line-numbers"> 5 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 6 </span> <span class="String"><span class="String">%{</span><span class="fmi">for more information on <span class="String"><span class="String">#{</span>topic<span class="String">}</span></span>, see <span class="String"><span class="String">#{</span>link<span class="String">}</span></span></span><span class="String">}</span></span> -<span class="line-numbers"> 7 </span> <span class="Keyword">end</span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> macro <span class="sy">:fmi</span> <span class="r">do</span> +<span class="no">2</span> topic, href = <span class="iv">@params</span> +<span class="no">3</span> link = placeholder <span class="r">do</span> |document| +<span class="no">4</span> interpret <span class="s"><span class="dl">"</span><span class="k">link[</span><span class="il"><span class="idl">#{</span>href<span class="idl">}</span></span><span class="k">]</span><span class="dl">"</span></span> +<span class="no">5</span> <span class="r">end</span> +<span class="no">6</span> <span class="s"><span class="dl">%{</span><span class="k"><span class="fmi">for more information on </span><span class="il"><span class="idl">#{</span>topic<span class="idl">}</span></span><span class="k">, see </span><span class="il"><span class="idl">#{</span>link<span class="idl">}</span></span><span class="k"></span></span><span class="dl">}</span></span> +<span class="no">7</span> <span class="r">end</span></pre></div> +</div> + <p>When the <code>interpret</code> method is called, the following happens:</p> <ol>@@ -78,111 +82,93 @@ <li>The bookmarks, headers and placeholders are passed from the main document to the new one. Because they are stored in arrays and hashes, they are passed by reference, so for example any new bookmark stored in the new document will also become available in the main document.</li>
<li>Any macro included in the <code>String</code> is evaluated, and the resulting text is returned by the method. Note that this new document does not get finalized: in other words, placeholders will be left as they are, and they’ll eventually be replaced when <em>the main document</em> is finalized.</li> </ol> - <div class="section"> -<h5 id="rewriting">Rewriting</h5> + <section class="section"> +<header><h1 id="rewriting">Rewriting</h1></header> <p>While the <code>interpret</code> method is useful to evaluate Glyph code in a macro while performing other actions (storing a bookmark, checking for the presence of an anchor, etc.), in some cases it may not be necessary. If you simply want your macro to be converted into existing Glyph macro without performing any action excepting parameter substitution, you can just use the <a href="/glyph/book/macros/macros_core.html#m_rewrite_"><code>rewrite:</code></a> macro within youy Glyph document</p> <p>Consider the following macro definition:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> macro <span class="Constant"><span class="Constant">:</span>issue</span> <span class="Keyword">do</span> -<span class="line-numbers"> 2 </span> interpret <span class="String"><span class="String">%{</span></span> -<span class="line-numbers"> 3 </span> <span class="String"> tr[</span> -<span class="line-numbers"> 4 </span> <span class="String"> td[.=>[http://github.com/h3rald/glyph/issues/closed#issue/<span class="String"><span class="String">#{</span>param<span class="String">[</span><span class="Constant">0</span><span class="String">]</span><span class="String">}</span></span>|#<span class="String"><span class="String">#{</span><span class="String"><span class="Entity">param</span></span><span class="String">(</span><span class="Constant">0</span><span class="String">)</span><span class="String">}</span></span>]]</span> -<span class="line-numbers"> 5 </span> <span class="String"> td[txt[<span class="String"><span class="String">#{</span><span class="String"><span class="Entity">param</span></span><span class="String">(</span><span class="Constant">1</span><span class="String">)</span><span class="String">}</span></span>]]</span> -<span class="line-numbers"> 6 </span> <span class="String"> ]</span> -<span class="line-numbers"> 7 </span> <span class="String"> <span class="String">}</span></span> -<span class="line-numbers"> 8 </span> <span class="Keyword">end</span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> macro <span class="sy">:issue</span> <span class="r">do</span> +<span class="no">2</span> interpret <span class="s"><span class="dl">%{</span><span class="k"> +<span class="no">3</span> tr[ +<span class="no">4</span> td[.=>[http://github.com/h3rald/glyph/issues/closed#issue/</span><span class="il"><span class="idl">#{</span>param[<span class="i">0</span>]<span class="idl">}</span></span><span class="k">|#</span><span class="il"><span class="idl">#{</span>param(<span class="i">0</span>)<span class="idl">}</span></span><span class="k">]] +<span class="no">5</span> td[txt[</span><span class="il"><span class="idl">#{</span>param(<span class="i">1</span>)<span class="idl">}</span></span><span class="k">]] +<span class="no">6</span> ] +<span class="no">7</span> </span><span class="dl">}</span></span> +<span class="no">8</span> <span class="r">end</span></pre></div> +</div> + <p>The <code>issue</code> macro is only rewriting existing Glyph code around the two parameters provided. In this case, it is possible to do exactly the same thing using the <a href="/glyph/book/macros/macros_core.html#m_rewrite_"><code>rewrite:</code></a> macro:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> rewrite:[issue| -<span class="line-numbers"> 2 </span> tr[ -<span class="line-numbers"> 3 </span> td[.=>[http://github.com/h3rald/glyph/issues/closed#issue/{{0}}|#{{0}}]] -<span class="line-numbers"> 4 </span> td[txt[{{1}}]] -<span class="line-numbers"> 5 </span> ] -<span class="line-numbers"> 6 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> rewrite:[issue| +<span class="no">2</span> tr[ +<span class="no">3</span> td[.=<span class="er">></span>[http://github.com/h3rald/glyph/issues/closed#issue/{{0}}|#{{0}}]] +<span class="no">4</span> td[txt[{{1}}]] +<span class="no">5</span> ] +<span class="no">6</span> ]</pre></div> +</div> + <p>Within the <a href="/glyph/book/macros/macros_core.html#m_rewrite_"><code>rewrite:</code></a> macro, it is possible to use a special syntax to call the <code>raw_attr</code> or <code>raw_param</code> methods: <br /> <code>{{</code><em>parameter_number</em> or <em>attribute_name</em><code>}}</code></p> -</div> - <div class="navigation"><a href="/glyph/book/extending/validators.html">Using Validators ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/layouts.html">→ Layouts</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/interpreting.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/extending/validators.html">Using Validators ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/layouts.html">→ Layouts</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,89 +1,93 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Layouts</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Layouts – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Layouts</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Layouts</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/interpreting.html">Interpreting Glyph Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/further_reading.html">→ Further Reading</a></div> + <nav><a href="/glyph/book/extending/interpreting.html">Interpreting Glyph Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/further_reading.html">→ Further Reading</a></nav> <p>When generating <a href="/glyph/book/text_editing/topics.html#topics">topic</a>-based outputs, Glyph uses <em>layouts</em> to render topics as standalone documents. By default, the following two layout are used:</p> <ul> <li><code>topic</code> — used to render standard topics.</li> <li><code>index</code> — used to render the index page of your document.</li> </ul> <p>Layouts are nothing more than “fancy” Glyph macros defined using the Glyph language (i.e. by using <a href="/glyph/book/extending/interpreting.html#rewriting">macro rewriting</a>) within a single <code>.glyph</code> file.</p> -<div class="section"> -<h5 id="h_84">Topic Layout</h5> +<section class="section"> +<header><h1 id="h_84">Topic Layout</h1></header> <p>The default layout used to render all web topics (the layout used for web5 topics is very similar) is defined as follows:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> document[ -<span class="line-numbers"> 2 </span> head[ -<span class="line-numbers"> 3 </span> style[default.css] -<span class="line-numbers"> 4 </span> ] -<span class="line-numbers"> 5 </span> body[ -<span class="line-numbers"> 6 </span> @class[topic] -<span class="line-numbers"> 7 </span> section[ -<span class="line-numbers"> 8 </span> @title[{{title}}] -<span class="line-numbers"> 9 </span> @id[{{id}}] -<span class="line-numbers"> 10 </span> navigation[{{id}}] -<span class="line-numbers"> 11 </span> {{contents}} -<span class="line-numbers"> 12 </span> navigation[{{id}}] -<span class="line-numbers"> 13 </span> ] -<span class="line-numbers"> 14 </span> ] -<span class="line-numbers"> 15 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> document[ +<span class="no"> 2</span> head[ +<span class="no"> 3</span> style[default.css] +<span class="no"> 4</span> ] +<span class="no"> 5</span> body[ +<span class="no"> 6</span> @class[topic] +<span class="no"> 7</span> section[ +<span class="no"> 8</span> @title[{{title}}] +<span class="no"> 9</span> @id[{{id}}] +<span class="no"><strong>10</strong></span> navigation[{{id}}] +<span class="no">11</span> {{contents}} +<span class="no">12</span> navigation[{{id}}] +<span class="no">13</span> ] +<span class="no">14</span> ] +<span class="no">15</span> ]</pre></div> +</div> + <p>Note that it takes the following attributes, passed automatically by Glyph when processing each topic:</p> <ul> <li><code>title</code> — the title of the topic.</li>@@ -91,125 +95,105 @@ <li><code>id</code> — the ID of the topic.</li>
<li><code>contents</code> — the body of the topic.</li> </ul> -</div> -<div class="section"> -<h5 id="index_layout">Index Layout</h5> +</section> +<section class="section"> +<header><h1 id="index_layout">Index Layout</h1></header> <p>The default layout used to render the web index page (the layout used for the web5 index is very similar) is defined as follows:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> document[ -<span class="line-numbers"> 2 </span> head[ -<span class="line-numbers"> 3 </span> style[default.css] -<span class="line-numbers"> 4 </span> ] -<span class="line-numbers"> 5 </span> body[ -<span class="line-numbers"> 6 </span> @class[topic] -<span class="line-numbers"> 7 </span> halftitlepage[ -<span class="line-numbers"> 8 </span> title[] -<span class="line-numbers"> 9 </span> subtitle[] -<span class="line-numbers"> 10 </span> author[] -<span class="line-numbers"> 11 </span> ] -<span class="line-numbers"> 12 </span> frontmatter[ -<span class="line-numbers"> 13 </span> toc[] -<span class="line-numbers"> 14 </span> ] -<span class="line-numbers"> 15 </span> ] -<span class="line-numbers"> 16 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> document[ +<span class="no"> 2</span> head[ +<span class="no"> 3</span> style[default.css] +<span class="no"> 4</span> ] +<span class="no"> 5</span> body[ +<span class="no"> 6</span> @class[topic] +<span class="no"> 7</span> halftitlepage[ +<span class="no"> 8</span> title[] +<span class="no"> 9</span> subtitle[] +<span class="no"><strong>10</strong></span> author[] +<span class="no">11</span> ] +<span class="no">12</span> frontmatter[ +<span class="no">13</span> toc[] +<span class="no">14</span> ] +<span class="no">15</span> ] +<span class="no">16</span> ]</pre></div> +</div> + <p>Index layouts do not take any attribute or parameter (basically because they are used to produce only one page).</p> -</div> -<div class="section"> -<h5 id="h_86">Creating a Custom Layout</h5> +</section> +<section class="section"> +<header><h1 id="h_86">Creating a Custom Layout</h1></header> <p>To create a custom layout, proceed as follows:</p> <ul> <li>Create a <code>.glyph</code> file in the <code>lib/layouts</code> directory, within your project, e.g. <code>mytopic.glyph</code></li> <li>Add the layout code, making sure (for topic layouts) that all the attributes (<code>title</code>, <code>id</code>, <code>contents</code>) are specified correctly.</li> <li>Set the <code>output.*.layouts.topic</code> setting to the name of the new layout (<code>mytopic</code>).</li> </ul> - <div class="tip"> + <aside class="tip"> <span class="note-title">Tip</span>You can override which layout to use on a specific topic by specifying it in a <code>@layout</code> attribute. -</div> +</aside> -</div> +</section> - <div class="navigation"><a href="/glyph/book/extending/interpreting.html">Interpreting Glyph Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/further_reading.html">→ Further Reading</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/layouts.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/extending/interpreting.html">Interpreting Glyph Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/further_reading.html">→ Further Reading</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,87 +1,91 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Defining Custom Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Defining Custom Macros – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Defining Custom Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Defining Custom Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/internals.html">A quick look at Glyph's internals ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/params_attrs.html">→ Parameters and Attributes</a></div> + <nav><a href="/glyph/book/extending/internals.html">A quick look at Glyph's internals ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/params_attrs.html">→ Parameters and Attributes</a></nav> <p>Glyph was created wih extensibility in mind. You can freely extend Glyph Language by creating or overriding macros, to do whatever you like. Macro definitions are written in pure Ruby code and placed in <code>.rb</code> files within the <code>lib/macros/</code> folder of your project.</p> -<div class="box"> +<aside class="box"> <div class="box-title">Alternative Ways to Define Macros</div> <p>You can also define macros:</p> <ul> <li>inside your document, using the <a href="/glyph/book/macros/macros_core.html#m_macro_"><code>macro:</code></a> macro.</li> <li>Using the <a href="/glyph/book/macros/macros_core.html#m_include"><code>include</code></a> macro specifying the path to an <code>.rb</code> file containing macro definitions stored in the <code>lib/</code> directory (useful especially when <a href="/glyph/book/compiling/lite_mode.html#lite_mode">compiling single Glyph files</a>).</li> </ul> +</aside> +<p>This is the source code of a fairly simple macro used to format a note:</p> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> macro <span class="sy">:note</span> <span class="r">do</span> +<span class="no">2</span> <span class="s"><span class="dl">%{</span><span class="k"><div class="</span><span class="il"><span class="idl">#{</span><span class="iv">@name</span><span class="idl">}</span></span><span class="k">"><span class="note-title"></span><span class="il"><span class="idl">#{</span><span class="iv">@name</span>.to_s.capitalize<span class="idl">}</span></span><span class="k"></span> +<span class="no">3</span> </span><span class="il"><span class="idl">#{</span><span class="iv">@value</span><span class="idl">}</span></span><span class="k"> +<span class="no">4</span> +<span class="no">5</span> </div></span><span class="dl">}</span></span> +<span class="no">6</span> <span class="r">end</span></pre></div> </div> -<p>This is the source code of a fairly simple macro used to format a note:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> macro <span class="Constant"><span class="Constant">:</span>note</span> <span class="Keyword">do</span> -<span class="line-numbers"> 2 </span> <span class="String"><span class="String">%{</span><div class="<span class="String"><span class="String">#{</span><span class="Variable"><span class="Variable">@</span>name</span><span class="String">}</span></span>"><span class="note-title"><span class="String"><span class="String">#{</span><span class="Variable"><span class="Variable">@</span>name</span><span class="String"><span class="String">.</span><span class="Entity">to_s</span></span><span class="String"><span class="String">.</span><span class="Entity">capitalize</span></span><span class="String">}</span></span></span></span> -<span class="line-numbers"> 3 </span> <span class="String"> <span class="String"><span class="String">#{</span><span class="Variable"><span class="Variable">@</span>value</span><span class="String">}</span></span></span> -<span class="line-numbers"> 4 </span> <span class="String"></span> -<span class="line-numbers"> 5 </span> <span class="String"> </div><span class="String">}</span></span> -<span class="line-numbers"> 6 </span> <span class="Keyword">end</span> -</pre> + <p>The <code>macro</code> method takes a single <code>Symbol</code> or <code>String</code> parameter, corresponding to the name of the macro. In this case, the entire block (or <em>body</em> of the macro) is a <code>String</code> corresponding to what we want the macro to evaluate to: a <code><div></code> tag containing a note.</p> <p>The body of the macro is evaluated in the context of the <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Macro"><code>Glyph::Macro</code></a> class, therefore its instance variables (like <code>@name</code> or <code>@value</code>) can be used directly.</p> -<div class="box"> +<aside class="box"> <div class="box-title">Why using <code>@name</code> instead of just “note”?</div> <p>For the <code>note</code> macro, it absolutely makes no difference. However, by using <code>@name</code> it is possible to re-use the same code for the <code>tip</code>, <code>important</code> and <code>caution</code> macros as well, which are in fact only aliases of the <code>note</code> macro.</p> -</div> +</aside> <p>The following table lists all the instance variables that can be used inside macros:</p> <table><tr><th>Variable</th> <th>Description</th></tr>@@ -105,86 +109,64 @@ <tr><td>
<code>@source</code> </td> <td>A <code>String</code> identifying the source of the macro (a file, a snippet, etc.).</td></tr></table> - <div class="navigation"><a href="/glyph/book/extending/internals.html">A quick look at Glyph's internals ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/params_attrs.html">→ Parameters and Attributes</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/macro_def.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/extending/internals.html">A quick look at Glyph's internals ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/params_attrs.html">→ Parameters and Attributes</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,82 +1,86 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Custom Output Formats</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Custom Output Formats – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Custom Output Formats</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Custom Output Formats</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/task.html">Defining Custom Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/command.html">→ Defining Custom Commands</a></div> + <nav><a href="/glyph/book/extending/task.html">Defining Custom Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/command.html">→ Defining Custom Commands</a></nav> <p>As shown in <a href="/glyph/book/extending/commands_tasks.html#cmd_tasks_arch">How Commands and Tasks work</a>, the <a href="/glyph/book/ref_commands.html#c_compile"><code>compile</code></a> command command calls specific tasks defined in the <code>generate:</code> Rake namespace to generate output files in a particular format.</p> <p>More specifically, when a <code>--format</code> option is specified, the command looks for a task with the same name within the <code>generate:</code> namespace. This makes adding new output formats to Glyph a fairly easy task, without the need to specify custom commands or similar.</p> <p>The following sections explain how the <code>h3rald</code> output format was created to integrate this book into the <a href="http://www.h3rald.com">H3RALD.com</a> website.</p> -<div class="section"> -<h6 id="h_93">Output Configuration</h6> +<section class="section"> +<header><h1 id="h_93">Output Configuration</h1></header> <p>The first step required to add a new output format to Glyph is extending Glyph’s configuration by adding the appropriate output hash, as follows:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> :<span class="MetaTag"><span class="MetaTag">output</span><span class="MetaTag">:</span> </span> -<span class="line-numbers"> 2 </span> :<span class="MetaTag"><span class="MetaTag">h3rald</span><span class="MetaTag">:</span> </span> -<span class="line-numbers"> 3 </span> :<span class="String"><span class="Entity">multifile<span class="Entity">:</span></span> <span class="String">true</span></span> -<span class="line-numbers"> 4 </span> :<span class="MetaTag"><span class="MetaTag">extension</span><span class="MetaTag">:</span> </span><span class="String"><span class="String">'</span>.html<span class="String">'</span></span> -<span class="line-numbers"> 5 </span> :<span class="MetaTag"><span class="MetaTag">filter_target</span><span class="MetaTag">:</span> </span><span class="String"><span class="String">'</span>html<span class="String">'</span></span> -<span class="line-numbers"> 6 </span> :<span class="MetaTag"><span class="MetaTag">base</span><span class="MetaTag">:</span> </span><span class="String"><span class="String">'</span>/glyph/book/<span class="String">'</span></span> -<span class="line-numbers"> 7 </span> :<span class="MetaTag"><span class="MetaTag">macro_dirs</span><span class="MetaTag">:</span> </span>[<span class="String"><span class="String">'</span>html<span class="String">'</span></span>] -<span class="line-numbers"> 8 </span> :<span class="MetaTag"><span class="MetaTag">layout_dirs</span><span class="MetaTag">:</span> </span>[<span class="String"><span class="String">'</span>web<span class="String">'</span></span>] -<span class="line-numbers"> 9 </span> :<span class="MetaTag"><span class="MetaTag">layouts</span><span class="MetaTag">:</span> </span> -<span class="line-numbers"> 10 </span> :<span class="String"><span class="Entity">topic<span class="Entity">:</span></span> <span class="String">bookpage</span></span> -<span class="line-numbers"> 11 </span> :<span class="String"><span class="Entity">index<span class="Entity">:</span></span> <span class="String">bookindex</span></span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> <span class="sy">:output</span>: +<span class="no"> 2</span> <span class="sy">:h3rald</span>: +<span class="no"> 3</span> <span class="sy">:multifile</span>: <span class="er">true</span> +<span class="no"> 4</span> <span class="sy">:extension</span>: <span class="er">'.html'</span> +<span class="no"> 5</span> <span class="sy">:filter_target</span>: <span class="er">'html'</span> +<span class="no"> 6</span> <span class="sy">:base</span>: <span class="er">'/glyph/book/'</span> +<span class="no"> 7</span> <span class="sy">:macro_dirs</span>: [<span class="er">'html', 'html5']</span> +<span class="no"> 8</span> <span class="sy">:layout_dirs</span>: [<span class="er">'web5']</span> +<span class="no"> 9</span> <span class="sy">:layouts</span>: +<span class="no"><strong>10</strong></span> <span class="sy">:topic</span>: <span class="er">bookpage</span> +<span class="no">11</span> <span class="sy">:index</span>: <span class="er">bookindex</span></pre></div> +</div> + <p>In particular, the following keys are mandatory:</p> <ul> <li>multifile</li>@@ -87,128 +91,105 @@ <li>macro_dirs</li>
<li>layout_dirs</li> </ul> +</section> +<section class="section"> +<header><h1 id="h_94">Creating a 'generate:h3rald' task</h1></header> +<p>The next (and final) step involves creating a custom <code>h3rald</code> task within the <code>generate:</code> namespace. This task can be placed in any <code>.rake</code> file within the <code>lib/tasks</code> directory:</p> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> namespace <span class="sy">:generate</span> <span class="r">do</span> +<span class="no"> 2</span> desc <span class="s"><span class="dl">"</span><span class="k">Create output for h3rald.com integration</span><span class="dl">"</span></span> +<span class="no"> 3</span> task <span class="sy">:h3rald</span> => [<span class="sy">:web5</span>] <span class="r">do</span> +<span class="no"> 4</span> dir = <span class="co">Glyph</span>::<span class="co">PROJECT</span>/<span class="s"><span class="dl">'</span><span class="k">output/h3rald</span><span class="dl">'</span></span> +<span class="no"> 5</span> (dir/<span class="s"><span class="dl">"</span><span class="k">glyph/book</span><span class="dl">"</span></span>).mkpath +<span class="no"> 6</span> <span class="c"># Copy files in subdir</span> +<span class="no"> 7</span> (dir).find <span class="r">do</span> |i| +<span class="no"> 8</span> <span class="r">if</span> i.file? <span class="r">then</span> +<span class="no"> 9</span> <span class="r">next</span> <span class="r">if</span> i.to_s.match(<span class="co">Regexp</span>.escape(dir/<span class="s"><span class="dl">'</span><span class="k">glyph</span><span class="dl">'</span></span>)) +<span class="no"><strong>10</strong></span> dest = dir/<span class="s"><span class="dl">"</span><span class="k">glyph/book/</span><span class="il"><span class="idl">#{</span>i.relative_path_from(<span class="co">Glyph</span>::<span class="co">PROJECT</span>/dir)<span class="idl">}</span></span><span class="dl">"</span></span> +<span class="no">11</span> src = i.to_s +<span class="no">12</span> <span class="co">Pathname</span>.new(dest).parent.mkpath +<span class="no">13</span> file_copy src, dest +<span class="no">14</span> <span class="r">end</span> +<span class="no">15</span> <span class="r">end</span> +<span class="no">16</span> <span class="c"># Remove files from output dir</span> +<span class="no">17</span> dir.children.each <span class="r">do</span> |c| +<span class="no">18</span> <span class="r">unless</span> c == dir/<span class="s"><span class="dl">'</span><span class="k">glyph</span><span class="dl">'</span></span> <span class="r">then</span> +<span class="no">19</span> c.directory? ? c.rmtree : c.unlink +<span class="no"><strong>20</strong></span> <span class="r">end</span> +<span class="no">21</span> <span class="r">end</span> +<span class="no">22</span> (dir/<span class="s"><span class="dl">'</span><span class="k">glyph/book/images/glyph/glyph.eps</span><span class="dl">'</span></span>).unlink +<span class="no">23</span> (dir/<span class="s"><span class="dl">'</span><span class="k">glyph/book/images/glyph/glyph.svg</span><span class="dl">'</span></span>).unlink +<span class="no">24</span> <span class="c"># Create project page</span> +<span class="no">25</span> project = <span class="co">Glyph</span>.filter <span class="s"><span class="dl">%{</span><span class="k">layout:project[ +<span class="no">26</span> @contents[</span><span class="il"><span class="idl">#{</span>file_load(<span class="co">Glyph</span>::<span class="co">PROJECT</span>/<span class="s"><span class="dl">'</span><span class="k">text/introduction.glyph</span><span class="dl">'</span></span>)<span class="idl">}</span></span><span class="k">] +<span class="no">27</span> ]</span><span class="dl">}</span></span> +<span class="no">28</span> file_write dir/<span class="s"><span class="dl">"</span><span class="k">glyph.textile</span><span class="dl">"</span></span>, project +<span class="no">29</span> <span class="r">end</span> +<span class="no"><strong>30</strong></span> <span class="r">end</span></pre></div> </div> -<div class="section"> -<h6 id="h_94">Creating a 'generate:h3rald' task</h6> -<p>The next (and final) step involves creating a custom <code>h3rald</code> task within the <code>generate:</code> namespace. This task can be placed in any <code>.rake</code> file within the <code>lib/tasks</code> directory:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> namespace <span class="Constant"><span class="Constant">:</span>generate</span> <span class="Keyword">do</span> -<span class="line-numbers"> 2 </span> desc <span class="String"><span class="String">"</span>Create output for h3rald.com integration<span class="String">"</span></span> -<span class="line-numbers"> 3 </span> task <span class="Constant"><span class="Constant">:</span>h3rald</span> => [<span class="Constant"><span class="Constant">:</span>web</span>] <span class="Keyword">do</span> -<span class="line-numbers"> 4 </span> dir <span class="Keyword">=</span> <span class="Support">Glyph</span>::<span class="Entity">PROJECT</span><span class="Keyword">/</span><span class="String"><span class="String">'</span>output/h3rald<span class="String">'</span></span> -<span class="line-numbers"> 5 </span> (dir<span class="Keyword">/</span><span class="String"><span class="String">"</span>glyph/book<span class="String">"</span></span>).<span class="Entity">mkpath</span> -<span class="line-numbers"> 6 </span> <span class="Comment"> <span class="Comment">#</span> Copy files in subdir</span> -<span class="line-numbers"> 7 </span> (dir).<span class="Entity">find</span> <span class="Keyword">do </span>|<span class="Variable">i</span>| -<span class="line-numbers"> 8 </span> <span class="Keyword">if</span> i.<span class="Entity">file?</span> <span class="Keyword">then</span> -<span class="line-numbers"> 9 </span> <span class="Keyword">next</span> <span class="Keyword">if</span> -<span class="line-numbers"> 10 </span> i.<span class="Entity">to_s</span>.<span class="Entity">match</span>(<span class="Support">Regexp</span>.<span class="Entity">escape</span>(dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>glyph<span class="String">'</span></span>)) <span class="Keyword">||</span> -<span class="line-numbers"> 11 </span> i.<span class="Entity">to_s</span>.<span class="Entity">match</span>(<span class="Support">Regexp</span>.<span class="Entity">escape</span>(dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>images<span class="String">'</span></span>)) <span class="Keyword">||</span> -<span class="line-numbers"> 12 </span> i.<span class="Entity">to_s</span>.<span class="Entity">match</span>(<span class="Support">Regexp</span>.<span class="Entity">escape</span>(dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>styles<span class="String">'</span></span>)) -<span class="line-numbers"> 13 </span> dest <span class="Keyword">=</span> dir<span class="Keyword">/</span><span class="String"><span class="String">"</span>glyph/book/<span class="String"><span class="String">#{</span>i<span class="String"><span class="String">.</span><span class="Entity">relative_path_from</span></span><span class="String">(</span><span class="Support">Glyph</span><span class="String"><span class="String">::</span><span class="Entity">PROJECT</span></span><span class="Keyword">/</span>dir<span class="String">)</span><span class="String">}</span></span><span class="String">"</span></span> -<span class="line-numbers"> 14 </span> src <span class="Keyword">=</span> i.<span class="Entity">to_s</span> -<span class="line-numbers"> 15 </span> <span class="Support">Pathname</span>.<span class="Entity">new</span>(dest).<span class="Entity">parent</span>.<span class="Entity">mkpath</span> -<span class="line-numbers"> 16 </span> file_copy src, dest -<span class="line-numbers"> 17 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 18 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 19 </span> <span class="Comment"> <span class="Comment">#</span> Remove files</span> -<span class="line-numbers"> 20 </span> dir.<span class="Entity">children</span>.<span class="Entity">each</span> <span class="Keyword">do </span>|<span class="Variable">c</span>| -<span class="line-numbers"> 21 </span> <span class="Keyword">unless</span> [dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>glyph<span class="String">'</span></span>, dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>images<span class="String">'</span></span>, dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>styles<span class="String">'</span></span>].<span class="Entity">include?</span> c <span class="Keyword">then</span> -<span class="line-numbers"> 22 </span> c.<span class="Entity">directory?</span> <span class="Keyword">?</span> c.<span class="Entity">rmtree</span> : c.<span class="Entity">unlink</span> -<span class="line-numbers"> 23 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 24 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 25 </span> (dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>images/glyph/glyph.eps<span class="String">'</span></span>).<span class="Entity">unlink</span> -<span class="line-numbers"> 26 </span> (dir<span class="Keyword">/</span><span class="String"><span class="String">'</span>images/glyph/glyph.svg<span class="String">'</span></span>).<span class="Entity">unlink</span> -<span class="line-numbers"> 27 </span> <span class="Comment"> <span class="Comment">#</span> Create project page</span> -<span class="line-numbers"> 28 </span> project <span class="Keyword">=</span> <span class="Support">Glyph</span>.<span class="Entity">filter</span> <span class="String"><span class="String">%{</span>layout:project[</span> -<span class="line-numbers"> 29 </span> <span class="String"> @contents[<span class="String"><span class="String">#{</span><span class="String"><span class="Entity">file_load</span></span><span class="String">(</span><span class="Support">Glyph</span><span class="String"><span class="String">::</span><span class="Entity">PROJECT</span></span><span class="Keyword">/</span><span class="String"><span class="String">'</span>text/introduction.glyph<span class="String">'</span></span><span class="String">)</span><span class="String">}</span></span>]</span> -<span class="line-numbers"> 30 </span> <span class="String"> ]<span class="String">}</span></span> -<span class="line-numbers"> 31 </span> file_write dir<span class="Keyword">/</span><span class="String"><span class="String">"</span>glyph.textile<span class="String">"</span></span>, project -<span class="line-numbers"> 32 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 33 </span> <span class="Keyword">end</span> -</pre> - <p>In this case, this task does not actually renders files in a different format, it just moves the files generated by the @generate:web@ task in different subdirectories.</p> + + <p>In this case, this task does not actually renders files in a different format, it just moves the files generated by the @generate:web5@ task in different subdirectories.</p> <p>Additionally, it also generates the <a href="http://www.h3rald.com/glyph/">Glyph project page</a> from the book's introduction (note the usage of a raw custom layout macro).</p> -</div> - <div class="navigation"><a href="/glyph/book/extending/task.html">Defining Custom Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/command.html">→ Defining Custom Commands</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_41.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/extending/task.html">Defining Custom Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/command.html">→ Defining Custom Commands</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,67 +1,69 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Parameters and Attributes</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Parameters and Attributes – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> - <h2>Parameters and Attributes</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/macro_def.html">Defining Custom Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/bookmarks_headers.html">→ Bookmarks and Headers</a></div> + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Parameters and Attributes</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/extending/macro_def.html">Defining Custom Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/bookmarks_headers.html">→ Bookmarks and Headers</a></nav> <p>Perhaps the most common things to do in a macro definition is accessing parameters and attributes. When doing so, it is important to consider whether we want to retrieve the <em>raw value</em> of and attribute or parameter or its <em>expanded value</em>. The difference between the two will become clearer in the following sections and also in the <a href="/glyph/book/extending/interpreting.html#interpreting">Interpreting Glyph Code</a> section.</p> - <div class="section"> -<h5 id="expanded_values">Accessing Expanded Values</h5> + <section class="section"> +<header><h1 id="expanded_values">Accessing Expanded Values</h1></header> <p>Normally, you just want to get the value of an attribute or parameter and use it in the macro. This means, in other words, its <em>expanded</em> value, i.e. the value resulting from the expansion of the macros (if any) within the attribute or parameter.</p> <p>To access expanded values, use the following methods:</p> <ul>@@ -72,47 +74,53 @@ <li><code>parameters</code> (or <code>params</code>): Returns an array of expanded parameters.</li>
<li><code>attributes</code> (or <code>attrs</code>): Returns a hash of expanded attributes.</li> </ul> +</section> + <section class="section"> +<header><h1 id="h_77">Accessing Raw Values</h1></header> +<p>While accessing expanded values is simple and immediate, in some cases it may not produce the desired results. Consider the following macro definition:</p> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> macro <span class="sy">:nest_section</span> <span class="r">do</span> +<span class="no"> 2</span> interpret <span class="s"><span class="dl">%{</span><span class="k">section[ +<span class="no"> 3</span> @title[A] +<span class="no"> 4</span> section[ +<span class="no"> 5</span> @title[B] +<span class="no"> 6</span> </span><span class="il"><span class="idl">#{</span>value<span class="idl">}</span></span><span class="k"> +<span class="no"> 7</span> ] +<span class="no"> 8</span> ]</span><span class="dl">}</span></span> +<span class="no"> 9</span> <span class="r">end</span></pre></div> </div> - <div class="section"> -<h5 id="h_77">Accessing Raw Values</h5> -<p>While accessing expanded values is simple and immediate, in some cases it may not produce the desired results. Consider the following macro definition:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> macro <span class="Constant"><span class="Constant">:</span>nest_section</span> <span class="Keyword">do</span> -<span class="line-numbers"> 2 </span> interpret <span class="String"><span class="String">%{</span>section[</span> -<span class="line-numbers"> 3 </span> <span class="String"> @title[A]</span> -<span class="line-numbers"> 4 </span> <span class="String"> section[</span> -<span class="line-numbers"> 5 </span> <span class="String"> @title[B]</span> -<span class="line-numbers"> 6 </span> <span class="String"> <span class="String"><span class="String">#{</span>value<span class="String">}</span></span></span> -<span class="line-numbers"> 7 </span> <span class="String"> ]</span> -<span class="line-numbers"> 8 </span> <span class="String"> ]<span class="String">}</span></span> -<span class="line-numbers"> 9 </span> <span class="Keyword">end</span> -</pre> + <p>And suppose to use it as follows:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> nest_section[ -<span class="line-numbers"> 2 </span> section[ -<span class="line-numbers"> 3 </span> <span class="Variable"><span class="Variable">@</span>title</span>[<span class="Variable">Inner</span> <span class="Variable">Section</span>] -<span class="line-numbers"> 4 </span> ... -<span class="line-numbers"> 5 </span> ] -<span class="line-numbers"> 6 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> nest_section[ +<span class="no">2</span> section[ +<span class="no">3</span> <span class="iv">@title</span>[<span class="co">Inner</span> <span class="co">Section</span>] +<span class="no">4</span> ... +<span class="no">5</span> ] +<span class="no">6</span> ]</pre></div> +</div> + <p>It produces the following HTML code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>section<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 2 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">h2</span> <span class="MetaTag"><span class="MetaTag">id</span><span class="MetaTag">=</span><span class="String"><span class="String">"</span><span class="String">h_2</span><span class="String">"</span></span></span><span class="MetaTag">></span></span>A<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">h2</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>section<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">h3</span> <span class="MetaTag"><span class="MetaTag">id</span><span class="MetaTag">=</span><span class="String"><span class="String">"</span><span class="String">h_3</span><span class="String">"</span></span></span><span class="MetaTag">></span></span>B<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">h3</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 5 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>section<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 6 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">h2</span> <span class="MetaTag"><span class="MetaTag">id</span><span class="MetaTag">=</span><span class="String"><span class="String">"</span><span class="String">h_1</span><span class="String">"</span></span></span><span class="MetaTag">></span></span>Inner Section<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">h2</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 7 </span> ... -<span class="line-numbers"> 8 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 9 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 10 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">section</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no"> 2</span> <span class="ta"><h2</span> <span class="an">id</span>=<span class="s"><span class="dl">"</span><span class="k">h_2</span><span class="dl">"</span></span><span class="ta">></span>A<span class="ta"></h2></span> +<span class="no"> 3</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">section</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no"> 4</span> <span class="ta"><h3</span> <span class="an">id</span>=<span class="s"><span class="dl">"</span><span class="k">h_3</span><span class="dl">"</span></span><span class="ta">></span>B<span class="ta"></h3></span> +<span class="no"> 5</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">section</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no"> 6</span> <span class="ta"><h2</span> <span class="an">id</span>=<span class="s"><span class="dl">"</span><span class="k">h_1</span><span class="dl">"</span></span><span class="ta">></span>Inner Section<span class="ta"></h2></span> +<span class="no"> 7</span> ... +<span class="no"> 8</span> <span class="ta"></div></span> +<span class="no"> 9</span> <span class="ta"></div></span> +<span class="no"><strong>10</strong></span> <span class="ta"></div></span></pre></div> +</div> + <p>Everything is fine <em>except</em> for the header level: the heading "Inner Section" is of level 2, but it should be level 4!</p> <p>This happens because the inner section is evaluated <em>before</em> the <code>nest_section</code> macro: after all, we ask for it ourselves when we call the <code>value</code> method inside the macro definition. When the value is expanded, there are no outer sections <em>yet</em>.</p> <p>To avoid this unwanted behavior, we can use the <code>raw_value</code> method instead, that returns the first parameter converted back to a Glyph code string.</p> - <div class="tip"> + <aside class="tip"> <span class="note-title">Tip</span>To be on the safe side, always use <code>raw_*</code> methods when interpreting. -</div> +</aside> <p>To access raw values, use the following methods:</p> <ul> <li><code>raw_parameter</code> (or <code>raw_param</code>): Returns the raw parameter value of the parameter specified by number.</li>@@ -120,87 +128,65 @@ <li><code>raw_value</code>: Returns the first raw parameter value (i.e. like <code>raw_parameter(0)</code>).</li>
<li><code>raw_attribute</code> (or <code>raw_attr</code>): Returns the attribute value of the attribute specified by name.</li> </ul> -</div> - <div class="navigation"><a href="/glyph/book/extending/macro_def.html">Defining Custom Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/bookmarks_headers.html">→ Bookmarks and Headers</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_32.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/extending/macro_def.html">Defining Custom Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/bookmarks_headers.html">→ Bookmarks and Headers</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,167 +1,149 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Using Placeholders</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Using Placeholders – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Using Placeholders</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Using Placeholders</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/bookmarks_headers.html">Bookmarks and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/validators.html">→ Using Validators</a></div> + <nav><a href="/glyph/book/extending/bookmarks_headers.html">Bookmarks and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/validators.html">→ Using Validators</a></nav> <p>Sometimes you may need to access some data that will not be available until the entire document has been fully parsed and analyzed. For example, in order to be able to validate internal links, it is necessary to know in advance if the bookmark ID referenced in the link exists or not, either before (that’s easy) or even <em>after</em> the link.</p> <p>Here’s the source code of the <a href="/glyph/book/macros/macros_inline.html#m_link"><code>link</code></a> macro:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> macro <span class="Constant"><span class="Constant">:</span>link</span> <span class="Keyword">do</span> -<span class="line-numbers"> 2 </span> href, title <span class="Keyword">=</span> <span class="Variable"><span class="Variable">@</span>params</span> -<span class="line-numbers"> 3 </span> <span class="Keyword">if</span> href.<span class="Entity">match</span> <span class="String"><span class="String">/</span></span><span class="String">^#</span><span class="String"><span class="String">/</span></span> <span class="Keyword">then</span> -<span class="line-numbers"> 4 </span> anc <span class="Keyword">=</span> href.<span class="Entity">gsub</span>(<span class="String"><span class="String">/</span></span><span class="String">^#</span><span class="String"><span class="String">/</span></span>, <span class="String"><span class="String">'</span><span class="String">'</span></span>).<span class="Entity">to_sym</span> -<span class="line-numbers"> 5 </span> bmk <span class="Keyword">=</span> bookmark? anc -<span class="line-numbers"> 6 </span> <span class="Keyword">if</span> bmk <span class="Keyword">then</span> -<span class="line-numbers"> 7 </span> title <span class="Keyword">||=</span> bmk[<span class="Constant"><span class="Constant">:</span>title</span>] -<span class="line-numbers"> 8 </span> <span class="Keyword">else</span> -<span class="line-numbers"> 9 </span> plac <span class="Keyword">=</span> placeholder <span class="Keyword">do </span>|<span class="Variable">document</span>| -<span class="line-numbers"> 10 </span> macro_error <span class="String"><span class="String">"</span>Bookmark '<span class="String"><span class="String">#{</span>anc<span class="String">}</span></span>' does not exist<span class="String">"</span></span> <span class="Keyword">unless</span> document.<span class="Entity">bookmarks</span>[anc] -<span class="line-numbers"> 11 </span> document.<span class="Entity">bookmarks</span>[anc][<span class="Constant"><span class="Constant">:</span>title</span>] -<span class="line-numbers"> 12 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 13 </span> title <span class="Keyword">||=</span> plac -<span class="line-numbers"> 14 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 15 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 16 </span> title <span class="Keyword">||=</span> href -<span class="line-numbers"> 17 </span> <span class="String"><span class="String">%{</span><a href="<span class="String"><span class="String">#{</span>href<span class="String">}</span></span>"><span class="String"><span class="String">#{</span>title<span class="String">}</span></span></a><span class="String">}</span></span> -<span class="line-numbers"> 18 </span> <span class="Keyword">end</span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> macro <span class="sy">:link</span> <span class="r">do</span> +<span class="no"> 2</span> href, title = <span class="iv">@params</span> +<span class="no"> 3</span> <span class="r">if</span> href.match <span class="rx"><span class="dl">/</span><span class="k">^#</span><span class="dl">/</span></span> <span class="r">then</span> +<span class="no"> 4</span> anc = href.gsub(<span class="rx"><span class="dl">/</span><span class="k">^#</span><span class="dl">/</span></span>, <span class="s"><span class="dl">'</span><span class="dl">'</span></span>).to_sym +<span class="no"> 5</span> bmk = bookmark? anc +<span class="no"> 6</span> <span class="r">if</span> bmk <span class="r">then</span> +<span class="no"> 7</span> title ||= bmk[<span class="sy">:title</span>] +<span class="no"> 8</span> <span class="r">else</span> +<span class="no"> 9</span> plac = placeholder <span class="r">do</span> |document| +<span class="no"><strong>10</strong></span> macro_error <span class="s"><span class="dl">"</span><span class="k">Bookmark '</span><span class="il"><span class="idl">#{</span>anc<span class="idl">}</span></span><span class="k">' does not exist</span><span class="dl">"</span></span> <span class="r">unless</span> document.bookmarks[anc] +<span class="no">11</span> document.bookmarks[anc][<span class="sy">:title</span>] +<span class="no">12</span> <span class="r">end</span> +<span class="no">13</span> title ||= plac +<span class="no">14</span> <span class="r">end</span> +<span class="no">15</span> <span class="r">end</span> +<span class="no">16</span> title ||= href +<span class="no">17</span> <span class="s"><span class="dl">%{</span><span class="k"><a href="</span><span class="il"><span class="idl">#{</span>href<span class="idl">}</span></span><span class="k">"></span><span class="il"><span class="idl">#{</span>title<span class="idl">}</span></span><span class="k"></a></span><span class="dl">}</span></span> +<span class="no">18</span> <span class="r">end</span></pre></div> +</div> + <p>If there’s already a bookmark stored in the current document, then it is possible to retrieve its title and use it as link text. Otherwise, it is necessary to wait until the entire document has been fully processed and then check if the bookmark exists. To do so, use the <code>placeholder</code> method. When called, this method returns an unique placeholder, which is then substituted with the value of the block, right before the document is finalized.</p> <p>Within the <code>placeholder</code> block, the <code>document</code> parameter is, by all means, the fully analyzed document.</p> - <div class="navigation"><a href="/glyph/book/extending/bookmarks_headers.html">Bookmarks and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/validators.html">→ Using Validators</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_34.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/extending/bookmarks_headers.html">Bookmarks and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/validators.html">→ Using Validators</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,68 +1,70 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Defining Custom Tasks</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Defining Custom Tasks – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Defining Custom Tasks</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Defining Custom Tasks</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/commands_tasks.html">Defining Custom Commands and Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/output_format.html">→ Custom Output Formats</a></div> + <nav><a href="/glyph/book/extending/commands_tasks.html">Defining Custom Commands and Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/output_format.html">→ Custom Output Formats</a></nav> <p>Glyph relies on <a href="http://rake.rubyforge.org/">Rake</a> to perform most of its core operations. Typically, Rake tasks are used do define the high level logic that is used by Glyph commands to, for example, compile a project or load configuration files.</p> <p>Furthermore, Rake provides an easy mechanism to create dependencies among tasks: for example, to make sure that Glyph’s configuration files are loaded before everything else happens.</p> -<div class="section"> -<h5 id="custom_generate_task">Creating a 'custom:generate' task</h5> +<section class="section"> +<header><h1 id="custom_generate_task">Creating a 'custom:generate' task</h1></header> <p>A custom task has been defined for the Glyph project used to produce this document. This custom task is used to compile a few of the documents files into standalone files, deployed in Glyph’s root folder:</p> <ul> <li><code>book/text/introduction.glyph</code> → <code>README.textile</code></li>@@ -72,111 +74,91 @@ <li><code>book/text/acknowledgement.glyph</code> → <code>AUTHORS.textile</code></li>
</ul> <p>First of all, create a <code>lib/tasks</code> folder in your project directory. Then, create a <code>.rake</code> file within it, e.g. <code>tasks.rake</code>.</p> <p>Finally, here’s the source of the task:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> namespace <span class="Constant"><span class="Constant">:</span>custom</span> <span class="Keyword">do</span> -<span class="line-numbers"> 2 </span> task <span class="Constant"><span class="Constant">:</span>generate</span>, [<span class="Constant"><span class="Constant">:</span>file</span>] <span class="Keyword">do </span>|<span class="Variable">t</span>, <span class="Variable">args</span>| -<span class="line-numbers"> 3 </span> generate <span class="Keyword">=</span> lambda <span class="Keyword">do </span>|<span class="Variable">source</span>, <span class="Variable">destination</span>| -<span class="line-numbers"> 4 </span> <span class="Support">Glyph</span>.<span class="Entity">info</span> <span class="String"><span class="String">"</span>Generating <span class="String"><span class="String">#{</span>destination<span class="String">}</span></span>...<span class="String">"</span></span> -<span class="line-numbers"> 5 </span> <span class="Support">Glyph</span>.<span class="Entity">compile</span> <span class="Support">Glyph</span>::<span class="Entity">PROJECT</span><span class="Keyword">/</span><span class="String"><span class="String">"</span>text/<span class="String"><span class="String">#{</span>source<span class="String">}</span></span>.glyph<span class="String">"</span></span>, -<span class="line-numbers"> 6 </span> <span class="Support">Glyph</span>::<span class="Entity">PROJECT</span><span class="Keyword">/</span><span class="String"><span class="String">"</span>../<span class="String"><span class="String">#{</span>destination<span class="String">}</span></span>.textile<span class="String">"</span></span> -<span class="line-numbers"> 7 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 8 </span> files <span class="Keyword">=</span> { -<span class="line-numbers"> 9 </span> <span class="Constant"><span class="Constant">:</span>AUTHORS</span> => <span class="Constant"><span class="Constant">:</span>acknowledgements</span>, -<span class="line-numbers"> 10 </span> <span class="Constant"><span class="Constant">:</span>CHANGELOG</span> => <span class="Constant"><span class="Constant">:</span>changelog</span>, -<span class="line-numbers"> 11 </span> <span class="Constant"><span class="Constant">:</span>LICENSE</span> => <span class="Constant"><span class="Constant">:</span>license</span>, -<span class="line-numbers"> 12 </span> <span class="Constant"><span class="Constant">:</span>README</span> => <span class="Constant"><span class="Constant">:</span>introduction</span> -<span class="line-numbers"> 13 </span> } -<span class="line-numbers"> 14 </span> arg <span class="Keyword">=</span> args[<span class="Constant"><span class="Constant">:</span>file</span>].<span class="Entity">upcase</span>.<span class="Entity">to_sym</span> -<span class="line-numbers"> 15 </span> <span class="Keyword">raise</span> <span class="Variable">RuntimeError</span>, <span class="String"><span class="String">"</span>Unknown file '<span class="String"><span class="String">#{</span>arg<span class="String">}</span></span>.glyph'<span class="String">"</span></span> -<span class="line-numbers"> 16 </span> <span class="Keyword">unless</span> files.<span class="Entity">keys</span>.<span class="Entity">include?</span> arg -<span class="line-numbers"> 17 </span> generate.<span class="Entity">call</span> files[arg], arg -<span class="line-numbers"> 18 </span> <span class="Support">Glyph</span>.<span class="Entity">info</span> <span class="String"><span class="String">"</span>Done.<span class="String">"</span></span> -<span class="line-numbers"> 19 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 20 </span> <span class="Keyword">end</span> -</pre> - <p>That’s it. Note that this task is pretty useless without a command that calls it, and it won’t even show up if you run <code>rake -T</code> within your project directory. <span class="fmi">for more information on creating custom commands, see <a href="/glyph/book/extending/command.html#custom_command">Defining Custom Commands</a></span>.</p> - + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> namespace <span class="sy">:custom</span> <span class="r">do</span> +<span class="no"> 2</span> task <span class="sy">:generate</span>, [<span class="sy">:file</span>] <span class="r">do</span> |t, args| +<span class="no"> 3</span> generate = lambda <span class="r">do</span> |source, destination| +<span class="no"> 4</span> <span class="co">Glyph</span>.info <span class="s"><span class="dl">"</span><span class="k">Generating </span><span class="il"><span class="idl">#{</span>destination<span class="idl">}</span></span><span class="k">...</span><span class="dl">"</span></span> +<span class="no"> 5</span> <span class="co">Glyph</span>.compile <span class="co">Glyph</span>::<span class="co">PROJECT</span>/<span class="s"><span class="dl">"</span><span class="k">text/</span><span class="il"><span class="idl">#{</span>source<span class="idl">}</span></span><span class="k">.glyph</span><span class="dl">"</span></span>, +<span class="no"> 6</span> <span class="co">Glyph</span>::<span class="co">PROJECT</span>/<span class="s"><span class="dl">"</span><span class="k">../</span><span class="il"><span class="idl">#{</span>destination<span class="idl">}</span></span><span class="k">.textile</span><span class="dl">"</span></span> +<span class="no"> 7</span> <span class="r">end</span> +<span class="no"> 8</span> files = { +<span class="no"> 9</span> <span class="sy">:AUTHORS</span> => <span class="sy">:acknowledgements</span>, +<span class="no"><strong>10</strong></span> <span class="sy">:CHANGELOG</span> => <span class="sy">:changelog</span>, +<span class="no">11</span> <span class="sy">:LICENSE</span> => <span class="sy">:license</span>, +<span class="no">12</span> <span class="sy">:README</span> => <span class="sy">:introduction</span> +<span class="no">13</span> } +<span class="no">14</span> arg = args[<span class="sy">:file</span>].upcase.to_sym +<span class="no">15</span> raise <span class="co">RuntimeError</span>, <span class="s"><span class="dl">"</span><span class="k">Unknown file '</span><span class="il"><span class="idl">#{</span>arg<span class="idl">}</span></span><span class="k">.glyph'</span><span class="dl">"</span></span> +<span class="no">16</span> <span class="r">unless</span> files.keys.include? arg +<span class="no">17</span> generate.call files[arg], arg +<span class="no">18</span> <span class="co">Glyph</span>.info <span class="s"><span class="dl">"</span><span class="k">Done.</span><span class="dl">"</span></span> +<span class="no">19</span> <span class="r">end</span> +<span class="no"><strong>20</strong></span> <span class="r">end</span></pre></div> </div> - <div class="navigation"><a href="/glyph/book/extending/commands_tasks.html">Defining Custom Commands and Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/output_format.html">→ Custom Output Formats</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/custom_task.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <p>That’s it. Note that this task is pretty useless without a command that calls it, and it won’t even show up if you run <code>rake -T</code> within your project directory. <span class="fmi">for more information on <mark>creating custom commands</mark>, see <a href="/glyph/book/extending/command.html#custom_command">Defining Custom Commands</a></span>.</p> + +</section> + + <nav><a href="/glyph/book/extending/commands_tasks.html">Defining Custom Commands and Tasks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/output_format.html">→ Custom Output Formats</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,67 +1,69 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Using Validators</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Using Validators – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Using Validators</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Using Validators</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/placeholders.html">Using Placeholders ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/interpreting.html">→ Interpreting Glyph Code</a></div> + <nav><a href="/glyph/book/extending/placeholders.html">Using Placeholders ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/interpreting.html">→ Interpreting Glyph Code</a></nav> <p>If you need to make sure that a macro is used properly, consider using <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Macro/Validators">validators</a>. These methods can be used anywhere within the macro code to check whether certain conditions are met or not. Some default validators are provided to check the number of parameters of a macro, and they are actually used in some system macros.</p> <p>If you want to create your own validators, you can call the generic <code>validate</code> method which takes the message to display in case of error, a Hash of options and a block containing the validation to perform.</p> - <div class="box"> + <aside class="box"> <div class="box-title">Validating macro placement</div> <p>You can, of course, create your own validators to check whether a macro is used directly within another. While this may seem a good idea to enforce constraints into the way documents are created, it has one major drawback: if you define a macro with such validation, you’re effectively limiting its usage, so for example you won’t be able to use within snippets or other custom macros.</p> <p>Suppose, for example, that the <a href="/glyph/book/macros/macros_block.html#m_box"><code>box</code></a> macro is only allowed directly under a <code>section</code> macro. This means that, for example:</p>@@ -72,87 +74,65 @@ </ul>
<p>Even if you consider all the possibilities within the scope of the default macros provided with Glyph, this could still make the <code>box</code> macro unusable within custom macros.</p> <p>For the specific cases where a macro does not make sense unless is within another (e.g. the <a href="/glyph/book/macros/macros_core.html#m_eq"><code>eq</code></a> macro), a <code>within</code> validator is used. Note though, that this validator only checks that the macro is used within another, but it is not necessarily its child.</p> -</div> - <div class="navigation"><a href="/glyph/book/extending/placeholders.html">Using Placeholders ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/interpreting.html">→ Interpreting Glyph Code</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_35.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/extending/placeholders.html">Using Placeholders ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/interpreting.html">→ Interpreting Glyph Code</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Project Configuration</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Project Configuration – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Project Configuration</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Project Configuration</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/getting_started/structure.html">Document Structure ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/glyph_files.html">→ .glyph files</a></div> + <nav><a href="/glyph/book/getting_started/structure.html">Document Structure ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/glyph_files.html">→ .glyph files</a></nav> <p>Glyph stores configuration settings in the following <span class="caps">YAML</span> files:</p> <ol>@@ -77,12 +79,12 @@ <p><code>glyph config</code> <em>setting</em> <em>[value]</em></p>
<p>If no <em>value</em> is specified, Glyph prints the value of the configuration setting, so typing <code>glyph config document.author</code> right after creating a project (assuming you didn’t set this in the Global Configuration) will print nothing, because this setting is blank by default.</p> <p>To change the value of a configuration setting, specify a value right after the setting, like this:</p> <p><code>glyph config document.author "John Smith"</code></p> -<div class="tip"> +<aside class="tip"> <p><span class="note-title">Tip</span>It is also possible to change configuration settings inside your document, using the <a href="/glyph/book/macros/macros_core.html#m_config_"><code>config:</code></a> macro.</p> -</div> +</aside> <p>In this way, the document author will be set to <em>John Smith</em> for the current project. To save this setting globally, add a <code>-g</code> option, like this:</p> <p><code>glyph config -g document.author "John Smith"</code></p> -<div class="box"> +<aside class="box"> <div class="box-title">Regarding configuration values and data types…</div> <p>Glyph attempts to “guess” the data type of a configuration value by evaluation (<code>Kernel#instance_eval</code>) if the value:</p> <ul>@@ -94,89 +96,67 @@ <li>is <em>true</em> or <em>false</em> → <code>Boolean</code></li>
<li>is <em>nil</em> → <code>NilClass</code></li> </ul> <p>Note that this guessing is far from being foolproof: If you type something like <em>{:test, 2}</em>, for example, you’ll get an error.</p> -</div> +</aside> <p>There are plenty of configuration settings that can be modified, but most of them are best if left alone (and in the System Configuration file).</p> <p>For a complete reference, see <a href="/glyph/book/document.html#cfg_ref">Configuration Reference</a>. For everyday use, you may just want to change the settings defined in the <a href="/glyph/book/config/document.html#cfg_document">document.*</a> namespace.</p> - <div class="navigation"><a href="/glyph/book/getting_started/structure.html">Document Structure ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/glyph_files.html">→ .glyph files</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/cfg.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/getting_started/structure.html">Document Structure ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/glyph_files.html">→ .glyph files</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,70 +1,72 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Creating your first Glyph Project</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Creating your first Glyph Project – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Creating your first Glyph Project</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Creating your first Glyph Project</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/acknowledgements.html">Acknowledgements ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/structure.html">→ Document Structure</a></div> + <nav><a href="/glyph/book/acknowledgements.html">Acknowledgements ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/structure.html">→ Document Structure</a></nav> <p>To install Glyph, simply run <code>gem install glyph</code>, like with any other Ruby gem. Then, create a new directory and initialize a new Glyph project, like so:</p> <p><code>mkdir</code> <em>test_document</em></p> <p><code>cd</code> <em>test_document</em></p> <p><code>glyph init</code></p> <p>That’s it. You just created a new Glyph project in the <code>test_document</code> directory.</p> -<div class="box"> +<aside class="box"> <div class="box-title">Glyph’s dependencies</div> <p>Glyph requires the following gems:</p> <ul>@@ -80,7 +82,7 @@ <li>Haml (if you want to load .sass files with the <a href="/glyph/book/macros/macros_structure.html#m_style"><code>style</code></a> macro)</li>
<li>CodeRay <em>or</em> UltraViolet (<a href="/glyph/book/macros/macros_filters.html#m_highlight"><code>highlight</code></a> macro)</li> <li>directory_watcher (to use auto-regeneration with the <a href="/glyph/book/ref_commands.html#c_compile"><code>compile</code></a> command)</li> </ul> -</div> +</aside> <p>Every Glyph project is comprised of the following directories:</p> <ul> <li><code>images/</code> — used to store the image files used in your document.</li>@@ -95,86 +97,64 @@ <li><code>config.yml</code> — containing your <a href="/glyph/book/getting_started/configuration.html#cfg">Project Configuration</a>.</li>
<li><code>document.glyph</code> — containing the <a href="/glyph/book/getting_started/structure.html#struct">structure</a> of your document.</li> <li><code>snippets.yml</code> — containing your text <a href="/glyph/book/text_editing/inclusions.html#incl">snippets</a>.</li> </ul> - <div class="navigation"><a href="/glyph/book/acknowledgements.html">Acknowledgements ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/structure.html">→ Document Structure</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_3.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/acknowledgements.html">Acknowledgements ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/structure.html">→ Document Structure</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,97 +1,101 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Document Structure</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Document Structure – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>Document Structure</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/getting_started/create_project.html">Creating your first Glyph Project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/configuration.html">→ Project Configuration</a></div> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Document Structure</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/getting_started/create_project.html">Creating your first Glyph Project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/configuration.html">→ Project Configuration</a></nav> <p>Every Glyph project contains a <code>document.glyph</code> file that is typically used to define the document structure. The default <code>document.glyph</code> generated automatically when creating a new project is the following:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> book[ -<span class="line-numbers"> 2 </span> @frontmatter[ -<span class="line-numbers"> 3 </span> toc[] -<span class="line-numbers"> 4 </span> preface[ -<span class="line-numbers"> 5 </span> @title[Preface] -<span class="line-numbers"> 6 </span> todo[Write the preface] -<span class="line-numbers"> 7 </span> include[preface] -<span class="line-numbers"> 8 </span> ] -<span class="line-numbers"> 9 </span> ] -<span class="line-numbers"> 10 </span> @bodymatter[ -<span class="line-numbers"> 11 </span> chapter[ -<span class="line-numbers"> 12 </span> @title[Chapter 1] -<span class="line-numbers"> 13 </span> todo[Write chapter 1] -<span class="line-numbers"> 14 </span> include[chapter_1] -<span class="line-numbers"> 15 </span> ] -<span class="line-numbers"> 16 </span> chapter[ -<span class="line-numbers"> 17 </span> @title[Chapter 2] -<span class="line-numbers"> 18 </span> todo[Write chapter 2] -<span class="line-numbers"> 19 </span> include[chapter_2] -<span class="line-numbers"> 20 </span> ] -<span class="line-numbers"> 21 </span> ] -<span class="line-numbers"> 22 </span> @backmatter[ -<span class="line-numbers"> 23 </span> appendix[ -<span class="line-numbers"> 24 </span> @title[Appendix A] -<span class="line-numbers"> 25 </span> todo[Write appendix A] -<span class="line-numbers"> 26 </span> include[appendix_a] -<span class="line-numbers"> 27 </span> ] -<span class="line-numbers"> 28 </span> ] -<span class="line-numbers"> 29 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> book[ +<span class="no"> 2</span> @frontmatter[ +<span class="no"> 3</span> toc[] +<span class="no"> 4</span> preface[ +<span class="no"> 5</span> @title[Preface] +<span class="no"> 6</span> todo[Write the preface] +<span class="no"> 7</span> include[preface] +<span class="no"> 8</span> ] +<span class="no"> 9</span> ] +<span class="no"><strong>10</strong></span> @bodymatter[ +<span class="no">11</span> chapter[ +<span class="no">12</span> @title[Chapter 1] +<span class="no">13</span> todo[Write chapter 1] +<span class="no">14</span> include[chapter_1] +<span class="no">15</span> ] +<span class="no">16</span> chapter[ +<span class="no">17</span> @title[Chapter 2] +<span class="no">18</span> todo[Write chapter 2] +<span class="no">19</span> include[chapter_2] +<span class="no"><strong>20</strong></span> ] +<span class="no">21</span> ] +<span class="no">22</span> @backmatter[ +<span class="no">23</span> appendix[ +<span class="no">24</span> @title[Appendix A] +<span class="no">25</span> todo[Write appendix A] +<span class="no">26</span> include[appendix_a] +<span class="no">27</span> ] +<span class="no">28</span> ] +<span class="no">29</span> ]</pre></div> +</div> + <p>Even without knowing anything about Glyph Language, you can easily figure out that this file defines a document with a Table of Contents, a Preface some Chapters and an Appendix.</p> <p>As you can see, Glyph wraps portions of text within square brackets preceded by an identifier. These identifiers are used for <em><a href="/glyph/book/text_editing/macro_intro.html#macro_intro">macros</a></em> and <em><a href="/glyph/book/text_editing/attribute_intro.html#attribute_intro">attributes</a></em>. The only syntactic difference between macros and attributes is that attributes are preceded by a <code>@</code>.</p>@@ -108,86 +112,64 @@ <li>The <a href="/glyph/book/macros/macros_structure.html#m_book"><code>book</code></a> macro wraps every other macro and is used to create the document header and default title page.</li>
<li>Then, the <code>@frontmatter</code>, <code>@bodymatter</code>, and <code>@backmatter</code> attributes are used to divide the portions of your document according to the rules of <a href="http://en.wikipedia.org/wiki/Book_design">book design</a>. They are not mandatory, but they can be used, for example, to number your appendixes with letters instead of numbers and similar.</li> <li><code>preface</code>, <code>chapter</code>, <code>appendix</code> are just a way to wrap content in <code><div></code> tags, from an <span class="caps">HTML</span> point of view, but they are also necessary to nest the content of your document and generate the Table of Contents automatically, together through <code>@title</code> attributes.</li> </ul> - <div class="navigation"><a href="/glyph/book/getting_started/create_project.html">Creating your first Glyph Project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/configuration.html">→ Project Configuration</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/struct.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/getting_started/create_project.html">Creating your first Glyph Project ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/getting_started/configuration.html">→ Project Configuration</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,65 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Rapid Document Authoring Framework</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Glyph - Document Authoring Framework</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> -</head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <h2>Glyph — Rapid Document Authoring Framework</h2> - <hr /> - <div id="content-body"> - <div class="contents"> -<h2 class="toc-header" id="toc">Table of Contents</h2> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Glyph - Document Authoring Framework</h1> + <h2>Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="glyph-index"> + <nav class="contents"> +<h1 class="toc-header" id="toc">Table of Contents</h1> <ol class="toc"> <li class="frontmatter introduction"><a href="/glyph/book/introduction.html#h_1">Introduction</a></li><li><ol><li class="frontmatter section"><a href="/glyph/book/license.html#h_12">License</a></li></ol></li> <li class="frontmatter acknowledgement"><a href="/glyph/book/acknowledgements.html#h_13">Acknowledgements</a></li><li class="bodymatter chapter">Getting Started</li><li><ol><li class="bodymatter section"><a href="/glyph/book/getting_started/create_project.html#h_15">Creating your first Glyph Project</a></li><li class="bodymatter section"><a href="/glyph/book/getting_started/structure.html#struct">Document Structure</a></li><li class="bodymatter section"><a href="/glyph/book/getting_started/configuration.html#cfg">Project Configuration</a></li></ol></li>@@ -76,86 +77,64 @@ <li class="backmatter appendix"><a href="/glyph/book/ref_commands.html#cmd_ref">Command Reference</a></li><li class="backmatter appendix">Macro Reference</li><li><ol><li class="appendix section"><a href="/glyph/book/macros/macros_core.html#h_122">Core Macros</a></li><li class="appendix section"><a href="/glyph/book/macros/macros_block.html#h_166">Block Macros</a></li><li class="appendix section"><a href="/glyph/book/macros/macros_inline.html#h_186">Inline Macros</a></li><li class="appendix section"><a href="/glyph/book/macros/macros_filters.html#f_macros">Filter Macros</a></li><li class="appendix section"><a href="/glyph/book/macros/macros_structure.html#h_202">Structure Macros</a></li></ol></li>
<li class="backmatter appendix">Configuration Reference</li><li><ol><li class="appendix section"><a href="/glyph/book/config/document.html#cfg_document">document.*</a></li><li class="appendix section"><a href="/glyph/book/config/filters.html#cfg_filters">filters.*</a></li><li class="appendix section"><a href="/glyph/book/config/options.html#cfg_options">options.*</a></li><li class="appendix section"><a href="/glyph/book/config/output.html#cfg_output">output.*</a></li></ol></li> <li class="backmatter appendix"><a href="/glyph/book/changelog.html#h_230">Changelog</a></li> </ol> -</div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/index.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - - </body> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> </html>
@@ -1,71 +1,72 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Introduction</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Introduction – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>Introduction</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/license.html">→ License</a></div> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Introduction</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/license.html">→ License</a></nav> <p>Glyph is a <em>Rapid Document Authoring Framework</em>.</p> <p>With Glyph, creating and maintaining any kind of document becomes as easy as… <em>programming</em>. Glyph enables you to minimize text duplication, focus on content rather than presentation, manage references seamlessly and automate tedious tasks through a simple but effective macro language, specifically geared towards customization and extensibility.</p> -<p><br style="clear:both" /></p> -<div class="section"> -<h3 id="h_2">Main Features</h3> -<div class="section"> -<h4 id="h_3">Command Line Interface</h4> +<section class="section"> +<header><h1 id="h_2">Main Features</h1></header> +<section class="section"> +<header><h1 id="h_3">Command Line Interface</h1></header> <p>Glyph is 100% command line. Its interface resambles <a href="http://git-scm.com/">Git’s</a> for its simplicity and power (thanks to the <a href="http://github.com/davetron5000/gli">gli</a> gem). Here are some example commands:</p> <ul> <li><code>glyph init</code> — to initialize a new Glyph project in the current (empty) directory.</li>@@ -77,9 +78,9 @@ <li><code>glyph compile readme.glyph</code> — to compile a <em>readme.glyph</em> located in the current directory into a single <span class="caps">HTML</span> file.</li>
<li><code>glyph outline -l 2</code> — Display the document outline, up to second-level headers.</li> <li><code>glyph stats</code> — Display project statistics.</li> </ul> -</div> -<div class="section"> -<h4 id="h_4">Minimalist Syntax</h4> +</section> +<section class="section"> +<header><h1 id="h_4">Minimalist Syntax</h1></header> <p>Glyph syntax rules can be explained using Glyph itself:</p> <div class="code"> <pre>@@ -136,9 +137,9 @@ </div>
</code> </pre> </div> -</div> -<div class="section"> -<h4 id="h_5">Content Reuse</h4> +</section> +<section class="section"> +<header><h1 id="h_5">Content Reuse</h1></header> <p>Finding yourself repeating the same sentence over an over? Glyph allows you to create snippets. Within snippets. Within other snippets (and so on, for a long long time…) as long as you don’t define a snippet by defining itself, which would be kinda nasty (and Glyph would complain!):</p> <div class="code"> <pre>@@ -160,36 +161,36 @@ </code>
</pre> </div> <p>If yourself dreaming about <em>parametric</em> snippets, just create your own macros (see the <a href="http://github.com/h3rald/glyph/blob/master/book/text/changelog.glyph">source</a> of Glyph’s changelog, just to have an idea).</p> -</div> -<div class="section"> -<h4 id="h_6">Automation of Common Tasks</h4> +</section> +<section class="section"> +<header><h1 id="h_6">Automation of Common Tasks</h1></header> <p>If you’re writing a book, you shouldn’t have to worry about pagination, headers, footers, table of contents, section numbering or similar. Glyph understands you, and will take care of everything for you (with a little help from CSS3, sometimes).</p> -</div> -<div class="section"> -<h4 id="h_7">Reference Validation</h4> +</section> +<section class="section"> +<header><h1 id="h_7">Reference Validation</h1></header> <p>Feel free to add plenty of links, snippets, bookmarks, … if Glyph doesn’t find something, it will definitely complain. Broken references are a thing on the past, and you don’t need to worry about it.</p> -</div> -<div class="section"> -<h4 id="h_8">Extreme Extensibility</h4> +</section> +<section class="section"> +<header><h1 id="h_8">Extreme Extensibility</h1></header> <ul> <li>You miss a <code>!!!</code> macro to format really, <em>really</em> important things? Create it. In under 3 seconds, in Ruby or Glyph itself. And yes, you can use special characters, too.</li> <li>You want your own, very special special <code>glyph create --everything</code> command to create all <em>you</em> need in a Glyph project? You can do it. Using your own Rake tasks, too.</li> <li>You want Glyph to output <span class="caps">ODF</span> files? You can do it, and you’ll be able to run <code>glyph generate -f odf</code>. This would probably require a little more time, but it’s trivial, from a technical point of view.</li> </ul> -</div> -<div class="section"> -<h4 id="h_9">Convention over Configuration</h4> +</section> +<section class="section"> +<header><h1 id="h_9">Convention over Configuration</h1></header> <p>Put your text files in <code>/text</code>, your images in <code>/images</code>, add custom macros in a <code>macro</code> folder within your <code>/lib</code> folder… you get the picture: Glyph has its special places.</p> <p>Nonetheless, you also have 1 (<em>one</em>) configuration file to customize to your heart’s content (with smart defaults).</p> -</div> -<div class="section"> -<h4 id="h_10">Free and Open Source</h4> +</section> +<section class="section"> +<header><h1 id="h_10">Free and Open Source</h1></header> <p>Glyph is 100% Open Source Software, developed using the Ruby Programming Language and licensed under the very permissive terms of the <a href="http://www.opensource.org/licenses/mit-license.php"><span class="caps">MIT</span> License</a>.</p> <p>If you have Ruby installed, just run <code>gem install glyph</code>. That’s all it takes.</p> -</div> -</div> -<div class="section"> -<h3 id="h_11">Resources</h3> +</section> +</section> +<section class="section"> +<header><h1 id="h_11">Resources</h1></header> <ul> <li>Home Page: <a href="http://www.h3rald.com/glyph/">http://www.h3rald.com/glyph/</a></li> <li>Repository: <a href="http://www.github.com/h3rald/glyph/">http://www.github.com/h3rald/glyph/</a></li>@@ -201,87 +202,65 @@ <li>Book (Web): <a href="http://www.h3rald.com/glyph/book/">http://www.h3rald.com/glyph/book/</a></li>
<li>Reference Documentation: <a href="http://rubydoc.info/gems/glyph/">http://rubydoc.info/gems/glyph/</a></li> <li>User Group: <a href="http://groups.google.com/group/glyph-framework">http://groups.google.com/group/glyph-framework</a></li> </ul> -</div> - <div class="navigation"><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/license.html">→ License</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_0.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/license.html">→ License</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - License</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>License – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>License</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>License</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/introduction.html">Introduction ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/acknowledgements.html">→ Acknowledgements</a></div> + <nav><a href="/glyph/book/introduction.html">Introduction ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/acknowledgements.html">→ Acknowledgements</a></nav> <p>Copyright © 2010 <strong>Fabio Cevasco</strong>, <a href="http://www.h3rald.com">http://www.h3rald.com</a></p> <div class="code">@@ -84,86 +86,64 @@ THE SOFTWARE.
</code> </pre> </div> - <div class="navigation"><a href="/glyph/book/introduction.html">Introduction ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/acknowledgements.html">→ Acknowledgements</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_1.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/introduction.html">Introduction ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/acknowledgements.html">→ Acknowledgements</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,67 +1,69 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Block Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Block Macros – Glyph Documentation</title> + + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Block Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Block Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/macros/macros_core.html">Core Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_inline.html">→ Inline Macros</a></div> + <nav><a href="/glyph/book/macros/macros_core.html">Core Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_inline.html">→ Inline Macros</a></nav> - <div class="section"> -<h4 id="m_box">box</h4> + <section class="section"> +<header><h1 id="m_box">box</h1></header> <p>Creates a titled box (<code><div></code> tag).</p>@@ -69,15 +71,16 @@
<div class="example"><p> <strong>Example</strong> </p> - <pre class="lazy"><span class="line-numbers"> 1 </span> box[Why boxes?| -<span class="line-numbers"> 2 </span> Boxes can be used to make a section of text stand out from the rest of the document. -<span class="line-numbers"> 3 </span> ] -</pre></div> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> box[Why boxes?| +<span class="no">2</span> Boxes can be used to make a section of text stand out from the rest of the document. +<span class="no">3</span> ]</pre></div> +</div></div> - <div class="section"> -<h5 id="h_168">Parameters</h5> + <section class="section"> +<header><h1 id="h_168">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -95,14 +98,14 @@ <td>The box text.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_codeblock">codeblock</h4> + <section class="section"> +<header><h1 id="m_codeblock">codeblock</h1></header> <p>Used to render a block of code within <code><pre></code> and <code><code></code> tags.</p>@@ -110,17 +113,18 @@
<div class="example"><p> <strong>Example</strong> </p> - <pre class="lazy"><span class="line-numbers"> 1 </span> code[ -<span class="line-numbers"> 2 </span> def hello -<span class="line-numbers"> 3 </span> puts "Hello World" -<span class="line-numbers"> 4 </span> end -<span class="line-numbers"> 5 </span> ] -</pre></div> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> code[ +<span class="no">2</span> def hello +<span class="no">3</span> puts "Hello World" +<span class="no">4</span> end +<span class="no">5</span> ]</pre></div> +</div></div> - <div class="section"> -<h5 id="h_170">Parameters</h5> + <section class="section"> +<header><h1 id="h_170">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -132,21 +136,21 @@ <td>The code to be formatted.</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_171">Remarks</h5> +<section class="section"> +<header><h1 id="h_171">Remarks</h1></header> <p>For code highlighting, see the <a href="/glyph/book/macros/macros_filters.html#m_highlight"><code>highlight</code></a> macro.</p> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_figure">figure</h4> + <section class="section"> +<header><h1 id="m_figure">figure</h1></header> <p>Includes an image in the document, with an optional caption (see <a href="/glyph/book/text_editing/images.html#img_fig">Images and Figures</a>).</p>@@ -154,16 +158,17 @@
<div class="example"><p> <strong>Example</strong> </p> - <pre class="lazy"><span class="line-numbers"> 1 </span> figure[ -<span class="line-numbers"> 2 </span> graph.png|Monthly Pageviews -<span class="line-numbers"> 3 </span> @width[90%] -<span class="line-numbers"> 4 </span> ] -</pre></div> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> figure[ +<span class="no">2</span> graph.png|Monthly Pageviews +<span class="no">3</span> @width[90%] +<span class="no">4</span> ]</pre></div> +</div></div> - <div class="section"> -<h5 id="h_173">Parameters</h5> + <section class="section"> +<header><h1 id="h_173">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -181,11 +186,11 @@ <td>The image caption <em>(optional)</em>.</td>
</tr> </table> -</div> +</section> - <div class="section"> -<h5 id="h_174">Attributes</h5> + <section class="section"> +<header><h1 id="h_174">Attributes</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Attribute</th>@@ -197,14 +202,14 @@ <td>Any attribute supported by the <a href="http://www.w3schools.com/tags/tag_IMG.asp">img tag</a>.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_image">image</h4> + <section class="section"> +<header><h1 id="m_image">image</h1></header> <p>Includes an image in the document</p>@@ -212,17 +217,18 @@
<div class="example"><p> <strong>Example</strong> </p> - <pre class="lazy"><span class="line-numbers"> 1 </span> img[ -<span class="line-numbers"> 2 </span> holidays/landscape.jpg -<span class="line-numbers"> 3 </span> @class[photo] -<span class="line-numbers"> 4 </span> @style[border: 1px solid black;] -<span class="line-numbers"> 5 </span> ] -</pre></div> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> img[ +<span class="no">2</span> holidays/landscape.jpg +<span class="no">3</span> @class[photo] +<span class="no">4</span> @style[border: 1px solid black;] +<span class="no">5</span> ]</pre></div> +</div></div> - <div class="section"> -<h5 id="h_176">Parameters</h5> + <section class="section"> +<header><h1 id="h_176">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -234,11 +240,11 @@ <td>The name of the image file (relative to the <code>images/</code> folder).</td>
</tr> </table> -</div> +</section> - <div class="section"> -<h5 id="h_177">Attributes</h5> + <section class="section"> +<header><h1 id="h_177">Attributes</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Attribute</th>@@ -250,22 +256,22 @@ <td>Any attribute supported by the <a href="http://www.w3schools.com/tags/tag_IMG.asp">img tag</a>.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_navigation">navigation</h4> + <section class="section"> +<header><h1 id="m_navigation">navigation</h1></header> <p>Displays links to the document’s <span class="caps">TOC</span> and the previous/next topic (used only in <a href="/glyph/book/extending/layouts.html#layouts">layouts</a>).</p> - <div class="section"> -<h5 id="h_179">Parameters</h5> + <section class="section"> +<header><h1 id="h_179">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -277,22 +283,22 @@ <td>The ID of the current topic.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_note">note</h4> + <section class="section"> +<header><h1 id="m_note">note</h1></header> <p>Creates a note <code>div</code> containing the value.</p> <strong>Aliases:</strong> <code>important, caution, tip</code> <p><strong>Example:</strong> <code>note[This is a note.]</code></p> - <div class="section"> -<h5 id="h_181">Parameters</h5> + <section class="section"> +<header><h1 id="h_181">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -304,130 +310,108 @@ <td>The text of the note.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_pubdate">pubdate</h4> + <section class="section"> +<header><h1 id="m_pubdate">pubdate</h1></header> <p>Evaluates to a date string (in the format: <em>current_month</em> <em>current_year</em>; i.e. <em>%B</em> <em>%Y</em>), within a <code><div></code> tag.</p> <p><strong>Example:</strong> <code>pubdate[]</code></p> -</div> +</section> - <div class="section"> -<h4 id="m_revision">revision</h4> + <section class="section"> +<header><h1 id="m_revision">revision</h1></header> <p>Renders the revision of the document (based on the <a href="/glyph/book/config/document.html#s_document_revision"><code>document.revision</code></a> setting) within a <code><div></code> tag.</p> <p><strong>Example:</strong> <code>revision[]</code></p> -</div> +</section> - <div class="section"> -<h4 id="m_subtitle">subtitle</h4> + <section class="section"> +<header><h1 id="m_subtitle">subtitle</h1></header> <p>Renders the subtitle of the document (based on the <a href="/glyph/book/config/document.html#s_document_subtitle"><code>document.subtitle</code></a> setting) within a <code><h2></code> tag.</p> <p><strong>Example:</strong> <code>subtitle[]</code></p> -</div> +</section> - <div class="section"> -<h4 id="m_title">title</h4> + <section class="section"> +<header><h1 id="m_title">title</h1></header> <p>Renders the title of the document (based on the <a href="/glyph/book/config/document.html#s_document_title"><code>document.title</code></a> setting) within a <code><h1></code> tag.</p> <p><strong>Example:</strong> <code>title[]</code></p> -</div> +</section> - <div class="navigation"><a href="/glyph/book/macros/macros_core.html">Core Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_inline.html">→ Inline Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_49.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/macros/macros_core.html">Core Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_inline.html">→ Inline Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,76 +1,78 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Core Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Core Macros – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Core Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Core Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/ref_commands.html">Command Reference ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_block.html">→ Block Macros</a></div> + <nav><a href="/glyph/book/ref_commands.html">Command Reference ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_block.html">→ Block Macros</a></nav> - <div class="section"> -<h4 id="m_alias">alias</h4> + <section class="section"> +<header><h1 id="m_alias">alias</h1></header> <p>Creates a macro alias.</p> <p><strong>Example:</strong> <code>alias[s|section]</code></p> - <div class="section"> -<h5 id="h_124">Parameters</h5> + <section class="section"> +<header><h1 id="h_124">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -88,22 +90,22 @@ <td>The name of an existing macro.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_and">and</h4> + <section class="section"> +<header><h1 id="m_and">and</h1></header> <p>Conditional <code>and</code> operator, to be used with the <a href="#m_condition"><code>condition</code></a> macro.</p> <p><strong>Example:</strong> <code>?[and[true|false]|This is never displayed.]</code></p> - <div class="section"> -<h5 id="h_126">Parameters</h5> + <section class="section"> +<header><h1 id="h_126">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -120,22 +122,22 @@ <td>The second expression to test</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_comment">comment</h4> + <section class="section"> +<header><h1 id="m_comment">comment</h1></header> <p>Evaluates to nothing. Used to add comments in a Glyph document that will not be displayed in output files.</p> <strong>Aliases:</strong> <code>--</code> <p><strong>Example:</strong> <code>--[=>[#link|This link will not be evaluated]]</code></p> - <div class="section"> -<h5 id="h_128">Parameters</h5> + <section class="section"> +<header><h1 id="h_128">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -147,29 +149,29 @@ <td>The contents to comment out</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_129">Remarks</h5> +<section class="section"> +<header><h1 id="h_129">Remarks</h1></header> <p>Macros are not expanded within comments.</p> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_condition">condition</h4> + <section class="section"> +<header><h1 id="m_condition">condition</h1></header> <p>Tests a conditional expression. For more information, see <a href="/glyph/book/text_editing/conditionals.html#cond_macros">Conditional Macros</a>.</p> <strong>Aliases:</strong> <code>?</code> - <div class="section"> -<h5 id="h_131">Parameters</h5> + <section class="section"> +<header><h1 id="h_131">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -187,11 +189,11 @@ <td>The contents to expand if the condition is satisfied.</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_132">Remarks</h5> +<section class="section"> +<header><h1 id="h_132">Remarks</h1></header> <p>For examples see any of the following:</p> <ul> <li><a href="#m_and"><code>and</code></a> macro</li>@@ -201,22 +203,22 @@ <li><a href="#m_match"><code>match</code></a> macro</li>
<li><a href="#m_eq"><code>eq</code></a> macro</li> </ul> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_config">config</h4> + <section class="section"> +<header><h1 id="m_config">config</h1></header> <p>Returns the value of a configuration setting.</p> <strong>Aliases:</strong> <code>$</code> <p><strong>Example:</strong> <code>$[document.author]</code></p> - <div class="section"> -<h5 id="h_134">Parameters</h5> + <section class="section"> +<header><h1 id="h_134">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -228,22 +230,22 @@ <td>The full name of a configuration setting.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_config_">config:</h4> + <section class="section"> +<header><h1 id="m_config_">config:</h1></header> <p>Sets the value of a configuration setting.</p> <strong>Aliases:</strong> <code>$:</code> <p><strong>Example:</strong> <code>$:[document.draft|true]</code></p> - <div class="section"> -<h5 id="h_136">Parameters</h5> + <section class="section"> +<header><h1 id="h_136">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -256,34 +258,34 @@ </tr>
<tr> - <td>0</td> + <td>1</td> <td>The new value of the configuration setting</td> </tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_137">Remarks</h5> +<section class="section"> +<header><h1 id="h_137">Remarks</h1></header> <p>This macro cannot be used in <a href="/glyph/book/compiling/programmatic_usage.html#modes">safe mode</a>.</p> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_eq">eq</h4> + <section class="section"> +<header><h1 id="m_eq">eq</h1></header> <p>Conditional equality operator, to be used with the <a href="#m_condition"><code>condition</code></a> macro.</p> <p><strong>Example:</strong> <code>?[eq[$[document.draft]|true]|This is displayed only in draft documents.]</code></p> - <div class="section"> -<h5 id="h_139">Parameters</h5> + <section class="section"> +<header><h1 id="h_139">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -300,22 +302,22 @@ <td>The second expression to test</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_escape">escape</h4> + <section class="section"> +<header><h1 id="m_escape">escape</h1></header> <p>Evaluates to its value. Commonly used with the escaping delimiters <code>[=</code> and <code>=]</code>.</p> <strong>Aliases:</strong> <code>.</code> <p><strong>Example:</strong> <code>.[=Macros are escaped here =>[#test].=]</code></p> - <div class="section"> -<h5 id="h_141">Parameters</h5> + <section class="section"> +<header><h1 id="h_141">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -327,22 +329,22 @@ <td>The contents to escape.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_include">include</h4> + <section class="section"> +<header><h1 id="m_include">include</h1></header> <p>Evaluates to the contents of a text file stored in the <code>text/</code> directory referenced by its relative path. If the <a href="/glyph/book/config/options.html#s_options_filters_by_file_extension"><code>options.filters_by_file_extension</code></a> setting is <code>true</code>, filters the contents of the file using the <a href="/glyph/book/macros/macros_filters.html#f_macros">filter macro</a> corresponding to the file extension.</p> <strong>Aliases:</strong> <code>@</code> <p><strong>Example:</strong> <code>include[frontmatter/introduction]</code></p> - <div class="section"> -<h5 id="h_143">Parameters</h5> + <section class="section"> +<header><h1 id="h_143">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -354,31 +356,31 @@ <td>The file to include.</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_144">Remarks</h5> +<section class="section"> +<header><h1 id="h_144">Remarks</h1></header> <ul><li>This macro cannot be used in <a href="/glyph/book/compiling/programmatic_usage.html#modes">safe mode</a>.</li> <li><code>.glyph</code> is assumed if no file extension is specified.</li> <li>This macro can also be used to include <code>.rb</code> ruby files within the <code>lib</code> directory. File contents are evaluated in the context of the <a href="http://yardoc.org/docs/h3rald-glyph/Glyph">Glyph</a> module.</li></ul> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_match">match</h4> + <section class="section"> +<header><h1 id="m_match">match</h1></header> <p>Checks a string against a regular expression.</p> <p><strong>Example:</strong> <code>?[match[Hello!|/^hell/i]|This is always displayed]</code></p> - <div class="section"> -<h5 id="h_146">Parameters</h5> + <section class="section"> +<header><h1 id="h_146">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -402,29 +404,29 @@ <td>The contents to expand if the string matches.</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_147">Remarks</h5> +<section class="section"> +<header><h1 id="h_147">Remarks</h1></header> <p>This macro must be used with the <a href="#m_condition"><code>condition</code></a> macro.</p> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_macro_">macro:</h4> + <section class="section"> +<header><h1 id="m_macro_">macro:</h1></header> <p>Defines a macro.</p> <strong>Aliases:</strong> <code>%:</code> <p><strong>Example:</strong> <code>%:[test|"<em>test: #{value}</em>"]</code></p> - <div class="section"> -<h5 id="h_149">Parameters</h5> + <section class="section"> +<header><h1 id="h_149">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -442,30 +444,30 @@ <td>The macro definition (Ruby code).</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_150">Remarks</h5> +<section class="section"> +<header><h1 id="h_150">Remarks</h1></header> <ul><li>This macro cannot be used in <a href="/glyph/book/compiling/programmatic_usage.html#modes">safe mode</a>.</li> <li>The new macro can only be used <em>after</em> its declaration.</li></ul> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_not">not</h4> + <section class="section"> +<header><h1 id="m_not">not</h1></header> <p>Conditional <code>not</code> operator, to be used with the <a href="#m_condition"><code>condition</code></a> macro.</p> <p><strong>Example:</strong> <code>?[not[false]|This is always displayed.]</code></p> - <div class="section"> -<h5 id="h_152">Parameters</h5> + <section class="section"> +<header><h1 id="h_152">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -477,22 +479,22 @@ <td>The expression to negate</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_or">or</h4> + <section class="section"> +<header><h1 id="m_or">or</h1></header> <p>Conditional <code>or</code> operator, to be used with the <a href="#m_condition"><code>condition</code></a> macro.</p> <p><strong>Example:</strong> <code>?[or[true|false]|This is always displayed.]</code></p> - <div class="section"> -<h5 id="h_154">Parameters</h5> + <section class="section"> +<header><h1 id="h_154">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -509,14 +511,14 @@ <td>The second expression to test</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_rewrite_">rewrite:</h4> + <section class="section"> +<header><h1 id="m_rewrite_">rewrite:</h1></header> <p>Defines a new macro by rewriting (for more information, see <a href="/glyph/book/extending/interpreting.html#rewriting">Rewriting</a>)</p> <strong>Aliases:</strong> <code>rw:</code>@@ -524,18 +526,19 @@
<div class="example"><p> <strong>Example</strong> </p> - <pre class="lazy"><span class="line-numbers"> 1 </span> rw:[release| -<span class="line-numbers"> 2 </span> section[ -<span class="line-numbers"> 3 </span> @title[Release {{0}}] -<span class="line-numbers"> 4 </span> {{1}} -<span class="line-numbers"> 5 </span> ] -<span class="line-numbers"> 6 </span> ] -</pre></div> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> rw:[release| +<span class="no">2</span> section[ +<span class="no">3</span> @title[Release {{0}}] +<span class="no">4</span> {{1}} +<span class="no">5</span> ] +<span class="no">6</span> ]</pre></div> +</div></div> - <div class="section"> -<h5 id="h_156">Parameters</h5> + <section class="section"> +<header><h1 id="h_156">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -553,22 +556,22 @@ <td>The macro definition (Glyph code).</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_157">Remarks</h5> +<section class="section"> +<header><h1 id="h_157">Remarks</h1></header> <ul><li>The new macro can only be used <em>after</em> its declaration.</li> <li>This macro cannot be used in <a href="/glyph/book/compiling/programmatic_usage.html#modes">safe mode</a>.</li></ul> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_ruby">ruby</h4> + <section class="section"> +<header><h1 id="m_ruby">ruby</h1></header> <p>Evaluates its value as Ruby code within the context of the <a href="http://yardoc.org/docs/h3rald-glyph/Glyph">Glyph</a> module.</p> <strong>Aliases:</strong> <code>%</code>@@ -580,8 +583,8 @@ <code>%[Time.now]</code><br /><code>%[Glyph::VERSION]</code><br />
</div> - <div class="section"> -<h5 id="h_159">Parameters</h5> + <section class="section"> +<header><h1 id="h_159">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -593,29 +596,29 @@ <td>The Ruby code to evaluate.</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_160">Remarks</h5> +<section class="section"> +<header><h1 id="h_160">Remarks</h1></header> <p>This macro cannot be used in <a href="/glyph/book/compiling/programmatic_usage.html#modes">safe mode</a>.</p> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_snippet">snippet</h4> + <section class="section"> +<header><h1 id="m_snippet">snippet</h1></header> <p>Returns the value of a snippet.</p> <strong>Aliases:</strong> <code>&</code> <p><strong>Example:</strong> <code>&[glang]</code></p> - <div class="section"> -<h5 id="h_162">Parameters</h5> + <section class="section"> +<header><h1 id="h_162">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -627,22 +630,22 @@ <td>The ID of the snippet to retrieve.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_snippet_">snippet:</h4> + <section class="section"> +<header><h1 id="m_snippet_">snippet:</h1></header> <p>Defines a snippet.</p> <strong>Aliases:</strong> <code>&:</code> <p><strong>Example:</strong> <code>&:[test|This is a test]</code></p> - <div class="section"> -<h5 id="h_164">Parameters</h5> + <section class="section"> +<header><h1 id="h_164">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -660,97 +663,75 @@ <td>The contents of the new snippet.</td>
</tr> </table> -</div> +</section> -<div class="section"> -<h5 id="h_165">Remarks</h5> +<section class="section"> +<header><h1 id="h_165">Remarks</h1></header> <p>The new snippet can only be used <em>after</em> its declaration.</p> -</div> +</section> -</div> +</section> - <div class="navigation"><a href="/glyph/book/ref_commands.html">Command Reference ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_block.html">→ Block Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_48.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/ref_commands.html">Command Reference ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_block.html">→ Block Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,67 +1,69 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Filter Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Filter Macros – Glyph Documentation</title> + + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <h2>Filter Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/macros/macros_inline.html">Inline Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_structure.html">→ Structure Macros</a></div> + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Filter Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/macros/macros_inline.html">Inline Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_structure.html">→ Structure Macros</a></nav> - <div class="section"> -<h4 id="m_markdown">markdown</h4> + <section class="section"> +<header><h1 id="m_markdown">markdown</h1></header> <p>Uses a Markdown converter (BlueCloth, RDiscount, Maruku or Kramdown) to transform the value into <span class="caps">HTML</span> if the <a href="/glyph/book/config/output.html#cfg_output"><code>output.*.filter_target</code></a> setting is set to <code>html</code>.</p> <p>If the <a href="/glyph/book/config/options.html#s_options_filters_by_file_extension"><code>options.filters_by_file_extension</code></a> setting is <code>true</code>, this macro is called automatically on <a href="/glyph/book/macros/macros_core.html#m_include">included</a> files with a <code>.markdown</code> or a <code>.md</code> extension.</p> <strong>Aliases:</strong> <code>md</code>@@ -69,8 +71,8 @@ <p><strong>Example:</strong> <code>markdown[This is *emphasized* text.]</code></p>
- <div class="section"> -<h5 id="h_198">Parameters</h5> + <section class="section"> +<header><h1 id="h_198">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -82,14 +84,14 @@ <td>The Markdown text to filter.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_textile">textile</h4> + <section class="section"> +<header><h1 id="m_textile">textile</h1></header> <p>Uses the RedCloth gem to transform the value into <span class="caps">HTML</span> or LaTeX, depending on the value of the <a href="/glyph/book/config/output.html#cfg_output"><code>output.*.filter_target</code></a>.</p> <p>If the <a href="/glyph/book/config/options.html#s_options_filters_by_file_extension"><code>options.filters_by_file_extension</code></a> setting is <code>true</code>, this macro is called automatically on <a href="/glyph/book/macros/macros_core.html#m_include">included</a> files with a <code>.textile</code> or a <code>.txt</code> extension.</p> <strong>Aliases:</strong> <code>txt</code>@@ -97,8 +99,8 @@ <p><strong>Example:</strong> <code>textile[This is a *strong emphasis*.]</code></p>
- <div class="section"> -<h5 id="h_200">Parameters</h5> + <section class="section"> +<header><h1 id="h_200">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -110,110 +112,89 @@ <td>The Textile text to filter.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_highlight">highlight</h4> -<p>Highlights a piece of source code (second parameter) according to the specified language (first parameter). <span class="fmi">for more information on code highligting, see <a href="/glyph/book/text_editing/code.html#source_code">Source Code</a></span>.</p> + <section class="section"> +<header><h1 id="m_highlight">highlight</h1></header> +<p>Highlights a piece of source code (second parameter) according to the specified language (first parameter). <span class="fmi">for more information on <mark>code highligting</mark>, see <a href="/glyph/book/text_editing/code.html#source_code">Source Code</a></span>.</p> <div class="example"><p> <strong>Example</strong> </p> - <pre class="lazy"><span class="line-numbers"> 1 </span> highlight[ruby| -<span class="line-numbers"> 2 </span> def hello -<span class="line-numbers"> 3 </span> puts "Hello World" -<span class="line-numbers"> 4 </span> end -<span class="line-numbers"> 5 </span> ] -</pre></div> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> highlight[ruby| +<span class="no">2</span> def hello +<span class="no">3</span> puts "Hello World" +<span class="no">4</span> end +<span class="no">5</span> ]</pre></div> +</div></div> -</div> +</section> - <div class="navigation"><a href="/glyph/book/macros/macros_inline.html">Inline Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_structure.html">→ Structure Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/f_macros.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/macros/macros_inline.html">Inline Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_structure.html">→ Structure Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,75 +1,77 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Inline Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Inline Macros – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>Inline Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/macros/macros_block.html">Block Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_filters.html">→ Filter Macros</a></div> + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Inline Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/macros/macros_block.html">Block Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_filters.html">→ Filter Macros</a></nav> - <div class="section"> -<h4 id="m_anchor">anchor</h4> + <section class="section"> +<header><h1 id="m_anchor">anchor</h1></header> <p>Creates a named anchor (or bookmark).</p> <strong>Aliases:</strong> <code>bookmark, #</code> <p><strong>Example:</strong> <code>#[test|Test Bookmark]</code></p> - <div class="section"> -<h5 id="h_188">Parameters</h5> + <section class="section"> +<header><h1 id="h_188">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -87,22 +89,22 @@ <td>The contents of the bookmark <em>(optional)</em></td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_draftcomment">draftcomment</h4> + <section class="section"> +<header><h1 id="m_draftcomment">draftcomment</h1></header> <p>If the <a href="/glyph/book/config/document.html#s_document_draft"><code>document.draft</code></a> setting is set to <code>true</code>, displays a draft comment within the document.</p> <strong>Aliases:</strong> <code>dc</code> <p><strong>Example:</strong> <code>dc[This is printed only in draft documents.]</code></p> - <div class="section"> -<h5 id="h_190">Parameters</h5> + <section class="section"> +<header><h1 id="h_190">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -114,22 +116,22 @@ <td>The text of the comment.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_fmi">fmi</h4> + <section class="section"> +<header><h1 id="m_fmi">fmi</h1></header> <p>Creates a <em>For More Information</em> link (for an example usage, see the <a href="#m_link"><code>link</code></a> macro).</p> <p><strong>Example:</strong> <code>fmi[creating links|#links]</code></p> - <div class="section"> -<h5 id="h_192">Parameters</h5> + <section class="section"> +<header><h1 id="h_192">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -142,27 +144,27 @@ </tr>
<tr> - <td>0</td> + <td>1</td> <td>A valid bookmark within the document.</td> </tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_link">link</h4> -<p>Creates an hyperlink (<span class="fmi">for more information on creating links, see <a href="/glyph/book/text_editing/links.html#links">Links and Bookmarks</a></span>).</p> + <section class="section"> +<header><h1 id="m_link">link</h1></header> +<p>Creates an hyperlink (<span class="fmi">for more information on <mark>creating links</mark>, see <a href="/glyph/book/text_editing/links.html#links">Links and Bookmarks</a></span>).</p> <strong>Aliases:</strong> <code>=></code> <p><strong>Example:</strong> <code>=>[http://www.h3rald.com|H3RALD.com]</code></p> - <div class="section"> -<h5 id="h_194">Parameters</h5> + <section class="section"> +<header><h1 id="h_194">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -180,100 +182,78 @@ <td>The text of the link <em>(optional)</em>.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_todo">todo</h4> + <section class="section"> +<header><h1 id="m_todo">todo</h1></header> <p>Saves the value as a <span class="caps">TODO</span> item, which can be printed using the <a href="/glyph/book/ref_commands.html#c_todo"><code>todo</code></a> command and included in the document if the <a href="/glyph/book/config/document.html#s_document_draft"><code>document.draft</code></a> setting is set to <code>true</code>.</p> <strong>Aliases:</strong> <code>!</code> <p><strong>Example:</strong> <code>todo[Remember to do this.]</code></p> -</div> +</section> - <div class="navigation"><a href="/glyph/book/macros/macros_block.html">Block Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_filters.html">→ Filter Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_50.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/macros/macros_block.html">Block Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_filters.html">→ Filter Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,67 +1,69 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Structure Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Structure Macros – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <section id="container"> - <h2>Structure Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/macros/macros_filters.html">Filter Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/document.html">→ document.*</a></div> + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Structure Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/macros/macros_filters.html">Filter Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/document.html">→ document.*</a></nav> - <div class="section"> -<h4 id="m_article">article</h4> + <section class="section"> +<header><h1 id="m_article">article</h1></header> <p>Used to create a simple article. By default, it includes the following macros:</p> <ul> <li><code>document</code>@@ -87,8 +89,8 @@
- <div class="section"> -<h5 id="h_204">Parameters</h5> + <section class="section"> +<header><h1 id="h_204">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -100,11 +102,11 @@ <td>The article contents.</td>
</tr> </table> -</div> +</section> - <div class="section"> -<h5 id="h_205">Attributes</h5> + <section class="section"> +<header><h1 id="h_205">Attributes</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Attribute</th>@@ -140,14 +142,14 @@ <td>Contents to include instead of the default <code>halftitlepage</code> macro.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_book">book</h4> + <section class="section"> +<header><h1 id="m_book">book</h1></header> <p>Used to create a book. By default, it includes the following macros:</p> <ul> <li><code>document</code>@@ -174,8 +176,8 @@
- <div class="section"> -<h5 id="h_207">Parameters</h5> + <section class="section"> +<header><h1 id="h_207">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -187,11 +189,11 @@ <td>The article contents.</td>
</tr> </table> -</div> +</section> - <div class="section"> -<h5 id="h_208">Attributes</h5> + <section class="section"> +<header><h1 id="h_208">Attributes</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Attribute</th>@@ -245,22 +247,22 @@ <td>Contents to include within a <code>backmatter</code> macro.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_document">document</h4> + <section class="section"> +<header><h1 id="m_document">document</h1></header> <p>Creates an <code><html></code> tag and a <span class="caps">DOCTYPE</span> declaration. Called internally by the <a href="#m_book"><code>book</code></a> macro and the <a href="#m_article"><code>article</code></a> macro.</p> - <div class="section"> -<h5 id="h_210">Parameters</h5> + <section class="section"> +<header><h1 id="h_210">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -272,22 +274,22 @@ <td>The document contents.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_head">head</h4> + <section class="section"> +<header><h1 id="m_head">head</h1></header> <p>Creates a <code><head></code> tag, pre-populated with <code>title</code> and author/copyright <code><meta></code> tags.</p> - <div class="section"> -<h5 id="h_212">Parameters</h5> + <section class="section"> +<header><h1 id="h_212">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -299,14 +301,14 @@ <td>The head contents.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_section">section</h4> + <section class="section"> +<header><h1 id="m_section">section</h1></header> <p>Creates a section (<code><div></code> tag).</p> <strong>Aliases:</strong> <code>acknowledgement, addendum, afterword, appendix, bibliography, chapter, colophon, dedication, epilogue, foreword, glossary, imprint, index, inspiration, introduction, lof, lot, part, postscript, preface, prologue, promotion, references, section, section, volume</code>@@ -314,17 +316,18 @@
<div class="example"><p> <strong>Example</strong> </p> - <pre class="lazy"><span class="line-numbers"> 1 </span> section[ -<span class="line-numbers"> 2 </span> @title[Test Section] -<span class="line-numbers"> 3 </span> @id[test] -<span class="line-numbers"> 4 </span> ... -<span class="line-numbers"> 5 </span> ] -</pre></div> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> section[ +<span class="no">2</span> @title[Test Section] +<span class="no">3</span> @id[test] +<span class="no">4</span> ... +<span class="no">5</span> ]</pre></div> +</div></div> - <div class="section"> -<h5 id="h_214">Parameters</h5> + <section class="section"> +<header><h1 id="h_214">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -336,11 +339,11 @@ <td>The text of the section</td>
</tr> </table> -</div> +</section> - <div class="section"> -<h5 id="h_215">Attributes</h5> + <section class="section"> +<header><h1 id="h_215">Attributes</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Attribute</th>@@ -364,22 +367,22 @@ <td>If not blank, the header will not appear in the Table of Contents. <em>(optional)</em></td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_style">style</h4> -<p>Embeds the content of a <span class="caps">CSS</span> or Sass file within a <code><style></code> tag (<span class="fmi">for more information on stylesheets, see <a href="/glyph/book/text_editing/stylesheets.html#stylesheets">Adding Stylesheets</a></span>).</p> + <section class="section"> +<header><h1 id="m_style">style</h1></header> +<p>Embeds the content of a <span class="caps">CSS</span> or Sass file within a <code><style></code> tag (<span class="fmi">for more information on <mark>stylesheets</mark>, see <a href="/glyph/book/text_editing/stylesheets.html#stylesheets">Adding Stylesheets</a></span>).</p> <p><strong>Example:</strong> <code>style[default.css]</code></p> - <div class="section"> -<h5 id="h_217">Parameters</h5> + <section class="section"> +<header><h1 id="h_217">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -391,22 +394,22 @@ <td>The stylesheet file to embed.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="m_toc">toc</h4> + <section class="section"> +<header><h1 id="m_toc">toc</h1></header> <p>Generates a <em>Table of Contents</em> based on how sections are nested in the current document.</p> <p><strong>Example:</strong> <code>toc[1]</code></p> - <div class="section"> -<h5 id="h_219">Parameters</h5> + <section class="section"> +<header><h1 id="h_219">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -418,90 +421,68 @@ <td>The maximum header depth of the TOC <em>(optional)</em>.</td>
</tr> </table> -</div> +</section> -</div> +</section> - <div class="navigation"><a href="/glyph/book/macros/macros_filters.html">Filter Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/document.html">→ document.*</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_52.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/macros/macros_filters.html">Filter Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/config/document.html">→ document.*</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Command Reference</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Command Reference – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Command Reference</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Command Reference</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_macro.html">Macro Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_core.html">→ Core Macros</a></div> + <nav><a href="/glyph/book/troubleshooting/errors_macro.html">Macro Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_core.html">→ Core Macros</a></nav> <p>Glyph’s command-line interface has been built using the <a href="http://github.com/davetron5000/gli">gli</a> (Git-like interface) gem. Therefore, Glyph commands are all written like this:</p> <p><strong>glyph</strong> <em>global_options</em> <strong>command</strong> <em>options</em> <em>parameters</em></p> <p>Where:</p>@@ -66,22 +68,22 @@ <ul>
<li><em>global_options</em> and <em>options</em> are in the form: <code>-n</code> <em>value</em> or <code>--name=</code><em>value</em>, e.g. <code>-f pdf</code> or <code>--format=pdf</code></li> <li><em>parameters</em> are separated by whitespaces, and can be wrapped in quotes.</li> </ul> -<div class="section"> -<h3 id="h_103">Global Options</h3> -<div class="section"> -<h4 id="debug_switch"><code>-d</code>, <code>--debug</code></h4> +<section class="section"> +<header><h1 id="h_103">Global Options</h1></header> +<section class="section"> +<header><h1 id="debug_switch"><code>-d</code>, <code>--debug</code></h1></header> <p>If specified, the command is executed in debug mode and additional diagnostic information is printed on the screen.</p> -</div> +</section> -</div> -<div class="section"> -<h3 id="c_add">add</h3> +</section> +<section class="section"> +<header><h1 id="c_add">add</h1></header> <p>Creates a new text file in the <code>text/</code> folder.</p> <p><strong>Example:</strong> <code>glyph add introduction.textile</code></p> - <div class="section"> -<h4 id="h_106">Parameters</h4> + <section class="section"> +<header><h1 id="h_106">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -93,16 +95,16 @@ <td>The name (or relative path) of the new file to be created.</td>
</tr> </table> -</div> +</section> -</div> -<div class="section"> -<h3 id="c_compile">compile</h3> +</section> +<section class="section"> +<header><h1 id="c_compile">compile</h1></header> <p>Compiles a Glyph document into an output file. If no options are specified, the <code>document.glyph</code> file is used as source to produce a standalone HTML file.</p> <p><strong>Example:</strong> <code>glyph compile -f pdf</code></p> - <div class="section"> -<h4 id="h_108">Parameters</h4> + <section class="section"> +<header><h1 id="h_108">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -120,11 +122,11 @@ <td>The destination file <em>(Optional)</em>.</td>
</tr> </table> -</div> +</section> - <div class="section"> -<h4 id="h_109">Options</h4> + <section class="section"> +<header><h1 id="h_109">Options</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Option</th>@@ -157,12 +159,12 @@ </td>
</tr> </table> -</div> +</section> -</div> -<div class="section"> -<h3 id="c_config">config</h3> -Gets or sets a configuration setting in the project or global configuration file (<span class="fmi">for more information on configuration files, see <a href="/glyph/book/getting_started/configuration.html#cfg">Project Configuration</a></span>). +</section> +<section class="section"> +<header><h1 id="c_config">config</h1></header> +Gets or sets a configuration setting in the project or global configuration file (<span class="fmi">for more information on <mark>configuration files</mark>, see <a href="/glyph/book/getting_started/configuration.html#cfg">Project Configuration</a></span>). <div class="examples"> <p><strong>Examples:</strong></p>@@ -170,8 +172,8 @@ <code>glyph config document.filename</code><br /><code>glyph config -g document.author "Fabio Cevasco"</code><br />
</div> - <div class="section"> -<h4 id="h_111">Options</h4> + <section class="section"> +<header><h1 id="h_111">Options</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Option</th>@@ -186,11 +188,11 @@ </td>
</tr> </table> -</div> +</section> - <div class="section"> -<h4 id="h_112">Parameters</h4> + <section class="section"> +<header><h1 id="h_112">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -208,11 +210,11 @@ <td>The new value of the configuration setting.</td>
</tr> </table> -</div> +</section> -</div> -<div class="section"> -<h3 id="c_help">help</h3> +</section> +<section class="section"> +<header><h1 id="c_help">help</h1></header> Prints information about all Glyph commands or about one specific command. <div class="examples">@@ -221,8 +223,8 @@ <code>glyph help</code><br /><code>glyph help compile</code><br />
</div> - <div class="section"> -<h4 id="h_114">Parameters</h4> + <section class="section"> +<header><h1 id="h_114">Parameters</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Parameter</th>@@ -234,21 +236,21 @@ <td>A valid Glyph command.</td>
</tr> </table> -</div> +</section> -</div> -<div class="section"> -<h3 id="c_init">init</h3> +</section> +<section class="section"> +<header><h1 id="c_init">init</h1></header> Creates a new Glyph project in the current directory (if empty). <p><strong>Example:</strong> <code>glyph init</code></p> -</div> -<div class="section"> -<h3 id="c_outline">outline</h3> +</section> +<section class="section"> +<header><h1 id="c_outline">outline</h1></header> Display an outline of the current document. - <div class="section"> -<h4 id="h_117">Options</h4> + <section class="section"> +<header><h1 id="h_117">Options</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Option</th>@@ -286,7 +288,7 @@ </td>
</tr> </table> -</div> +</section> <div class="examples">@@ -294,10 +296,10 @@ <p><strong>Examples:</strong></p>
<code>glyph outline -it -l 1</code><br /><code>glyph outline -l 2</code><br /><code>glyph outline -f</code><br /> </div> -</div> -<div class="section"> -<h3 id="c_stats">stats</h3> -<p>Displays project statistics (<span class="fmi">for more information on this command, see <a href="/glyph/book/document.html#stats">Document Statistics</a></span>).</p> +</section> +<section class="section"> +<header><h1 id="c_stats">stats</h1></header> +<p>Displays project statistics (<span class="fmi">for more information on <mark>this command</mark>, see <a href="/glyph/book/document.html#stats">Document Statistics</a></span>).</p> <div class="examples"> <p><strong>Examples:</strong></p>@@ -305,8 +307,8 @@ <code>glyph stats -m </code><br /><code>glyph stats --link=h3rald.com</code><br />
</div> - <div class="section"> -<h4 id="h_119">Options</h4> + <section class="section"> +<header><h1 id="h_119">Options</h1></header> <table style="width:100%;"> <tr> <th style="width:30%">Option</th>@@ -384,95 +386,73 @@ </td>
</tr> </table> -</div> +</section> -</div> -<div class="section"> -<h3 id="c_todo">todo</h3> +</section> +<section class="section"> +<header><h1 id="c_todo">todo</h1></header> Prints all the todo items saved using the <a href="/glyph/book/macros/macros_inline.html#m_todo"><code>todo</code></a> macro. <p><strong>Example:</strong> <code>glyph todo</code></p> -</div> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_macro.html">Macro Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_core.html">→ Core Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/cmd_ref.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/troubleshooting/errors_macro.html">Macro Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/macros/macros_core.html">→ Core Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,201 +1,185 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Bookmark Statistics</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Bookmark Statistics – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + - <h2>Bookmark Statistics</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/stats/snippets.html">Snippet Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/links.html">→ Link Statistics</a></div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Bookmark Statistics</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/stats/snippets.html">Snippet Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/links.html">→ Link Statistics</a></nav> - <div class="section"> -<h4 id="h_62">Displaying stats about all bookmarks</h4> + <section class="section"> +<header><h1 id="h_62">Displaying stats about all bookmarks</h1></header> <p>To display statistics about all bookmarks, execute <code>glyph stats --bookmarks</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Bookmarks -<span class="line-numbers"> 2 </span> -- Total Bookmarks: 241 -<span class="line-numbers"> 3 </span> -- Total Referenced Bookmarks: 89 -<span class="line-numbers"> 4 </span> -- Total Unreferenced Bookmarks: 155 -<span class="line-numbers"> 5 </span> -- Bookmarks: -<span class="line-numbers"> 6 </span> attribute_intro auto_regeneration c_add c_compile c_config -<span class="line-numbers"> 7 </span> c_help c_init c_outline c_todo cfg -<span class="line-numbers"> 8 </span> cfg_document cfg_filters cfg_ref cmd_ref compile -<span class="line-numbers"> 9 </span> [...] -<span class="line-numbers"> 10 </span> -- Referenced Bookmarks: -<span class="line-numbers"> 11 </span> - attribute_intro (1) -<span class="line-numbers"> 12 </span> - auto_regeneration (2) -<span class="line-numbers"> 13 </span> - c_add (2) -<span class="line-numbers"> 14 </span> - c_compile (10) -<span class="line-numbers"> 15 </span> - c_config (6) -<span class="line-numbers"> 16 </span> - c_init (1) -<span class="line-numbers"> 17 </span> - c_outline (1) -<span class="line-numbers"> 18 </span> [...] -<span class="line-numbers"> 19 </span> -- Unreferenced Bookmarks: -<span class="line-numbers"> 20 </span> c_help cmd_ref expanded_values extending h_1 -<span class="line-numbers"> 21 </span> h_10 h_102 h_105 h_107 h_109 -<span class="line-numbers"> 22 </span> h_111 h_112 h_114 h_115 h_117 -<span class="line-numbers"> 23 </span> [...] -</pre> - <div class="section"> -<h5 id="h_63">Remarks</h5> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===== Bookmarks +<span class="no"> 2</span> -- Total Bookmarks: 241 +<span class="no"> 3</span> -- Total Referenced Bookmarks: 89 +<span class="no"> 4</span> -- Total Unreferenced Bookmarks: 155 +<span class="no"> 5</span> -- Bookmarks: +<span class="no"> 6</span> attribute_intro auto_regeneration c_add c_compile c_config +<span class="no"> 7</span> c_help c_init c_outline c_todo cfg +<span class="no"> 8</span> cfg_document cfg_filters cfg_ref cmd_ref compile +<span class="no"> 9</span> [...] +<span class="no"><strong>10</strong></span> -- Referenced Bookmarks: +<span class="no">11</span> - attribute_intro (1) +<span class="no">12</span> - auto_regeneration (2) +<span class="no">13</span> - c_add (2) +<span class="no">14</span> - c_compile (10) +<span class="no">15</span> - c_config (6) +<span class="no">16</span> - c_init (1) +<span class="no">17</span> - c_outline (1) +<span class="no">18</span> [...] +<span class="no">19</span> -- Unreferenced Bookmarks: +<span class="no"><strong>20</strong></span> c_help cmd_ref expanded_values extending h_1 +<span class="no">21</span> h_10 h_102 h_105 h_107 h_109 +<span class="no">22</span> h_111 h_112 h_114 h_115 h_117 +<span class="no">23</span> [...]</pre></div> +</div> + + <section class="section"> +<header><h1 id="h_63">Remarks</h1></header> <ul> <li>All the automatically-generated bookmarks (like headers, starting with <code>h_</code>) are included as well.</li> </ul> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="h_64">Displaying stats about a single bookmark</h4> + <section class="section"> +<header><h1 id="h_64">Displaying stats about a single bookmark</h1></header> <p>To display statistics about a single bookmark (e.g. <code>yardoc</code>), execute <code>glyph stats --bookmark=c_config</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Bookmark 'c_config' (header) -<span class="line-numbers"> 2 </span> -- Defined in: text/ref_commands.glyph -<span class="line-numbers"> 3 </span> -- Referenced in: -<span class="line-numbers"> 4 </span> - text/changelog.glyph (2) -<span class="line-numbers"> 5 </span> - text/getting_started/configuration.glyph (1) -<span class="line-numbers"> 6 </span> - text/troubleshooting/errors_command.glyph (3) -</pre> - <div class="section"> -<h5 id="h_65">Remarks</h5> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> ===== Bookmark 'c_config' (header) +<span class="no">2</span> -- Defined in: text/ref_commands.glyph +<span class="no">3</span> -- Referenced in: +<span class="no">4</span> - text/changelog.glyph (2) +<span class="no">5</span> - text/getting_started/configuration.glyph (1) +<span class="no">6</span> - text/troubleshooting/errors_command.glyph (3)</pre></div> +</div> + + <section class="section"> +<header><h1 id="h_65">Remarks</h1></header> <ul> <li>Do not prepend the bookmark ID with <code>#</code>.</li> </ul> -</div> +</section> -</div> - <div class="navigation"><a href="/glyph/book/stats/snippets.html">Snippet Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/links.html">→ Link Statistics</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/stats_bookmarks.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/stats/snippets.html">Snippet Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/links.html">→ Link Statistics</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,242 +1,226 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Link Statistics</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Link Statistics – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Link Statistics</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Link Statistics</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/stats/bookmarks.html">Bookmark Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/internals.html">→ A quick look at Glyph's internals</a></div> + <nav><a href="/glyph/book/stats/bookmarks.html">Bookmark Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/internals.html">→ A quick look at Glyph's internals</a></nav> - <div class="section"> -<h4 id="h_67">Displaying stats about all links</h4> + <section class="section"> +<header><h1 id="h_67">Displaying stats about all links</h1></header> <p>To display statistics about all links, execute <code>glyph stats --links</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Links -<span class="line-numbers"> 2 </span> -- Total Internal Links: 89 -<span class="line-numbers"> 3 </span> -- Internal Links -<span class="line-numbers"> 4 </span> - #attribute_intro -<span class="line-numbers"> 5 </span> - #auto_regeneration -<span class="line-numbers"> 6 </span> - #c_add -<span class="line-numbers"> 7 </span> - #c_compile -<span class="line-numbers"> 8 </span> - #c_config -<span class="line-numbers"> 9 </span> - #c_init -<span class="line-numbers"> 10 </span> - #c_outline -<span class="line-numbers"> 11 </span> - #c_stats -<span class="line-numbers"> 12 </span> - #c_todo -<span class="line-numbers"> 13 </span> - #cfg -<span class="line-numbers"> 14 </span> - #cfg_document -<span class="line-numbers"> 15 </span> - #cfg_filters -<span class="line-numbers"> 16 </span> [...] -<span class="line-numbers"> 17 </span> -- Total External Links: 95 -<span class="line-numbers"> 18 </span> -- External Links -<span class="line-numbers"> 19 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph -<span class="line-numbers"> 20 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/Document -<span class="line-numbers"> 21 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/Interpreter -<span class="line-numbers"> 22 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/Macro -<span class="line-numbers"> 23 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/Macro/Validators -<span class="line-numbers"> 24 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/Macro:update_source -<span class="line-numbers"> 25 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/MacroNode -<span class="line-numbers"> 26 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/Parser -<span class="line-numbers"> 27 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Glyph/SyntaxNode -<span class="line-numbers"> 28 </span> - <span class="InvalidIllegal">&</span>[yardoc]/Macro -<span class="line-numbers"> 29 </span> - http://code.google.com/p/wkhtmltopdf/ -<span class="line-numbers"> 30 </span> - http://coderay.rubychan.de/ -<span class="line-numbers"> 31 </span> - http://coderay.rubychan.de/doc/classes/CodeRay/Encoders/HTML.html -<span class="line-numbers"> 32 </span> [...] -</pre> - <div class="section"> -<h5 id="h_68">Remarks</h5> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===== Links +<span class="no"> 2</span> -- Total Internal Links: 89 +<span class="no"> 3</span> -- Internal Links +<span class="no"> 4</span> - #attribute_intro +<span class="no"> 5</span> - #auto_regeneration +<span class="no"> 6</span> - #c_add +<span class="no"> 7</span> - #c_compile +<span class="no"> 8</span> - #c_config +<span class="no"> 9</span> - #c_init +<span class="no"><strong>10</strong></span> - #c_outline +<span class="no">11</span> - #c_stats +<span class="no">12</span> - #c_todo +<span class="no">13</span> - #cfg +<span class="no">14</span> - #cfg_document +<span class="no">15</span> - #cfg_filters +<span class="no">16</span> [...] +<span class="no">17</span> -- Total External Links: 95 +<span class="no">18</span> -- External Links +<span class="no">19</span> - <span class="er">&</span>[yardoc]/Glyph +<span class="no"><strong>20</strong></span> - <span class="er">&</span>[yardoc]/Glyph/Document +<span class="no">21</span> - <span class="er">&</span>[yardoc]/Glyph/Interpreter +<span class="no">22</span> - <span class="er">&</span>[yardoc]/Glyph/Macro +<span class="no">23</span> - <span class="er">&</span>[yardoc]/Glyph/Macro/Validators +<span class="no">24</span> - <span class="er">&</span>[yardoc]/Glyph/Macro:update_source +<span class="no">25</span> - <span class="er">&</span>[yardoc]/Glyph/MacroNode +<span class="no">26</span> - <span class="er">&</span>[yardoc]/Glyph/Parser +<span class="no">27</span> - <span class="er">&</span>[yardoc]/Glyph/SyntaxNode +<span class="no">28</span> - <span class="er">&</span>[yardoc]/Macro +<span class="no">29</span> - http://code.google.com/p/wkhtmltopdf/ +<span class="no"><strong>30</strong></span> - http://coderay.rubychan.de/ +<span class="no">31</span> - http://coderay.rubychan.de/doc/classes/CodeRay/Encoders/HTML.html +<span class="no">32</span> [...]</pre></div> +</div> + + <section class="section"> +<header><h1 id="h_68">Remarks</h1></header> <ul> <li>The only criteria used to determine if a link is internal is whether it starts with a <code>#</code> or not.</li> </ul> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="h_69">Displaying stats about links matching a regular expression</h4> + <section class="section"> +<header><h1 id="h_69">Displaying stats about links matching a regular expression</h1></header> <p>To display statistics about links matching a regular expression (e.g. <code>/c_/</code>), execute <code>glyph stats --link=c_</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Links matching /c_/ -<span class="line-numbers"> 2 </span> -- Total Links: 8 -<span class="line-numbers"> 3 </span> -- Link Targets: -<span class="line-numbers"> 4 </span> - #c_add -<span class="line-numbers"> 5 </span> - #c_compile -<span class="line-numbers"> 6 </span> - #c_config -<span class="line-numbers"> 7 </span> - #c_init -<span class="line-numbers"> 8 </span> - #c_outline -<span class="line-numbers"> 9 </span> - #c_stats -<span class="line-numbers"> 10 </span> - #c_todo -<span class="line-numbers"> 11 </span> - #esc_quot -<span class="line-numbers"> 12 </span> -- Details: -<span class="line-numbers"> 13 </span> - #c_add (2) -<span class="line-numbers"> 14 </span> - text/troubleshooting/errors_command.glyph (1) -<span class="line-numbers"> 15 </span> - text/troubleshooting/errors_generic.glyph (1) -<span class="line-numbers"> 16 </span> - #c_compile (10) -<span class="line-numbers"> 17 </span> - text/changelog.glyph (1) -<span class="line-numbers"> 18 </span> - text/compiling/compiling.glyph (2) -<span class="line-numbers"> 19 </span> - text/compiling/lite_mode.glyph (1) -<span class="line-numbers"> 20 </span> - text/compiling/programmatic_usage.glyph (2) -<span class="line-numbers"> 21 </span> - text/getting_started/create_project.glyph (1) -<span class="line-numbers"> 22 </span> - text/ref_config.glyph (1) -<span class="line-numbers"> 23 </span> - text/troubleshooting/errors_command.glyph (2) -<span class="line-numbers"> 24 </span> - #c_config (6) -<span class="line-numbers"> 25 </span> - text/changelog.glyph (2) -<span class="line-numbers"> 26 </span> - text/getting_started/configuration.glyph (1) -<span class="line-numbers"> 27 </span> - text/troubleshooting/errors_command.glyph (3) -<span class="line-numbers"> 28 </span> - #c_init (1) -<span class="line-numbers"> 29 </span> - text/troubleshooting/errors_generic.glyph (1) -<span class="line-numbers"> 30 </span> - #c_outline (1) -<span class="line-numbers"> 31 </span> - text/changelog.glyph (1) -<span class="line-numbers"> 32 </span> - #c_stats (1) -<span class="line-numbers"> 33 </span> - text/stats/stats.glyph (1) -<span class="line-numbers"> 34 </span> - #c_todo (1) -<span class="line-numbers"> 35 </span> - text/macros/macros_inline.glyph (1) -<span class="line-numbers"> 36 </span> - #esc_quot (2) -<span class="line-numbers"> 37 </span> - text/extending/macro_def.glyph (1) -<span class="line-numbers"> 38 </span> - text/text_editing/macro_intro.glyph (1) -</pre> - <div class="section"> -<h5 id="h_70">Remarks</h5> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===== Links matching /c_/ +<span class="no"> 2</span> -- Total Links: 8 +<span class="no"> 3</span> -- Link Targets: +<span class="no"> 4</span> - #c_add +<span class="no"> 5</span> - #c_compile +<span class="no"> 6</span> - #c_config +<span class="no"> 7</span> - #c_init +<span class="no"> 8</span> - #c_outline +<span class="no"> 9</span> - #c_stats +<span class="no"><strong>10</strong></span> - #c_todo +<span class="no">11</span> - #esc_quot +<span class="no">12</span> -- Details: +<span class="no">13</span> - #c_add (2) +<span class="no">14</span> - text/troubleshooting/errors_command.glyph (1) +<span class="no">15</span> - text/troubleshooting/errors_generic.glyph (1) +<span class="no">16</span> - #c_compile (10) +<span class="no">17</span> - text/changelog.glyph (1) +<span class="no">18</span> - text/compiling/compiling.glyph (2) +<span class="no">19</span> - text/compiling/lite_mode.glyph (1) +<span class="no"><strong>20</strong></span> - text/compiling/programmatic_usage.glyph (2) +<span class="no">21</span> - text/getting_started/create_project.glyph (1) +<span class="no">22</span> - text/ref_config.glyph (1) +<span class="no">23</span> - text/troubleshooting/errors_command.glyph (2) +<span class="no">24</span> - #c_config (6) +<span class="no">25</span> - text/changelog.glyph (2) +<span class="no">26</span> - text/getting_started/configuration.glyph (1) +<span class="no">27</span> - text/troubleshooting/errors_command.glyph (3) +<span class="no">28</span> - #c_init (1) +<span class="no">29</span> - text/troubleshooting/errors_generic.glyph (1) +<span class="no"><strong>30</strong></span> - #c_outline (1) +<span class="no">31</span> - text/changelog.glyph (1) +<span class="no">32</span> - #c_stats (1) +<span class="no">33</span> - text/stats/stats.glyph (1) +<span class="no">34</span> - #c_todo (1) +<span class="no">35</span> - text/macros/macros_inline.glyph (1) +<span class="no">36</span> - #esc_quot (2) +<span class="no">37</span> - text/extending/macro_def.glyph (1) +<span class="no">38</span> - text/text_editing/macro_intro.glyph (1)</pre></div> +</div> + + <section class="section"> +<header><h1 id="h_70">Remarks</h1></header> <ul> <li>No distinction between external and internal targets is made.</li> </ul> -</div> +</section> -</div> - <div class="navigation"><a href="/glyph/book/stats/bookmarks.html">Bookmark Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/internals.html">→ A quick look at Glyph's internals</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/stats_links.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/stats/bookmarks.html">Bookmark Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/extending/internals.html">→ A quick look at Glyph's internals</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,225 +1,209 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Macro Statistics</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Macro Statistics – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> - <h2>Macro Statistics</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/stats/stats.html">Using the stats command ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/snippets.html">→ Snippet Statistics</a></div> + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Macro Statistics</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/stats/stats.html">Using the stats command ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/snippets.html">→ Snippet Statistics</a></nav> - <div class="section"> -<h4 id="h_52">Displaying stats about all macros</h4> + <section class="section"> +<header><h1 id="h_52">Displaying stats about all macros</h1></header> <p>To display statistics about all macros, execute <code>glyph stats --macros</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Macros -<span class="line-numbers"> 2 </span> -- Total Macro Instances: 2497 -<span class="line-numbers"> 3 </span> -- Total Macro Definitions: 65 -<span class="line-numbers"> 4 </span> -- Total Macro Aliases: 57 -<span class="line-numbers"> 5 </span> -- Total Used Macro Definitions: 56 -<span class="line-numbers"> 6 </span> -- Macro Definitions: -<span class="line-numbers"> 7 </span> #> $> %> alias: aliases -<span class="line-numbers"> 8 </span> anchor and article author block_example -<span class="line-numbers"> 9 </span> book box class codeblock comment -<span class="line-numbers"> 10 </span> condition config config: config_table default -<span class="line-numbers"> 11 </span> document draftcomment eq error_table escape -<span class="line-numbers"> 12 </span> example examples features figure fmi -<span class="line-numbers"> 13 </span> head highlight image include issue -<span class="line-numbers"> 14 </span> link macro: markdown match navigation -<span class="line-numbers"> 15 </span> not note option or parameters -<span class="line-numbers"> 16 </span> pubdate ref_config ref_error ref_macro release -<span class="line-numbers"> 17 </span> revision rewrite: ruby section snippet -<span class="line-numbers"> 18 </span> snippet: stats_for style subtitle textile -<span class="line-numbers"> 19 </span> title toc todo values |xml| -<span class="line-numbers"> 20 </span> -<span class="line-numbers"> 21 </span> -- Used Macro Definitions: -<span class="line-numbers"> 22 </span> #> $> %> aliases anchor -<span class="line-numbers"> 23 </span> and author block_example book box -<span class="line-numbers"> 24 </span> class codeblock comment condition config -<span class="line-numbers"> 25 </span> config_table default document eq error_table -<span class="line-numbers"> 26 </span> escape example examples features figure -<span class="line-numbers"> 27 </span> fmi head highlight image include -<span class="line-numbers"> 28 </span> issue link note option or -<span class="line-numbers"> 29 </span> parameters pubdate ref_config ref_error ref_macro -<span class="line-numbers"> 30 </span> release revision rewrite: ruby section -<span class="line-numbers"> 31 </span> snippet snippet: stats_for style subtitle -<span class="line-numbers"> 32 </span> textile title toc todo values -<span class="line-numbers"> 33 </span> |xml| -</pre> - <div class="section"> -<h5 id="h_53">Remarks</h5> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===== Macros +<span class="no"> 2</span> -- Total Macro Instances: 2497 +<span class="no"> 3</span> -- Total Macro Definitions: 65 +<span class="no"> 4</span> -- Total Macro Aliases: 57 +<span class="no"> 5</span> -- Total Used Macro Definitions: 56 +<span class="no"> 6</span> -- Macro Definitions: +<span class="no"> 7</span> #<span class="er">></span> $<span class="er">></span> %<span class="er">></span> alias: aliases +<span class="no"> 8</span> anchor and article author block_example +<span class="no"> 9</span> book box class codeblock comment +<span class="no"><strong>10</strong></span> condition config config: config_table default +<span class="no">11</span> document draftcomment eq error_table escape +<span class="no">12</span> example examples features figure fmi +<span class="no">13</span> head highlight image include issue +<span class="no">14</span> link macro: markdown match navigation +<span class="no">15</span> not note option or parameters +<span class="no">16</span> pubdate ref_config ref_error ref_macro release +<span class="no">17</span> revision rewrite: ruby section snippet +<span class="no">18</span> snippet: stats_for style subtitle textile +<span class="no">19</span> title toc todo values |xml| +<span class="no"><strong>20</strong></span> +<span class="no">21</span> -- Used Macro Definitions: +<span class="no">22</span> #<span class="er">></span> $<span class="er">></span> %<span class="er">></span> aliases anchor +<span class="no">23</span> and author block_example book box +<span class="no">24</span> class codeblock comment condition config +<span class="no">25</span> config_table default document eq error_table +<span class="no">26</span> escape example examples features figure +<span class="no">27</span> fmi head highlight image include +<span class="no">28</span> issue link note option or +<span class="no">29</span> parameters pubdate ref_config ref_error ref_macro +<span class="no"><strong>30</strong></span> release revision rewrite: ruby section +<span class="no">31</span> snippet snippet: stats_for style subtitle +<span class="no">32</span> textile title toc todo values +<span class="no">33</span> |xml|</pre></div> +</div> + + <section class="section"> +<header><h1 id="h_53">Remarks</h1></header> <ul> <li>Only macro <em>definitions</em> (not their <em>aliases</em>) are displayed, both default and user-defined.</li> <li>The <code>|xml|</code> macro is a special macro used if the <a href="/glyph/book/config/options.html#s_options_xml_fallback"><code>options.xml_fallback</code></a> setting is enabled.</li> <li>There’s no distinction between macros defined by the user and macros defined by Glyph itself.</li> </ul> -</div> +</section> + +</section> + <section class="section"> +<header><h1 id="h_54">Displaying stats about a single macro</h1></header> +<p>To display statistics about a single macro (e.g. <code>note</code>), execute <code>glyph stats --macro=note</code>. Glyph displays something like this:</p> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===== Macro 'note' +<span class="no"> 2</span> -- Total Instances: 18 +<span class="no"> 3</span> -- Occurrences: +<span class="no"> 4</span> - text/compiling/compiling.glyph (2) +<span class="no"> 5</span> - text/compiling/programmatic_usage.glyph (1) +<span class="no"> 6</span> - text/extending/params_attrs.glyph (1) +<span class="no"> 7</span> - text/getting_started/configuration.glyph (1) +<span class="no"> 8</span> - text/stats/macros.glyph (2) +<span class="no"> 9</span> - text/text_editing/attribute_intro.glyph (1) +<span class="no"><strong>10</strong></span> - text/text_editing/esc_quot.glyph (1) +<span class="no">11</span> - text/text_editing/images.glyph (1) +<span class="no">12</span> - text/text_editing/inclusions.glyph (3) +<span class="no">13</span> - text/text_editing/links.glyph (1) +<span class="no">14</span> - text/text_editing/raw_html.glyph (1) +<span class="no">15</span> - text/text_editing/section_aliases.glyph (1) +<span class="no">16</span> - text/text_editing/xml_fallback.glyph (2)</pre></div> </div> - <div class="section"> -<h4 id="h_54">Displaying stats about a single macro</h4> -<p>To display statistics about a single macro (e.g. <code>note</code>), execute <code>glyph stats --macro=note</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Macro 'note' -<span class="line-numbers"> 2 </span> -- Total Instances: 18 -<span class="line-numbers"> 3 </span> -- Occurrences: -<span class="line-numbers"> 4 </span> - text/compiling/compiling.glyph (2) -<span class="line-numbers"> 5 </span> - text/compiling/programmatic_usage.glyph (1) -<span class="line-numbers"> 6 </span> - text/extending/params_attrs.glyph (1) -<span class="line-numbers"> 7 </span> - text/getting_started/configuration.glyph (1) -<span class="line-numbers"> 8 </span> - text/stats/macros.glyph (2) -<span class="line-numbers"> 9 </span> - text/text_editing/attribute_intro.glyph (1) -<span class="line-numbers"> 10 </span> - text/text_editing/esc_quot.glyph (1) -<span class="line-numbers"> 11 </span> - text/text_editing/images.glyph (1) -<span class="line-numbers"> 12 </span> - text/text_editing/inclusions.glyph (3) -<span class="line-numbers"> 13 </span> - text/text_editing/links.glyph (1) -<span class="line-numbers"> 14 </span> - text/text_editing/raw_html.glyph (1) -<span class="line-numbers"> 15 </span> - text/text_editing/section_aliases.glyph (1) -<span class="line-numbers"> 16 </span> - text/text_editing/xml_fallback.glyph (2) -</pre> - <div class="section"> -<h5 id="h_55">Remarks</h5> + <section class="section"> +<header><h1 id="h_55">Remarks</h1></header> <ul> <li>All the instances of the specified macro definition <em>and all its aliases</em> are collected, regardless whether a definition or an alias is specified.</li> <li>If you use custom macros, make sure they call the <a href="http://yardoc.org/docs/h3rald-glyph/Glyph/Macro:update_source">Macro#update_source</a> appropriately method if necessary.</li> <li>If macros are used within <a href="/glyph/book/extending/interpreting.html#rewriting">rewritten</a> macros, they’ll be also listed in each file where the rewritten macro is used.</li> </ul> -</div> +</section> -</div> - <div class="navigation"><a href="/glyph/book/stats/stats.html">Using the stats command ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/snippets.html">→ Snippet Statistics</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/stats_macros.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/stats/stats.html">Using the stats command ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/snippets.html">→ Snippet Statistics</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,202 +1,186 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Snippet Statistics</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Snippet Statistics – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Snippet Statistics</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Snippet Statistics</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/stats/macros.html">Macro Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/bookmarks.html">→ Bookmark Statistics</a></div> + <nav><a href="/glyph/book/stats/macros.html">Macro Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/bookmarks.html">→ Bookmark Statistics</a></nav> - <div class="section"> -<h4 id="h_57">Displaying stats about all snippets</h4> + <section class="section"> +<header><h1 id="h_57">Displaying stats about all snippets</h1></header> <p>To display statistics about all snippets, execute <code>glyph stats --snippets</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Snippets -<span class="line-numbers"> 2 </span> -- Total Snippets: 21 -<span class="line-numbers"> 3 </span> -- Total Used Snippets: 21 -<span class="line-numbers"> 4 </span> -- Total Unused Snippets: 0 -<span class="line-numbers"> 5 </span> -- Snippets: -<span class="line-numbers"> 6 </span> bin_params called_on_files coderay filter_by_ext gcode -<span class="line-numbers"> 7 </span> glang htmlcode img_attrs img_file macros -<span class="line-numbers"> 8 </span> markups only_after_declaration only_defined_through opt prince -<span class="line-numbers"> 9 </span> referenced_with_path sq_esc unsafe uv wkhtml -<span class="line-numbers"> 10 </span> yardoc -<span class="line-numbers"> 11 </span> -- Used Snippets: -<span class="line-numbers"> 12 </span> bin_params called_on_files coderay filter_by_ext gcode -<span class="line-numbers"> 13 </span> glang htmlcode img_attrs img_file macros -<span class="line-numbers"> 14 </span> markups only_after_declaration only_defined_through opt prince -<span class="line-numbers"> 15 </span> referenced_with_path sq_esc unsafe uv wkhtml -<span class="line-numbers"> 16 </span> yardoc -</pre> - <div class="section"> -<h5 id="h_58">Remarks</h5> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===== Snippets +<span class="no"> 2</span> -- Total Snippets: 21 +<span class="no"> 3</span> -- Total Used Snippets: 21 +<span class="no"> 4</span> -- Total Unused Snippets: 0 +<span class="no"> 5</span> -- Snippets: +<span class="no"> 6</span> bin_params called_on_files coderay filter_by_ext gcode +<span class="no"> 7</span> glang htmlcode img_attrs img_file macros +<span class="no"> 8</span> markups only_after_declaration only_defined_through opt prince +<span class="no"> 9</span> referenced_with_path sq_esc unsafe uv wkhtml +<span class="no"><strong>10</strong></span> yardoc +<span class="no">11</span> -- Used Snippets: +<span class="no">12</span> bin_params called_on_files coderay filter_by_ext gcode +<span class="no">13</span> glang htmlcode img_attrs img_file macros +<span class="no">14</span> markups only_after_declaration only_defined_through opt prince +<span class="no">15</span> referenced_with_path sq_esc unsafe uv wkhtml +<span class="no">16</span> yardoc</pre></div> +</div> + + <section class="section"> +<header><h1 id="h_58">Remarks</h1></header> <ul> <li>Information on snippet usage and definitions is available only when displaying statistics for a single snippet.</li> </ul> -</div> +</section> -</div> +</section> - <div class="section"> -<h4 id="h_59">Displaying stats about a single snippet</h4> + <section class="section"> +<header><h1 id="h_59">Displaying stats about a single snippet</h1></header> <p>To display statistics about a single snippet (e.g. <code>yardoc</code>), execute <code>glyph stats --snippet=yardoc</code>. Glyph displays something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ===== Snippet 'yardoc' -<span class="line-numbers"> 2 </span> -- Definition: -<span class="line-numbers"> 3 </span> ------------------- -<span class="line-numbers"> 4 </span> http://yardoc.org/docs/h3rald-glyph -<span class="line-numbers"> 5 </span> ------------------- -<span class="line-numbers"> 6 </span> -- Total Used Instances: 18 -<span class="line-numbers"> 7 </span> -- Usage Details: -<span class="line-numbers"> 8 </span> - text/extending/bookmarks_headers.glyph (1) -<span class="line-numbers"> 9 </span> - text/extending/further_reading.glyph (5) -<span class="line-numbers"> 10 </span> - text/extending/internals.glyph (5) -<span class="line-numbers"> 11 </span> - text/extending/macro_def.glyph (3) -<span class="line-numbers"> 12 </span> - text/extending/validators.glyph (1) -<span class="line-numbers"> 13 </span> - text/macros/macros_core.glyph (2) -<span class="line-numbers"> 14 </span> - text/stats/macros.glyph (1) -</pre> - <div class="section"> -<h5 id="h_60">Remarks</h5> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===== Snippet 'yardoc' +<span class="no"> 2</span> -- Definition: +<span class="no"> 3</span> ------------------- +<span class="no"> 4</span> http://yardoc.org/docs/h3rald-glyph +<span class="no"> 5</span> ------------------- +<span class="no"> 6</span> -- Total Used Instances: 18 +<span class="no"> 7</span> -- Usage Details: +<span class="no"> 8</span> - text/extending/bookmarks_headers.glyph (1) +<span class="no"> 9</span> - text/extending/further_reading.glyph (5) +<span class="no"><strong>10</strong></span> - text/extending/internals.glyph (5) +<span class="no">11</span> - text/extending/macro_def.glyph (3) +<span class="no">12</span> - text/extending/validators.glyph (1) +<span class="no">13</span> - text/macros/macros_core.glyph (2) +<span class="no">14</span> - text/stats/macros.glyph (1)</pre></div> +</div> + + <section class="section"> +<header><h1 id="h_60">Remarks</h1></header> <ul> <li>Nested snippets appear as within the file containing the top-level snippet.</li> </ul> -</div> +</section> -</div> - <div class="navigation"><a href="/glyph/book/stats/macros.html">Macro Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/bookmarks.html">→ Bookmark Statistics</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/stats_snippets.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/stats/macros.html">Macro Statistics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/bookmarks.html">→ Bookmark Statistics</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,84 +1,88 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Using the stats command</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Using the stats command – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Using the stats command</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Using the stats command</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/compiling/programmatic_usage.html">Using Glyph programmatically ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/macros.html">→ Macro Statistics</a></div> + <nav><a href="/glyph/book/compiling/programmatic_usage.html">Using Glyph programmatically ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/macros.html">→ Macro Statistics</a></nav> <p>Glyph includes a <a href="/glyph/book/ref_commands.html#c_stats"><code>stats</code></a> command that can be used to display useful statistics about your Glyph project. If you try running Glyph's command help, you'll see that this command can take quite a few options:</p> -<pre class="lazy"><span class="line-numbers"> 1 </span> $ glyph help stats -<span class="line-numbers"> 2 </span> ===================================== -<span class="line-numbers"> 3 </span> Glyph v.0.4.0 -<span class="line-numbers"> 4 </span> ===================================== -<span class="line-numbers"> 5 </span> stats [options] -<span class="line-numbers"> 6 </span> Display statistics -<span class="line-numbers"> 7 </span> -<span class="line-numbers"> 8 </span> Options: -<span class="line-numbers"> 9 </span> -b, --bookmarks - Display stats about bookmarks -<span class="line-numbers"> 10 </span> --bookmark=arg - Display stats about a single bookmark -<span class="line-numbers"> 11 </span> -f, --files - Display stats about project files -<span class="line-numbers"> 12 </span> -l, --links - Display stats about links -<span class="line-numbers"> 13 </span> --link=arg - Display stats about links matching a regular expression -<span class="line-numbers"> 14 </span> -m, --macros - Display stats about macros -<span class="line-numbers"> 15 </span> --macro=arg - Display stats about a single macro -<span class="line-numbers"> 16 </span> -s, --snippets - Display stats about snippets -<span class="line-numbers"> 17 </span> --snippet=arg - Display stats about a single snippet -</pre> +<div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> $ glyph help stats +<span class="no"> 2</span> ===================================== +<span class="no"> 3</span> Glyph v.0.4.1 +<span class="no"> 4</span> ===================================== +<span class="no"> 5</span> stats [options] +<span class="no"> 6</span> Display statistics +<span class="no"> 7</span> +<span class="no"> 8</span> Options: +<span class="no"> 9</span> -b, --bookmarks - Display stats about bookmarks +<span class="no"><strong>10</strong></span> --bookmark=arg - Display stats about a single bookmark +<span class="no">11</span> -f, --files - Display stats about project files +<span class="no">12</span> -l, --links - Display stats about links +<span class="no">13</span> --link=arg - Display stats about links matching a regular expression +<span class="no">14</span> -m, --macros - Display stats about macros +<span class="no">15</span> --macro=arg - Display stats about a single macro +<span class="no">16</span> -s, --snippets - Display stats about snippets +<span class="no">17</span> --snippet=arg - Display stats about a single snippet</pre></div> +</div> + <p>If no options are specified, the command returns a summary containing different element totals, i.e.:</p> <ul> <li>The files used in the project</li>@@ -88,118 +92,98 @@ <li>Bookmarks</li>
<li>Links and references</li> </ul> <p>Example:</p> -<pre class="lazy"><span class="line-numbers"> 1 </span> ===================================== -<span class="line-numbers"> 2 </span> Glyph - Statistics -<span class="line-numbers"> 3 </span> ===================================== -<span class="line-numbers"> 4 </span> -<span class="line-numbers"> 5 </span> ===== Files -<span class="line-numbers"> 6 </span> -- Total Files: 50 -<span class="line-numbers"> 7 </span> -- /text -- 46 -<span class="line-numbers"> 8 </span> -- /images -- 3 -<span class="line-numbers"> 9 </span> -- /styles -- 0 -<span class="line-numbers"> 10 </span> -- /layouts -- 0 -<span class="line-numbers"> 11 </span> -- /lib -- 1 -<span class="line-numbers"> 12 </span> -<span class="line-numbers"> 13 </span> ===== Macros -<span class="line-numbers"> 14 </span> -- Total Macro Instances: 2950 -<span class="line-numbers"> 15 </span> -- Total Macro Definitions: 22 -<span class="line-numbers"> 16 </span> -- Total Macro Aliases: 57 -<span class="line-numbers"> 17 </span> -- Total Used Macro Definitions: 60 -<span class="line-numbers"> 18 </span> -<span class="line-numbers"> 19 </span> ===== Snippets -<span class="line-numbers"> 20 </span> -- Total Snippets: 21 -<span class="line-numbers"> 21 </span> -- Total Used Snippets: 21 -<span class="line-numbers"> 22 </span> -- Total Unused Snippets: 0 -<span class="line-numbers"> 23 </span> -<span class="line-numbers"> 24 </span> ===== Bookmarks -<span class="line-numbers"> 25 </span> -- Total Bookmarks: 221 -<span class="line-numbers"> 26 </span> -- Total Referenced Bookmarks: 87 -<span class="line-numbers"> 27 </span> -- Total Unreferenced Bookmarks: 135 -<span class="line-numbers"> 28 </span> -<span class="line-numbers"> 29 </span> ===== Links -<span class="line-numbers"> 30 </span> -- Total Internal Links: 87 -<span class="line-numbers"> 31 </span> -- Total External Links: 97 -</pre> - <div class="navigation"><a href="/glyph/book/compiling/programmatic_usage.html">Using Glyph programmatically ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/macros.html">→ Macro Statistics</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_25.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +<div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> ===================================== +<span class="no"> 2</span> Glyph - Statistics +<span class="no"> 3</span> ===================================== +<span class="no"> 4</span> +<span class="no"> 5</span> ===== Files +<span class="no"> 6</span> -- Total Files: 50 +<span class="no"> 7</span> -- /text -- 46 +<span class="no"> 8</span> -- /images -- 3 +<span class="no"> 9</span> -- /styles -- 0 +<span class="no"><strong>10</strong></span> -- /layouts -- 0 +<span class="no">11</span> -- /lib -- 1 +<span class="no">12</span> +<span class="no">13</span> ===== Macros +<span class="no">14</span> -- Total Macro Instances: 2950 +<span class="no">15</span> -- Total Macro Definitions: 22 +<span class="no">16</span> -- Total Macro Aliases: 57 +<span class="no">17</span> -- Total Used Macro Definitions: 60 +<span class="no">18</span> +<span class="no">19</span> ===== Snippets +<span class="no"><strong>20</strong></span> -- Total Snippets: 21 +<span class="no">21</span> -- Total Used Snippets: 21 +<span class="no">22</span> -- Total Unused Snippets: 0 +<span class="no">23</span> +<span class="no">24</span> ===== Bookmarks +<span class="no">25</span> -- Total Bookmarks: 221 +<span class="no">26</span> -- Total Referenced Bookmarks: 87 +<span class="no">27</span> -- Total Unreferenced Bookmarks: 135 +<span class="no">28</span> +<span class="no">29</span> ===== Links +<span class="no"><strong>30</strong></span> -- Total Internal Links: 87 +<span class="no">31</span> -- Total External Links: 97</pre></div> +</div> + + <nav><a href="/glyph/book/compiling/programmatic_usage.html">Using Glyph programmatically ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/stats/macros.html">→ Macro Statistics</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,166 +1,150 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Macro attributes</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Macro attributes – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Macro attributes</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Macro attributes</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/macro_intro.html">Introducing Glyph Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/esc_quot.html">→ Escaping and Quoting</a></div> + <nav><a href="/glyph/book/text_editing/macro_intro.html">Introducing Glyph Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/esc_quot.html">→ Escaping and Quoting</a></nav> <p>Although a macro can take any number of parameters, they are often no more than two or three, for readibility reasons: parameters have no name, but their position within a macro is significant.</p> <p>If you have something like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> custom_image[test.png|50%|50%|Test Image] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> custom_image[test.png|50%|50%|Test Image]</pre></div> +</div> + <p>it may still be easy enough to understand what each parameter is used for, but:</p> <ul> <li>you can easily forget that the third parameter is the image width</li> <li>if you don’t want to resize the image, you still have to pass <em>empty parameters</em> to the macro, like this: <code>custom_image[test2.png|||Test Image]</code></li> </ul> <p>To avoid these situations, some macros which would normally take three or four parameters take optional attributes instead, so you can write:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> image[test.png -<span class="line-numbers"> 2 </span> @width[50%] -<span class="line-numbers"> 3 </span> @alt[Test Image] -<span class="line-numbers"> 4 </span> @height[50%] -<span class="line-numbers"> 5 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> image[test.png +<span class="no">2</span> @width[50%] +<span class="no">3</span> @alt[Test Image] +<span class="no">4</span> @height[50%] +<span class="no">5</span> ]</pre></div> +</div> + <p>More verbose, of course, but definitely more readable. In this way, if you won't want to scale an image, you can safely omit the <code>@width</code> and <code>@height</code> attributes.</p> - <div class="note"> + <aside class="note"> <span class="note-title">Note</span>Like parameters, attributes can contain other macros, too. -</div> - <div class="navigation"><a href="/glyph/book/text_editing/macro_intro.html">Introducing Glyph Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/esc_quot.html">→ Escaping and Quoting</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/attribute_intro.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/text_editing/macro_intro.html">Introducing Glyph Macros ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/esc_quot.html">→ Escaping and Quoting</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,98 +1,106 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Source Code</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Source Code – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> - <h2>Source Code</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/images.html">Images and Figures ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/raw_html.html">→ Textile or Markdown</a></div> + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Source Code</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/text_editing/images.html">Images and Figures ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/raw_html.html">→ Textile or Markdown</a></nav> <p>If you’re a programmer, chances are that you’re going to include some source code in your articles and books. Glyph offers two ways to format code blocks effortlessly: the <a href="/glyph/book/macros/macros_block.html#m_codeblock"><code>codeblock</code></a> macro, which simply wraps text into <code><pre></code> and <code><code></code> tags, or the <a href="/glyph/book/macros/macros_filters.html#m_highlight"><code>highlight</code></a> macro. The last one requires either <a href="http://coderay.rubychan.de/">Coderay</a> or <a href="http://ultraviolet.rubyforge.org/">Ultraviolet</a>, but it provides syntax highlighting for the most common programming languages.</p> <p>Cosider the following piece of ruby code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> def find_child(&block) -<span class="line-numbers"> 2 </span> children.each do |c| -<span class="line-numbers"> 3 </span> c.descend do |node, level| -<span class="line-numbers"> 4 </span> return node if block.call(node) -<span class="line-numbers"> 5 </span> end -<span class="line-numbers"> 6 </span> end -<span class="line-numbers"> 7 </span> nil -<span class="line-numbers"> 8 </span> end -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> def find_child(&block) +<span class="no">2</span> children.each do |c| +<span class="no">3</span> c.descend do |node, level| +<span class="no">4</span> return node if block.call(node) +<span class="no">5</span> end +<span class="no">6</span> end +<span class="no">7</span> nil +<span class="no">8</span> end</pre></div> +</div> + <p>It can be wrapped in a highlight macro, like so:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> highlight[=ruby| -<span class="line-numbers"> 2 </span> def find_child(&block) -<span class="line-numbers"> 3 </span> children.each do |c| -<span class="line-numbers"> 4 </span> c.descend do |node, level| -<span class="line-numbers"> 5 </span> return node if block.call(node) -<span class="line-numbers"> 6 </span> end -<span class="line-numbers"> 7 </span> end -<span class="line-numbers"> 8 </span> nil -<span class="line-numbers"> 9 </span> end -<span class="line-numbers"> 10 </span> =] -</pre> - <p>...to produce the following, using the ultraviolet highlighter:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="Keyword">def</span> <span class="Entity">find_child</span>(<span class="Variable"><span class="Keyword">&</span>block</span>) -<span class="line-numbers"> 2 </span> children.<span class="Entity">each</span> <span class="Keyword">do </span>|<span class="Variable">c</span>| -<span class="line-numbers"> 3 </span> c.<span class="Entity">descend</span> <span class="Keyword">do </span>|<span class="Variable">node</span>, <span class="Variable">level</span>| -<span class="line-numbers"> 4 </span> <span class="Keyword">return</span> node <span class="Keyword">if</span> block.<span class="Entity">call</span>(node) -<span class="line-numbers"> 5 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 6 </span> <span class="Keyword">end</span> -<span class="line-numbers"> 7 </span> <span class="Constant">nil</span> -<span class="line-numbers"> 8 </span> <span class="Keyword">end</span> -</pre> - <div class="box"> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> highlight[=ruby| +<span class="no"> 2</span> def find_child(&block) +<span class="no"> 3</span> children.each do |c| +<span class="no"> 4</span> c.descend do |node, level| +<span class="no"> 5</span> return node if block.call(node) +<span class="no"> 6</span> end +<span class="no"> 7</span> end +<span class="no"> 8</span> nil +<span class="no"> 9</span> end +<span class="no"><strong>10</strong></span> =]</pre></div> +</div> + + <p>...to produce the following, using the coderay highlighter:</p> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> <span class="r">def</span> <span class="fu">find_child</span>(&block) +<span class="no">2</span> children.each <span class="r">do</span> |c| +<span class="no">3</span> c.descend <span class="r">do</span> |node, level| +<span class="no">4</span> <span class="r">return</span> node <span class="r">if</span> block.call(node) +<span class="no">5</span> <span class="r">end</span> +<span class="no">6</span> <span class="r">end</span> +<span class="no">7</span> <span class="pc">nil</span> +<span class="no">8</span> <span class="r">end</span></pre></div> +</div> + + <aside class="box"> <div class="box-title">Some Remarks</div> <ul> <li>Highlighters require some configuration. For more information on relevant configuration settings, see the <a href="/glyph/book/config/filters.html#cfg_filters">filters.*</a> configuration settings.</li>@@ -100,87 +108,65 @@ <li>If you’re using the <a href="/glyph/book/macros/macros_filters.html#m_highlight"><code>highlight</code></a> macro together within the <a href="/glyph/book/macros/macros_filters.html#m_textile"><code>textile</code></a> macro, you must wrap the macro call within <code><notextile></code> tags.</li>
<li>You must always escape pipes (<code>|</code>) with the code or the highlight macro.</li> </ul> -</div> - <div class="navigation"><a href="/glyph/book/text_editing/images.html">Images and Figures ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/raw_html.html">→ Textile or Markdown</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/source_code.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/text_editing/images.html">Images and Figures ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/raw_html.html">→ Textile or Markdown</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Conditional Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Conditional Macros – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Conditional Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Conditional Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/evaluation.html">Evaluating Ruby code and Configuration Settings ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/compiling.html">→ Compiling a project</a></div> + <nav><a href="/glyph/book/text_editing/evaluation.html">Evaluating Ruby code and Configuration Settings ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/compiling.html">→ Compiling a project</a></nav> <p>Sometimes you may want text to be included in a document only if certain conditions are satisfied. For example, you may want to display a disclaimer section only if the document is a draft (see the <a href="/glyph/book/config/document.html#s_document_draft"><code>document.draft</code></a> setting), or use a particular stylesheet only if when you generate a <span class="caps">PDF</span> document.</p> <p>To do so, you can use the <a href="/glyph/book/macros/macros_core.html#m_condition"><code>condition</code></a> macro (aliased by <code>?</code>), and a set of additional macros that can be used as conditional operators i.e.:</p> <ul>@@ -69,11 +71,13 @@ <li><a href="/glyph/book/macros/macros_core.html#m_or"><code>or</code></a> macro</li>
<li><a href="/glyph/book/macros/macros_core.html#m_match"><code>match</code></a> macro</li> </ul> <p>Consider the following code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ?[$[document.draft]| -<span class="line-numbers"> 2 </span> This is a first draft of the Glyph Book] -<span class="line-numbers"> 3 </span> ?[not[$[document.draft]]| -<span class="line-numbers"> 4 </span> This is the official version of the Glyph Book] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> ?[$[document.draft]| +<span class="no">2</span> This is a first draft of the Glyph Book] +<span class="no">3</span> ?[not[$[document.draft]]| +<span class="no">4</span> This is the official version of the Glyph Book]</pre></div> +</div> + <p>In this case, if <code>document.draft</code> is set to <code>true</code>, “This is a first draft of the Glyph Book” will be displayed; if not, “This is the official version of the Glyph Book” will be displayed instead.</p> <p>The <a href="/glyph/book/macros/macros_core.html#m_condition"><code>condition</code></a> macro takes two parameters:</p> <ul>@@ -81,104 +85,84 @@ <li>the first one is the condition to evaluate</li>
<li>the second one is the text to include in the document only if the condition is satisfied.</li> </ul> <p>Note that <em>both</em> parameters can contain macros, of course, so you can write things like:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> ?[and[ -<span class="line-numbers"> 2 </span> eq[$[document.output]|pdf] -<span class="line-numbers"> 3 </span> | -<span class="line-numbers"> 4 </span> eq[$[tools.pdf_generator]|prince] -<span class="line-numbers"> 5 </span> ] -<span class="line-numbers"> 6 </span> | -<span class="line-numbers"> 7 </span> style[pagination.css]] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> ?[and[ +<span class="no">2</span> eq[$[document.output]|pdf] +<span class="no">3</span> | +<span class="no">4</span> eq[$[tools.pdf_generator]|prince] +<span class="no">5</span> ] +<span class="no">6</span> | +<span class="no">7</span> style[pagination.css]]</pre></div> +</div> + <p>In this case, the <code>pagination.css</code> stylesheet is included only when you're generating a PDF document using Prince XML.</p> - <div class="section"> -<h4 id="h_38">Results of conditional expressions</h4> + <section class="section"> +<header><h1 id="h_38">Results of conditional expressions</h1></header> <p>The <a href="/glyph/book/macros/macros_core.html#m_condition"><code>condition</code></a> macro in Glyph works in a similar way as conditionals in programming languages: if the conditional expression (supplied as first parameter) is satisfied then the second parameter is executed or displayed. But when is a conditional expression satisfied? Glyph is a simple mini-language to perform text manipulation, and has no types, it can only understand text, therefore:</p> <ul> <li>A conditional expression is satisfied if it evaluates to a non-empty string except “false”.</li> <li>A conditional expression is not satisfied if it evaluates to an empty string or the string “false”.</li> </ul> -</div> - <div class="navigation"><a href="/glyph/book/text_editing/evaluation.html">Evaluating Ruby code and Configuration Settings ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/compiling.html">→ Compiling a project</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/cond_macros.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/text_editing/evaluation.html">Evaluating Ruby code and Configuration Settings ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/compiling/compiling.html">→ Compiling a project</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,85 +1,89 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Escaping and Quoting</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Escaping and Quoting – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Escaping and Quoting</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Escaping and Quoting</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/attribute_intro.html">Macro attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/sections.html">→ Sections and Headers</a></div> + <nav><a href="/glyph/book/text_editing/attribute_intro.html">Macro attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/sections.html">→ Sections and Headers</a></nav> <p>Glyph doesn’t require any special control characters like LaTeX, and its macro syntax is very straightforward and liberal. This however comes with a price: because square brackets are used as delimiters, you must escape any square bracket in your text with a backslash. That’s not <em>too</em> bad if you think about it, unless you’re writing programming code, in which case escaping every single square bracket can be painful.</p> <p>If a portion of your text contains an excessive amount of square brackets, you may consider using the <a href="/glyph/book/macros/macros_core.html#m_escape"><code>escape</code></a> macro (or its alias <code>.</code>) with the <code>[=</code> and <code>=]</code> delimiters. By itself, the escape macro doesn’t do anything: it just evaluates to its contents, but the special delimiters act as an escape for any square bracket within them. As a consequence, any macro within <code>[=</code> and <code>=]</code> will <em>not</em> be evaluated.</p> <p>You can use the quoting delimiters with <em>any</em> macro identifier. Obviously, using them as delimiters for things like <a href="/glyph/book/macros/macros_structure.html#m_section"><code>section</code></a> macros may not be a good idea, but they should be more or less mandatory with the <a href="/glyph/book/macros/macros_block.html#m_codeblock"><code>codeblock</code></a> macro or the <a href="/glyph/book/macros/macros_filters.html#m_highlight"><code>highlight</code></a> macro, especially when it contains square brackets or even Glyph code, like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> codeblock[= -<span class="line-numbers"> 2 </span> section[ -<span class="line-numbers"> 3 </span> @title[A section] -<span class="line-numbers"> 4 </span> @id[test] -<span class="line-numbers"> 5 </span> This is a section. -<span class="line-numbers"> 6 </span> section[ -<span class="line-numbers"> 7 </span> @title[A nested section] -<span class="line-numbers"> 8 </span> This is another section. -<span class="line-numbers"> 9 </span> ] -<span class="line-numbers"> 10 </span> ] -<span class="line-numbers"> 11 </span> =] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> codeblock[= +<span class="no"> 2</span> section[ +<span class="no"> 3</span> @title[A section] +<span class="no"> 4</span> @id[test] +<span class="no"> 5</span> This is a section. +<span class="no"> 6</span> section[ +<span class="no"> 7</span> @title[A nested section] +<span class="no"> 8</span> This is another section. +<span class="no"> 9</span> ] +<span class="no"><strong>10</strong></span> ] +<span class="no">11</span> =]</pre></div> +</div> - <div class="note"> + + <aside class="note"> <span class="note-title">Note</span>Although quoting delimiters allow you to use square brackets without escaping them, you must still escape them if you want to escape quoting delimiters themselves. -</div> +</aside> <p>Besides square brackets, there are other characters that must or can be escaped with backslashes, as shown in the following table:</p>@@ -87,125 +91,103 @@ <table><tr><th>Escape Sequence</th>
<th>Evaluates to...</th> <th>Notes</th></tr> <tr><td> -<code>[</code> +<code>\[</code> </td> <td> <code>[</code> </td> <td>Square brackets must be escaped unless used as macro delimiters or within a quoting macro.</td></tr> <tr><td> -<code>]</code> +<code>\]</code> </td> <td> <code>]</code> </td> <td>Square brackets must be escaped unless used as macro delimiters or within a quoting macro.</td></tr> <tr><td> -<code>\</code> +<code>\\</code> </td> <td> <code>\</code> </td> <td>Backslashes do not have to be escaped by default, but an escaped backslash will evaluate to itself.</td></tr> <tr><td> -<code>=</code> +<code>\=</code> </td> <td> <code>=</code> </td> <td>Equal signs do not have to be escaped by default, but an escaped equal sign will evaluate to iself.</td></tr> <tr><td> -<code>|</code> +<code>\|</code> </td> <td> <code>|</code> </td> <td>Pipes must be escaped (even within quoting macros) unless they are used to separate macro parameters.</td></tr> <tr><td> -<code></code> +<code>\.</code> </td> <td /> - <td>An escaped dot evaluates to nothing. Useful to separate macro identifiers from other characters: <br /><code>_=>[#link|This link is emphasized using Textile]_</code></td></tr></table> - <div class="navigation"><a href="/glyph/book/text_editing/attribute_intro.html">Macro attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/sections.html">→ Sections and Headers</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/esc_quot.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <td>An escaped dot evaluates to nothing. Useful to separate macro identifiers from other characters: <br /><code>_\.=>[#link|This link is emphasized using Textile]_</code></td></tr></table> + <nav><a href="/glyph/book/text_editing/attribute_intro.html">Macro attributes ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/sections.html">→ Sections and Headers</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,152 +1,132 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Evaluating Ruby code and Configuration Settings</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Evaluating Ruby code and Configuration Settings – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Evaluating Ruby code and Configuration Settings</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Evaluating Ruby code and Configuration Settings</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/inclusions.html">Including Files and Snippets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/conditionals.html">→ Conditional Macros</a></div> + <nav><a href="/glyph/book/text_editing/inclusions.html">Including Files and Snippets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/conditionals.html">→ Conditional Macros</a></nav> <p>Glyph Language is not a full-blown programming language and it is currently not Turing-complete (it does not provide loops). However, it is possible to evaluate simple ruby code snippets using the <code>ruby</code> macro (aliased to <code>%</code>), like this:</p> <ul> <li><code>%[2 + 2]</code> → 4</li> - <li><code>%[Time.now]</code> → Fri Sep 03 21:10:53 +0200 2010</li> - <li><code>%[Glyph::VERSION]</code> → 0.4.0</li> + <li><code>%[Time.now]</code> → Thu Sep 23 13:33:57 +0200 2010</li> + <li><code>%[Glyph::VERSION]</code> → 0.4.1</li> </ul> <p>The scope for the code evaluation is the Kernel module, (with all inclusions required by Glyph itself).</p> <p>Although it is possible to retrieve Glyph configuration settings in this way (e.g. <code>%[cfg('document.author')]</code>), the <a href="/glyph/book/macros/macros_core.html#m_config"><code>config</code></a> macro (aliased to <code>$</code>) makes things slightly simpler (e.g. <code>$[document.author]</code>).</p> - <div class="navigation"><a href="/glyph/book/text_editing/inclusions.html">Including Files and Snippets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/conditionals.html">→ Conditional Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_20.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/text_editing/inclusions.html">Including Files and Snippets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/conditionals.html">→ Conditional Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,146 +1,126 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - .glyph files</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>.glyph files – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>.glyph files</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>.glyph files</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/getting_started/configuration.html">Project Configuration ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/macro_intro.html">→ Introducing Glyph Macros</a></div> + <nav><a href="/glyph/book/getting_started/configuration.html">Project Configuration ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/macro_intro.html">→ Introducing Glyph Macros</a></nav> <p>The <code>text</code> folder of any Glyph folder contains all the text source files used to produce a document. Although there are no restrictions on the extension of the files in this folder, you may want to use <code>.glyph</code>, especially if <a href="http://www.vim.org">Vim</a> is your favorite text editor.<br /> The reason is simple: a Glyph syntax file is <a href="http://www.vim.org/scripts/script.php?script_id=3086">available on vim.org</a>. Although not essential, syntax highlighting does help when editing Glyph files.</p> - <div class="navigation"><a href="/glyph/book/getting_started/configuration.html">Project Configuration ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/macro_intro.html">→ Introducing Glyph Macros</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_6.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/getting_started/configuration.html">Project Configuration ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/macro_intro.html">→ Introducing Glyph Macros</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,171 +1,155 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Images and Figures</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Images and Figures – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Images and Figures</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Images and Figures</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/links.html">Links and Bookmarks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/code.html">→ Source Code</a></div> + <nav><a href="/glyph/book/text_editing/links.html">Links and Bookmarks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/code.html">→ Source Code</a></nav> <p>Same as for <a href="/glyph/book/text_editing/links.html#links">links</a>, you can also include images and figures using Textile or Markdown. If you want additional features, you can use the <a href="/glyph/book/macros/macros_block.html#m_image"><code>image</code></a> macro and the <a href="/glyph/book/macros/macros_block.html#m_figure"><code>figure</code></a> macro, as shown in the following example:</p> - <div class="box"> + <aside class="box"> <div class="box-title">Example</div> <p>The following Glyph code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> image[glyph.svg -<span class="line-numbers"> 2 </span> @with[20%] -<span class="line-numbers"> 3 </span> @height[20%] -<span class="line-numbers"> 4 </span> ] -<span class="line-numbers"> 5 </span> figure[example.png|An example figure. -<span class="line-numbers"> 6 </span> @alt[Example Figure] -<span class="line-numbers"> 7 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> image[glyph.svg +<span class="no">2</span> @with[20%] +<span class="no">3</span> @height[20%] +<span class="no">4</span> ] +<span class="no">5</span> figure[example.png|An example figure. +<span class="no">6</span> @alt[Example Figure] +<span class="no">7</span> ]</pre></div> +</div> + <p>Is translated into the following HTML code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">img</span> <span class="MetaTag">src</span>=<span class="String"><span class="String">"</span>images/glyph.svg<span class="String">"</span></span> <span class="MetaTag">width</span>=<span class="String"><span class="String">"</span>20%<span class="String">"</span></span> <span class="MetaTag">height</span>=<span class="String"><span class="String">"</span>20%<span class="String">"</span></span> /<span class="MetaTag">></span></span> -<span class="line-numbers"> 2 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>figure<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">img</span> <span class="MetaTag">src</span>=<span class="String"><span class="String">"</span>images/example.png<span class="String">"</span></span> <span class="MetaTag">alt</span>=<span class="String"><span class="String">"</span>Example Figure<span class="String">"</span></span>/<span class="MetaTag">></span></span> -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>caption<span class="String">"</span></span><span class="MetaTag">></span></span>An example figure.<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 5 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> <span class="ta"><img</span> <span class="an">src</span>=<span class="s"><span class="dl">"</span><span class="k">images/glyph.svg</span><span class="dl">"</span></span> <span class="an">width</span>=<span class="s"><span class="dl">"</span><span class="k">20%</span><span class="dl">"</span></span> <span class="an">height</span>=<span class="s"><span class="dl">"</span><span class="k">20%</span><span class="dl">"</span></span> <span class="ta">/></span> +<span class="no">2</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">figure</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no">3</span> <span class="ta"><img</span> <span class="an">src</span>=<span class="s"><span class="dl">"</span><span class="k">images/example.png</span><span class="dl">"</span></span> <span class="an">alt</span>=<span class="s"><span class="dl">"</span><span class="k">Example Figure</span><span class="dl">"</span></span><span class="ta">/></span> +<span class="no">4</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">caption</span><span class="dl">"</span></span><span class="ta">></span>An example figure.<span class="ta"></div></span> +<span class="no">5</span> <span class="ta"></div></span></pre></div> +</div> + <p>Any attribute passed to the <a href="/glyph/book/macros/macros_block.html#m_image"><code>image</code></a> macro or the <a href="/glyph/book/macros/macros_block.html#m_figure"><code>figure</code></a> macro is automatically passed to the underlying <code><img></code> tag.</p> -</div> - <div class="note"> +</aside> + <aside class="note"> <span class="note-title">Note</span>In future releases, figures will be numbered automatically and included in a <em>List of Figures</em> section. -</div> - <div class="navigation"><a href="/glyph/book/text_editing/links.html">Links and Bookmarks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/code.html">→ Source Code</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/img_fig.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/text_editing/links.html">Links and Bookmarks ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/code.html">→ Source Code</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Including Files and Snippets</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Including Files and Snippets – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Including Files and Snippets</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Including Files and Snippets</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/stylesheets.html">Adding Stylesheets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/evaluation.html">→ Evaluating Ruby code and Configuration Settings</a></div> + <nav><a href="/glyph/book/text_editing/stylesheets.html">Adding Stylesheets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/evaluation.html">→ Evaluating Ruby code and Configuration Settings</a></nav> <p>If you’re authoring a user manual, a long article, or a book, writing everything inside a single <code>document.glyph</code> file may not be optimal. For this reason, Glyph provides an <a href="/glyph/book/macros/macros_core.html#m_include"><code>include</code></a> macro that can be used to include the contents of any file within the <code>text/</code> directory:</p> <p><code>include[general/introduction.textile]</code></p> <p>The macro call above loads the contents of the <code>introduction.textile</code> file, within the <code>text/general</code> directory.</p>@@ -68,115 +70,95 @@ <li><code>.textile</code> or <code>.txt</code> → <a href="/glyph/book/macros/macros_filters.html#m_textile"><code>textile</code></a> macro</li>
<li><code>.markdown</code> or <code>.md</code> → <a href="/glyph/book/macros/macros_filters.html#m_markdown"><code>markdown</code></a> macro</li> </ul> <p>You can override this behavior by setting the <code>filters.by_file_extensions</code> configuration setting to <code>false</code>. If no extension is specified, <code>.glyph</code> is assumed.</p> -<div class="tip"> +<aside class="tip"> <p><span class="note-title">Tip</span>The <a href="/glyph/book/macros/macros_core.html#m_include"><code>include</code></a> macro can also be used to include (and evaluate) ruby files (with a <code>.rb</code> extension). In this case, the ruby file must be placed within the <code>lib/</code> directory of the current project.</p> -</div> +</aside> <p>While including the context of an entire file is definitely a useful feature for content reuse, sometimes it can be an overkill. What if, for example, you just want to reuse a short procedure or even a sentence or a single word? In this case, you may want to consider using a <em>snippet</em> instead.</p> <p>Snippets are text strings saved in <span class="caps">YAML</span> format in the <code>snippets.yml</code> file. They can be included anywhere in your document using the <a href="/glyph/book/macros/macros_core.html#m_snippet"><code>snippet</code></a> macro (or its alias <code>&</code>).</p> -<div class="tip"> +<aside class="tip"> <p><span class="note-title">Tip</span>Besides storing snippets in the <code>snippets.yml</code> file, you can also define them right in your document, using the <a href="/glyph/book/macros/macros_core.html#m_snippet_"><code>snippet:</code></a> macro.</p> -</div> - <div class="box"> +</aside> + <aside class="box"> <div class="box-title">Example</div> <p>Consider the following <code>snippets.yml</code> file:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="Keyword">-</span><span class="Keyword">-</span><span class="Keyword">-</span><span class="InvalidDeprecated"> </span> -<span class="line-numbers"> 2 </span> :<span class="String"><span class="Entity">glang<span class="Entity">:</span></span> <span class="String">Glyph Language</span></span> -<span class="line-numbers"> 3 </span> :<span class="String"><span class="Entity">macros<span class="Entity">:</span></span> <span class="String">Glyph Macros</span></span> -<span class="line-numbers"> 4 </span> :<span class="MetaTag"><span class="MetaTag">sq_esc</span><span class="MetaTag">:</span> </span>|<span class="Keyword">-</span> -<span class="line-numbers"> 5 </span> Square brackets must be escaped<span class="InvalidDeprecated"> </span> -<span class="line-numbers"> 6 </span> unless used as macro delimiters or within a quoting macro. -<span class="line-numbers"> 7 </span> :<span class="String"><span class="Entity">markups<span class="Entity">:</span></span> <span class="String">Textile or Markdown</span></span> -<span class="line-numbers"> 8 </span> :<span class="MetaTag"><span class="MetaTag">test</span><span class="MetaTag">:</span> </span>|<span class="Keyword">-</span> -<span class="line-numbers"> 9 </span> This is a<span class="InvalidDeprecated"> </span> -<span class="line-numbers"> 10 </span> Test snippet -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> <span class="head"><span class="head">---</span></span> +<span class="no"> 2</span> <span class="sy">:glang</span>: <span class="er">Glyph Language</span> +<span class="no"> 3</span> <span class="sy">:macros</span>: <span class="er">Glyph Macros</span> +<span class="no"> 4</span> <span class="sy">:sq_esc</span>: <span class="er">|-</span> +<span class="no"> 5</span> <span class="er">Square brackets must be escaped </span> +<span class="no"> 6</span> <span class="er">unless used as macro delimiters or within a quoting macro.</span> +<span class="no"> 7</span> <span class="sy">:markups</span>: <span class="er">Textile or Markdown</span> +<span class="no"> 8</span> <span class="sy">:test</span>: <span class="er">|-</span> +<span class="no"> 9</span> <span class="er">This is a </span> +<span class="no"><strong>10</strong></span> <span class="er">Test snippet</span></pre></div> +</div> + <p>You can use <code>&[markups]</code> anywhere in your document instead of having to type "Textile or Markdown" every time. Additionally, later on you can change the value of the <code>markups</code> snippet only in the <code>snippets.yml</code> file to change it everywhere else in the document.</p> -</div> - <div class="tip"> +</aside> + <aside class="tip"> <span class="note-title">Tip</span>Snippets (or any other macro) can be nested within other snippets. Glyph takes care of checking if you nested snippets or macros mutually and warns you as necessary. -</div> - <div class="navigation"><a href="/glyph/book/text_editing/stylesheets.html">Adding Stylesheets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/evaluation.html">→ Evaluating Ruby code and Configuration Settings</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/incl.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/text_editing/stylesheets.html">Adding Stylesheets ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/evaluation.html">→ Evaluating Ruby code and Configuration Settings</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Links and Bookmarks</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Links and Bookmarks – Glyph Documentation</title> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Links and Bookmarks</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Links and Bookmarks</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/topics.html">Topics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/images.html">→ Images and Figures</a></div> + <nav><a href="/glyph/book/text_editing/topics.html">Topics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/images.html">→ Images and Figures</a></nav> <p>Lightweight markups let you create internal and external links in a very easy way, and you can still do so in Glyph. However, if you do so:</p> <ul> <li>you can’t check if they are valid</li>@@ -69,27 +71,32 @@ <ul>
<li>the <a href="/glyph/book/macros/macros_inline.html#m_link"><code>link</code></a> macro (aliased to <code>=></code>) — to create internal and external links.</li> <li>the <a href="/glyph/book/macros/macros_inline.html#m_anchor"><code>anchor</code></a> macro (aliased to <code>#</code>) — to create named anchors (bookmarks) within your document.</li> </ul> - <div class="box"> + <aside class="box"> <div class="box-title">Example</div> <p>The following Glyph code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> This is a link to link[#test]. -<span class="line-numbers"> 2 </span> ... -<span class="line-numbers"> 3 </span> This is link[#wrong]. -<span class="line-numbers"> 4 </span> This is a #[test|test anchor]. -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> This is a link to link[#test]. +<span class="no">2</span> ... +<span class="no">3</span> This is link[#wrong]. +<span class="no">4</span> This is a #[test|test anchor].</pre></div> +</div> + <p>Is translated into the following HTML code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>This is a link to <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">a</span> <span class="MetaTag">href</span>=<span class="String"><span class="String">"</span>#test<span class="String">"</span></span><span class="MetaTag">></span></span>test anchor<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">a</span><span class="MetaTag">></span></span>.<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 2 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>...<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>This is <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">a</span> <span class="MetaTag">href</span>=<span class="String"><span class="String">"</span>#wrong<span class="String">"</span></span><span class="MetaTag">></span></span>#wrong<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">a</span><span class="MetaTag">></span></span>.<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>This is a <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">a</span> <span class="MetaTag"><span class="MetaTag">id</span><span class="MetaTag">=</span><span class="String"><span class="String">"</span><span class="String">test</span><span class="String">"</span></span></span><span class="MetaTag">></span></span>test anchor<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">a</span><span class="MetaTag">></span></span>.<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> <span class="ta"><p></span>This is a link to <span class="ta"><a</span> <span class="an">href</span>=<span class="s"><span class="dl">"</span><span class="k">#test</span><span class="dl">"</span></span><span class="ta">></span>test anchor<span class="ta"></a></span>.<span class="ta"></p></span> +<span class="no">2</span> <span class="ta"><p></span>...<span class="ta"></p></span> +<span class="no">3</span> <span class="ta"><p></span>This is <span class="ta"><a</span> <span class="an">href</span>=<span class="s"><span class="dl">"</span><span class="k">#wrong</span><span class="dl">"</span></span><span class="ta">></span>#wrong<span class="ta"></a></span>.<span class="ta"></p></span> +<span class="no">4</span> <span class="ta"><p></span>This is a <span class="ta"><a</span> <span class="an">id</span>=<span class="s"><span class="dl">"</span><span class="k">test</span><span class="dl">"</span></span><span class="ta">></span>test anchor<span class="ta"></a></span>.<span class="ta"></p></span></pre></div> +</div> + <p>Additionally, the following warning message is displayed when <a href="/glyph/book/compiling/compiling.html#compile">compiling</a>:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> warning: Bookmark 'wrong' does not exist -<span class="line-numbers"> 2 </span> -> source: @: authoring.textile -<span class="line-numbers"> 3 </span> -> path: document/body/bodymatter/chapter/@/textile/section/section/box/link -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> warning: Bookmark 'wrong' does not exist +<span class="no">2</span> -<span class="er">></span> source: @: authoring.textile +<span class="no">3</span> -<span class="er">></span> path: document/body/bodymatter/chapter/@/textile/section/section/box/link</pre></div> +</div> -</div> +</aside> <p>Basically, if you use the <a href="/glyph/book/macros/macros_inline.html#m_link"><code>link</code></a> macro and the <a href="/glyph/book/macros/macros_inline.html#m_anchor"><code>anchor</code></a> macro, Glyph makes sure that:</p> <ul> <li>all links point to valid anchors within the document (regardless if the anchors are before or after the link, in snippets or included files).</li>@@ -97,97 +104,77 @@ <li>there are no duplicate anchors within the documents.</li>
<li>if no title is specified as second parameter for the <a href="/glyph/book/macros/macros_inline.html#m_link"><code>link</code></a> macro, the anchor’s name is used as such.</li> </ul> <p>Besides using the <a href="/glyph/book/macros/macros_inline.html#m_anchor"><code>anchor</code></a> macro, you can also create an anchor for a header by passing an <code>@id</code> attribute the the <a href="/glyph/book/macros/macros_structure.html#m_section"><code>section</code></a> macro, like this:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> section[ -<span class="line-numbers"> 2 </span> @title[My Section] -<span class="line-numbers"> 3 </span> @id[my_section] -<span class="line-numbers"> 4 </span> ... -<span class="line-numbers"> 5 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> section[ +<span class="no">2</span> @title[My Section] +<span class="no">3</span> @id[my_section] +<span class="no">4</span> ... +<span class="no">5</span> ]</pre></div> +</div> + <p>By default, validation is only enabled for internal links (i.e. the check occurs if the first parameter of the <a href="/glyph/book/macros/macros_inline.html#m_link"><code>link</code></a> macro starts with a <code>#</code>). You can enable it for external links as well by setting the <a href="/glyph/book/config/options.html#s_options_url_validation"><code>options.url_validation</code></a> setting to <code>true</code>. If URL validation is enabled, an error is returned if a link returns an HTTP status greater than 302.</p> - <div class="important"> + <aside class="important"> <span class="note-title">Important</span>Enabling URL validation may significantly slow down compilation if a lot of external links are present. -</div> - <div class="navigation"><a href="/glyph/book/text_editing/topics.html">Topics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/images.html">→ Images and Figures</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/links.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/text_editing/topics.html">Topics ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/images.html">→ Images and Figures</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,70 +1,72 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Introducing Glyph Macros</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Introducing Glyph Macros – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + - <h2>Introducing Glyph Macros</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/glyph_files.html">.glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/attribute_intro.html">→ Macro attributes</a></div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Introducing Glyph Macros</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/text_editing/glyph_files.html">.glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/attribute_intro.html">→ Macro attributes</a></nav> <p>The most important concept to grasp about Glyph is the concept of <em>macro</em>.</p> <p>A Glyph macro is, in a nutshell, an identifier of some kind that wraps a value or parameters within square brackets. More specifically:</p> <ul> <li>The macro identifier can contain <em>any</em> character except for: <code>[</code>, <code>]</code>, <code>\</code>, <code>|</code>, <code>@</code> or spaces.</li> - <li>The delimiters can be either <code>[</code> and <code>]</code> or <code>[=</code> and <code>=]</code> (<span class="fmi">for more information on differences between delimiters, see <a href="/glyph/book/text_editing/esc_quot.html#esc_quot">Escaping and Quoting</a></span>).</li> + <li>The delimiters can be either <code>[</code> and <code>]</code> or <code>[=</code> and <code>=]</code> (<span class="fmi">for more information on <mark>differences between delimiters</mark>, see <a href="/glyph/book/text_editing/esc_quot.html#esc_quot">Escaping and Quoting</a></span>).</li> <li>The value can be anything, even other macros. If a macro supports more than one parameter, they must be separated with <code>|</code>. For example, the <a href="/glyph/book/macros/macros_inline.html#m_link"><code>link</code></a> macro can take an optional second parameter for the link text: <code>link[#link_id|This is the link text]</code>.</li> <li>A macro can also have <em>attributes</em>, which look exactly like macros but their identifier starts with a <code>@</code>.</li> </ul>@@ -73,86 +75,64 @@ <ul>
<li><code>=>[#test|Test Section]</code></li> <li><code>link[#test|Test Section]</code></li> </ul> - <div class="navigation"><a href="/glyph/book/text_editing/glyph_files.html">.glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/attribute_intro.html">→ Macro attributes</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/macro_intro.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/text_editing/glyph_files.html">.glyph files ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/attribute_intro.html">→ Macro attributes</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,172 +1,155 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Textile or Markdown</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Textile or Markdown – Glyph Documentation</title> + + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <h2>Textile or Markdown</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/code.html">Source Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/xml_fallback.html">→ XML Fallback</a></div> + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Textile or Markdown</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/text_editing/code.html">Source Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/xml_fallback.html">→ XML Fallback</a></nav> <p>Textile or Markdown are very easy and intuitive to use, and they can produce HTML markup with almost no effort. Using them with Glyph is as simple as using the <a href="/glyph/book/macros/macros_filters.html#m_textile"><code>textile</code></a> macro (aliased to <code>txt</code>) and the <a href="/glyph/book/macros/macros_filters.html#m_markdown"><code>markdown</code></a> macro (aliased to <code>md</code>).</p> - <div class="box"> + <aside class="box"> <div class="box-title">Example</div> <p>The following Glyph code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> textile[ -<span class="line-numbers"> 2 </span> This is a paragraph with some _emphasized_ text. -<span class="line-numbers"> 3 </span> -<span class="line-numbers"> 4 </span> This is another paragraph with some -deleted- text. -<span class="line-numbers"> 5 </span> * This is -<span class="line-numbers"> 6 </span> * a bulletted -<span class="line-numbers"> 7 </span> * list -<span class="line-numbers"> 8 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> textile[ +<span class="no">2</span> This is a paragraph with some _emphasized_ text. +<span class="no">3</span> +<span class="no">4</span> This is another paragraph with some -deleted- text. +<span class="no">5</span> * This is +<span class="no">6</span> * a bulletted +<span class="no">7</span> * list +<span class="no">8</span> ]</pre></div> +</div> + <p>produces the following HTML code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>This is a paragraph with some <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">em</span><span class="MetaTag">></span></span>emphasized<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">em</span><span class="MetaTag">></span></span> text.<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 2 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>This is a paragraph with some <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">del</span><span class="MetaTag">></span></span>deleted<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">del</span><span class="MetaTag">></span></span> text.<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">ul</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">li</span><span class="MetaTag">></span></span>This is<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">li</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 5 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">li</span><span class="MetaTag">></span></span>a bulletted<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">li</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 6 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">li</span><span class="MetaTag">></span></span>list<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">li</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 7 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">ul</span><span class="MetaTag">></span></span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> <span class="ta"><p></span>This is a paragraph with some <span class="ta"><em></span>emphasized<span class="ta"></em></span> text.<span class="ta"></p></span> +<span class="no">2</span> <span class="ta"><p></span>This is a paragraph with some <span class="ta"><del></span>deleted<span class="ta"></del></span> text.<span class="ta"></p></span> +<span class="no">3</span> <span class="ta"><ul></span> +<span class="no">4</span> <span class="ta"><li></span>This is<span class="ta"></li></span> +<span class="no">5</span> <span class="ta"><li></span>a bulletted<span class="ta"></li></span> +<span class="no">6</span> <span class="ta"><li></span>list<span class="ta"></li></span> +<span class="no">7</span> <span class="ta"></ul></span></pre></div> +</div> -</div> - <div class="important"> +</aside> + <aside class="important"> <span class="note-title">Important</span>Be careful when using block-level HTML with Textile and Markdown: sometimes it may be necessary to add extra empty lines or escape tags. -</div> - <div class="navigation"><a href="/glyph/book/text_editing/code.html">Source Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/xml_fallback.html">→ XML Fallback</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_16.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/text_editing/code.html">Source Code ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/xml_fallback.html">→ XML Fallback</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Section Aliases</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Section Aliases – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Section Aliases</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Section Aliases</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/sections.html">Sections and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/topics.html">→ Topics</a></div> + <nav><a href="/glyph/book/text_editing/sections.html">Sections and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/topics.html">→ Topics</a></nav> <p>There are <em>a lot</em> of macros that can be used in the same way as <code>section</code>, one for each element commonly used in <a href="http://en.wikipedia.org/wiki/Book_design">book design</a>. Each one of them is a simple wrapper for a <code><div></code> tag with a <code>class</code> attribute set to its name.</p> <p>The following table lists the identifiers of all section-like macros, divided according to the part of the book they should be placed in:</p> <table><tr><th>Frontmatter</th>@@ -81,90 +83,68 @@ <p>
<strong>‡</strong>: Any subsection of this section is not listed in the Table of Contents. </p> - <div class="note"> + <aside class="note"> <span class="note-title">Note</span><code>frontmatter</code>, <code>bodymatter</code> and <code>backmatter</code> are also macro identifiers, but they are exposed as attributes for the <a href="/glyph/book/macros/macros_structure.html#m_book"><code>book</code></a> macro and the <a href="/glyph/book/macros/macros_structure.html#m_article"><code>article</code></a> macro, so if you're using either of these two macros as your root macro for your document, there's no need to use them explicitly. -</div> - <div class="navigation"><a href="/glyph/book/text_editing/sections.html">Sections and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/topics.html">→ Topics</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_11.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</aside> + <nav><a href="/glyph/book/text_editing/sections.html">Sections and Headers ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/topics.html">→ Topics</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,171 +1,155 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Sections and Headers</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Sections and Headers – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Sections and Headers</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Sections and Headers</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/esc_quot.html">Escaping and Quoting ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/section_aliases.html">→ Section Aliases</a></div> + <nav><a href="/glyph/book/text_editing/esc_quot.html">Escaping and Quoting ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/section_aliases.html">→ Section Aliases</a></nav> <p>Glyph documents are normally organized as a hierarchical tree of nested chapters, appendixes, sections, etc. To define a section, use the <a href="/glyph/book/macros/macros_structure.html#m_section"><code>section</code></a> macro, like so:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> section[ -<span class="line-numbers"> 2 </span> @title[Section #1] -<span class="line-numbers"> 3 </span> Write the section contents here... -<span class="line-numbers"> 4 </span> section[ -<span class="line-numbers"> 5 </span> @title[Section #2] -<span class="line-numbers"> 6 </span> This section is nested into the previous one. -<span class="line-numbers"> 7 </span> ] --[End of Section #2] -<span class="line-numbers"> 8 </span> ] --[End of Section #1] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> section[ +<span class="no">2</span> @title[Section #1] +<span class="no">3</span> Write the section contents here... +<span class="no">4</span> section[ +<span class="no">5</span> @title[Section #2] +<span class="no">6</span> This section is nested into the previous one. +<span class="no">7</span> ] --[End of Section #2] +<span class="no">8</span> ] --[End of Section #1]</pre></div> +</div> + <p>This example defines two nested sections. If the <code>@title</code> attribute is specified like in this case, it will be converted to a proper <span class="caps">HTML</span> header and it will appear in the Table of Contents (see the <a href="/glyph/book/macros/macros_structure.html#m_toc"><code>toc</code></a> macro).</p> <p>Note an important difference from <span class="caps">HTML</span>: there is no need for an explicit level for the headers, as it will be determined at runtime when the document is compiled, based on how sections are nested. The previous code snippet (taken as it is), for example, will be transformed into the following <span class="caps">HTML</span> code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>section<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 2 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">h2</span><span class="MetaTag">></span></span>Section #1<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">h2</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>Write the section contents here...<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">div</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>section<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 5 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">h3</span><span class="MetaTag">></span></span>Section #2<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">h3</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 6 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>This section is nested in the previous one<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 7 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 8 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">div</span><span class="MetaTag">></span></span> -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">section</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no">2</span> <span class="ta"><h2></span>Section #1<span class="ta"></h2></span> +<span class="no">3</span> <span class="ta"><p></span>Write the section contents here...<span class="ta"></p></span> +<span class="no">4</span> <span class="ta"><div</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">section</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no">5</span> <span class="ta"><h3></span>Section #2<span class="ta"></h3></span> +<span class="no">6</span> <span class="ta"><p></span>This section is nested in the previous one<span class="ta"></p></span> +<span class="no">7</span> <span class="ta"></div></span> +<span class="no">8</span> <span class="ta"></div></span></pre></div> +</div> + <p>By default, in Glyph the first header level is <em>2</em>, so the two headers are rendered as <code>h2</code> and <code>h3</code>, respectively (<code>--[...]</code> macros are <em>comments</em>, therefore they are not included in the final output).</p> - <div class="navigation"><a href="/glyph/book/text_editing/esc_quot.html">Escaping and Quoting ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/section_aliases.html">→ Section Aliases</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/sec_head.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/text_editing/esc_quot.html">Escaping and Quoting ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/section_aliases.html">→ Section Aliases</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,76 +1,78 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Adding Stylesheets</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Adding Stylesheets – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Adding Stylesheets</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Adding Stylesheets</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/xml_fallback.html">XML Fallback ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/inclusions.html">→ Including Files and Snippets</a></div> + <nav><a href="/glyph/book/text_editing/xml_fallback.html">XML Fallback ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/inclusions.html">→ Including Files and Snippets</a></nav> <p>Currently, Glyph does not provide any native way to format text and pages. The reason is that there's absolutely no need for that: CSS does the job just fine. In particular, CSS3 offers specific attributes and elements that can be used specifically for paginated documents. That's no replacement for LaTeX by any means, but it is enough if you're not looking for advanced typographical features.</p> <p>You can embed CSS files using the <a href="/glyph/book/macros/macros_structure.html#m_style"><code>style</code></a> macro, like this:</p> <p> <code>style[default.css]</code> </p> - <p>In this case, the <a href="/glyph/book/macros/macros_structure.html#m_style"><code>style</code></a> macro looks for a <code>default.css</code> file in the <code>/styles</code> folder of your Glyph project <em>and</em> among the default Glyph stylesheets, and embeds it within a <code><style></code> tag. If you supply a file with a <code>.sass</code> extension, it will interpret it as a Sass file and convert it to <span class="caps">CSS</span> automatically (if the <em>Haml</em> gem is installed).</p> - <div class="tip"> + <p>In this case, the <a href="/glyph/book/macros/macros_structure.html#m_style"><code>style</code></a> macro looks for a <code>default.css</code> file in the <code>/styles</code> folder of your Glyph project <em>and</em> among the default Glyph stylesheets, and embeds it within a <code><style></code> tag. If you supply a file with a <code>.sass</code> or <code>.scss</code> extension, it will interpret it as a Sass file and convert it to <span class="caps">CSS</span> automatically (if the <em>Haml</em> gem is installed).</p> + <aside class="tip"> <span class="note-title">Tip</span>By default, stylesheets are embedded within text files. If necessary, you can choose to link them or import them by changing the values of the <a href="/glyph/book/config/document.html#s_document_styles"><code>document.styles</code></a> setting. -</div> - <div class="section"> -<h4 id="default_stylesheets">Default Stylesheets</h4> +</aside> + <section class="section"> +<header><h1 id="default_stylesheets">Default Stylesheets</h1></header> <p>Glyph provides the following default stylesheets, that can be referenced directly using the <a href="/glyph/book/macros/macros_structure.html#m_style"><code>style</code></a> macro:</p> <table><tr><th>File name</th> <th>Notes</th></tr>@@ -91,87 +93,65 @@ <code>ultraviolet/*</code>
</td> <td>This folder contains the following <a href="http://ultraviolet.rubyforge.org/">Ultraviolet</a> stylesheets, used for syntax highlighting: <code>active4d.css, all_hallows_eve.css, amy.css, blackboard.css, brilliance_black.css, brilliance_dull.css, cobalt.css, dawn.css, eiffel.css, espresso_libre.css, idle.css, iplastic.css, lazy.css, mac_classic.css, magicwb_amiga.css, pastels_on_dark.css, slush_poppies.css, spacecadet.css, sunburst.css, twilight.css, zenburnesque.css</code></td></tr></table> -</div> - <div class="navigation"><a href="/glyph/book/text_editing/xml_fallback.html">XML Fallback ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/inclusions.html">→ Including Files and Snippets</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/stylesheets.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/text_editing/xml_fallback.html">XML Fallback ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/inclusions.html">→ Including Files and Snippets</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Topics</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Topics – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Topics</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Topics</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/section_aliases.html">Section Aliases ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/links.html">→ Links and Bookmarks</a></div> + <nav><a href="/glyph/book/text_editing/section_aliases.html">Section Aliases ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/links.html">→ Links and Bookmarks</a></nav> <p>Sections can also be used to create <em>topics</em>. In a technical writing context, the term topic identifies a single page of an online help (e.g. a Compiled <span class="caps">HTML</span> file, or <span class="caps">CHM</span>). Topics should generally be:</p> <ul> <li>self-contained, in the sense that they should make sense on their own, ideally without the need to be read in sequence</li>@@ -66,19 +68,23 @@ <li>be used for either <em>concepts</em>, <em>tasks</em> or <em>references</em></li>
<li>be divided into meaningful sections like <em>Introduction</em>, <em>Procedure</em>, <em>Result</em></li> </ul> <p>Glyph does not formally enforce the correctness of topic composition and usage, but it does enable authors to create them as a sort of external sections. Consider the following Glyph code:</p> -<pre class="lazy"><span class="line-numbers"> 1 </span> section[ -<span class="line-numbers"> 2 </span> @title[My First Topic] -<span class="line-numbers"> 3 </span> @id[first_topic] -<span class="line-numbers"> 4 </span> @src[test/first_topic.glyph] -<span class="line-numbers"> 5 </span> ] -</pre> +<div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> section[ +<span class="no">2</span> @title[My First Topic] +<span class="no">3</span> @id[first_topic] +<span class="no">4</span> @src[test/first_topic.glyph] +<span class="no">5</span> ]</pre></div> +</div> + <p>This is an ordinary section with a title and an explicit ID, but it has no contents. Instead, its <code>@src</code> attribute references an external file. If you are generating a single-file document, like a standalone <span class="caps">HTML</span> file or a <span class="caps">PDF</span> file, the code snippet above is exactly the same as the following:</p> -<pre class="lazy"><span class="line-numbers"> 1 </span> section[ -<span class="line-numbers"> 2 </span> @title[My First Topic] -<span class="line-numbers"> 3 </span> @id[first_topic] -<span class="line-numbers"> 4 </span> include[test/first_topic.glyph] -<span class="line-numbers"> 5 </span> ] -</pre> +<div class="CodeRay"> + <div class="code"><pre><span class="no">1</span> section[ +<span class="no">2</span> @title[My First Topic] +<span class="no">3</span> @id[first_topic] +<span class="no">4</span> include[test/first_topic.glyph] +<span class="no">5</span> ]</pre></div> +</div> + <p>On the other hand, if you are planning on producing a document comprised of multiple files (see <a href="/glyph/book/compiling/compiling.html#web_output">Web/Web5 Output</a>), the <code>@src</code> attribute tells Glyph to create a <em>topic</em> for the section. In this case:</p> <ul> <li>The <code>@title</code> attribute must be specified and is used as the topic title</li>@@ -87,86 +93,64 @@ <li>The topic file is rendered according to a specific <a href="/glyph/book/extending/layouts.html#layouts">layout</a>.</li>
<li>The location of the topic is the same as the location of the included file, mirrored in the output folder.</li> <li>Glyph takes care of changing the file extensions and resolving links automatically, regardless of the output target.</li> </ul> - <div class="navigation"><a href="/glyph/book/text_editing/section_aliases.html">Section Aliases ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/links.html">→ Links and Bookmarks</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/topics.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/text_editing/section_aliases.html">Section Aliases ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/links.html">→ Links and Bookmarks</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,131 +1,136 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - XML Fallback</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>XML Fallback – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>XML Fallback</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/text_editing/raw_html.html">Textile or Markdown ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/stylesheets.html">→ Adding Stylesheets</a></div> + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>XML Fallback</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/text_editing/raw_html.html">Textile or Markdown ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/stylesheets.html">→ Adding Stylesheets</a></nav> <p>Sure Textile and Markdown are great, but sometimes you may want to just use HTML, without the extra verbosity, of course. Take tables for example: Textile offers an easy way to create them, but things may get dirty when you need to have multiple paragraphs or lists within cells.</p> <p>Very early versions of Glyph used to offered some simple <code>table</code>, <code>tr</code>, <code>tr</code>, <code>td</code> macros just for that. Of course the problem was that thy didn't offer any way to customize the markup by adding, for example, CSS classes.</p> <p>Instead, by default, Glyph can convert any unrecognized macro to the corresponding XML element and macro attributes to XML attributes.</p> - <div class="box"> + <aside class="box"> <div class="box-title">Example</div> <p>The following Glyph code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> table[@class[features] -<span class="line-numbers"> 2 </span> tr[ -<span class="line-numbers"> 3 </span> th[ID] -<span class="line-numbers"> 4 </span> th[Priority] -<span class="line-numbers"> 5 </span> th[Description] -<span class="line-numbers"> 6 </span> ] -<span class="line-numbers"> 7 </span> tr[ -<span class="line-numbers"> 8 </span> td[27] -<span class="line-numbers"> 9 </span> td[span[@style[color:red;font-weight:bold;] HIGH]] -<span class="line-numbers"> 10 </span> td[HTML output] -<span class="line-numbers"> 11 </span> ] -<span class="line-numbers"> 12 </span> tr[ -<span class="line-numbers"> 13 </span> td[42] -<span class="line-numbers"> 14 </span> td[span[@style[color:green;font-weight:bols;] LOW]] -<span class="line-numbers"> 15 </span> td[ -<span class="line-numbers"> 16 </span> p[Support for less-used tags:] -<span class="line-numbers"> 17 </span> ul[ -<span class="line-numbers"> 18 </span> li[cite] -<span class="line-numbers"> 19 </span> li[sup] -<span class="line-numbers"> 20 </span> li[...] -<span class="line-numbers"> 21 </span> ] -<span class="line-numbers"> 22 </span> ] -<span class="line-numbers"> 23 </span> ] -<span class="line-numbers"> 24 </span> ] -</pre> + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> table[@class[features] +<span class="no"> 2</span> tr[ +<span class="no"> 3</span> th[ID] +<span class="no"> 4</span> th[Priority] +<span class="no"> 5</span> th[Description] +<span class="no"> 6</span> ] +<span class="no"> 7</span> tr[ +<span class="no"> 8</span> td[27] +<span class="no"> 9</span> td[span[@style[color:red;font-weight:bold;] HIGH]] +<span class="no"><strong>10</strong></span> td[HTML output] +<span class="no">11</span> ] +<span class="no">12</span> tr[ +<span class="no">13</span> td[42] +<span class="no">14</span> td[span[@style[color:green;font-weight:bols;] LOW]] +<span class="no">15</span> td[ +<span class="no">16</span> p[Support for less-used tags:] +<span class="no">17</span> ul[ +<span class="no">18</span> li[cite] +<span class="no">19</span> li[sup] +<span class="no"><strong>20</strong></span> li[...] +<span class="no">21</span> ] +<span class="no">22</span> ] +<span class="no">23</span> ] +<span class="no">24</span> ]</pre></div> +</div> + <p>Is translated into the following HTML code:</p> - <pre class="lazy"><span class="line-numbers"> 1 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">table</span> <span class="MetaTag">class</span>=<span class="String"><span class="String">"</span>features<span class="String">"</span></span><span class="MetaTag">></span></span> -<span class="line-numbers"> 2 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">tr</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 3 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">th</span><span class="MetaTag">></span></span>ID<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">th</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 4 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">th</span><span class="MetaTag">></span></span>Priority<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">th</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 5 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">th</span><span class="MetaTag">></span></span>Description<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">th</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 6 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">tr</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 7 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">tr</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 8 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">td</span><span class="MetaTag">></span></span>27<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">td</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 9 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">td</span><span class="MetaTag">></span></span><span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">span</span> <span class="MetaTag">style</span>=<span class="String"><span class="String">"</span>color:red;font-weight:bold;<span class="String">"</span></span><span class="MetaTag">></span></span>HIGH<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">span</span><span class="MetaTag">></span></span><span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">td</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 10 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">td</span><span class="MetaTag">></span></span>HTML output<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">td</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 11 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">tr</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 12 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">tr</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 13 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">td</span><span class="MetaTag">></span></span>42<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">td</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 14 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">td</span><span class="MetaTag">></span></span><span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">span</span> <span class="MetaTag">style</span>=<span class="String"><span class="String">"</span>color:green;font-weight:bold;<span class="String">"</span></span><span class="MetaTag">></span></span>LOW<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">span</span><span class="MetaTag">></span></span><span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">td</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 15 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">td</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 16 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">p</span><span class="MetaTag">></span></span>Support for less-used tags:<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">p</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 17 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">ul</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 18 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">li</span><span class="MetaTag">></span></span>cite<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">li</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 19 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">li</span><span class="MetaTag">></span></span>sup<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">li</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 20 </span> <span class="MetaTag"><span class="MetaTag"><</span><span class="MetaTag">li</span><span class="MetaTag">></span></span>...<span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">li</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 21 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">ul</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 22 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">td</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 23 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">tr</span><span class="MetaTag">></span></span> -<span class="line-numbers"> 24 </span> <span class="MetaTag"><span class="MetaTag"></</span><span class="MetaTag">table</span><span class="MetaTag">></span></span> -</pre> - + <div class="CodeRay"> + <div class="code"><pre><span class="no"> 1</span> <span class="ta"><table</span> <span class="an">class</span>=<span class="s"><span class="dl">"</span><span class="k">features</span><span class="dl">"</span></span><span class="ta">></span> +<span class="no"> 2</span> <span class="ta"><tr></span> +<span class="no"> 3</span> <span class="ta"><th></span>ID<span class="ta"></th></span> +<span class="no"> 4</span> <span class="ta"><th></span>Priority<span class="ta"></th></span> +<span class="no"> 5</span> <span class="ta"><th></span>Description<span class="ta"></th></span> +<span class="no"> 6</span> <span class="ta"></tr></span> +<span class="no"> 7</span> <span class="ta"><tr></span> +<span class="no"> 8</span> <span class="ta"><td></span>27<span class="ta"></td></span> +<span class="no"> 9</span> <span class="ta"><td></span><span class="ta"><span</span> <span class="an">style</span>=<span class="s"><span class="dl">"</span><span class="k">color:red;font-weight:bold;</span><span class="dl">"</span></span><span class="ta">></span>HIGH<span class="ta"></span></span><span class="ta"></td></span> +<span class="no"><strong>10</strong></span> <span class="ta"><td></span>HTML output<span class="ta"></td></span> +<span class="no">11</span> <span class="ta"></tr></span> +<span class="no">12</span> <span class="ta"><tr></span> +<span class="no">13</span> <span class="ta"><td></span>42<span class="ta"></td></span> +<span class="no">14</span> <span class="ta"><td></span><span class="ta"><span</span> <span class="an">style</span>=<span class="s"><span class="dl">"</span><span class="k">color:green;font-weight:bold;</span><span class="dl">"</span></span><span class="ta">></span>LOW<span class="ta"></span></span><span class="ta"></td></span> +<span class="no">15</span> <span class="ta"><td></span> +<span class="no">16</span> <span class="ta"><p></span>Support for less-used tags:<span class="ta"></p></span> +<span class="no">17</span> <span class="ta"><ul></span> +<span class="no">18</span> <span class="ta"><li></span>cite<span class="ta"></li></span> +<span class="no">19</span> <span class="ta"><li></span>sup<span class="ta"></li></span> +<span class="no"><strong>20</strong></span> <span class="ta"><li></span>...<span class="ta"></li></span> +<span class="no">21</span> <span class="ta"></ul></span> +<span class="no">22</span> <span class="ta"></td></span> +<span class="no">23</span> <span class="ta"></tr></span> +<span class="no">24</span> <span class="ta"></table></span></pre></div> </div> + +</aside> <p>Basically, if the <a href="/glyph/book/config/options.html#s_options_xml_fallback"><code>options.xml_fallback</code></a> setting is set to <code>true</code>, any macro unknown to Glyph with at most one parameter will be converted to an XML tag with the same name and any attribute will be converted to the corresponding XML attribute.</p> - <div class="important"> + <aside class="important"> <span class="note-title">Important</span>While macro names and attributes are validated so that an error is returned if they contain illegal character, no check is performed against any particular XML schema. -</div> +</aside> <p>Additionally, it is possible to force macro-to-<span class="caps">XML</span> conversion by prepending an equal sign to any macro, so for example <code>=snippet[test]</code> will be converted into <code><snippet>test</snippet></code>.</p> - <div class="section"> -<h5 id="xml_blacklist">Blacklisted XML tags</h5> + <section class="section"> +<header><h1 id="xml_blacklist">Blacklisted XML tags</h1></header> <p>By default, the following tags are blacklisted and will be ignored:</p> <ul> <li><code>applet</code></li>@@ -143,91 +148,69 @@ <li><code>object</code></li>
<li><code>param</code></li> <li><code>title</code></li> </ul> -<div class="tip"> +<aside class="tip"> <p><span class="note-title">Tip</span>You can change this list by modifying the <a href="/glyph/book/config/options.html#s_options_xml_blacklist"><code>options.xml_blacklist</code></a> setting.</p> -</div> +</aside> -</div> - <div class="navigation"><a href="/glyph/book/text_editing/raw_html.html">Textile or Markdown ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/stylesheets.html">→ Adding Stylesheets</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_17.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); +</section> + <nav><a href="/glyph/book/text_editing/raw_html.html">Textile or Markdown ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/text_editing/stylesheets.html">→ Adding Stylesheets</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Command Errors</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Command Errors – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Command Errors</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Command Errors</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_parser.html">Parsing Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_macro.html">→ Macro Errors</a></div> + <nav><a href="/glyph/book/troubleshooting/errors_parser.html">Parsing Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_macro.html">→ Macro Errors</a></nav> <table style="width:100%;"> <tr>@@ -127,86 +129,64 @@ <td>Returned by the <a href="/glyph/book/ref_commands.html#c_config"><code>config</code></a> command when attempting to override a setting in the <code>system.*</code> namespace.</td>
</tr> </table> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_parser.html">Parsing Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_macro.html">→ Macro Errors</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_45.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/troubleshooting/errors_parser.html">Parsing Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_macro.html">→ Macro Errors</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Generic Errors</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Generic Errors – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>Generic Errors</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/extending/command.html">Defining Custom Commands ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_parser.html">→ Parsing Errors</a></div> + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Generic Errors</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/extending/command.html">Defining Custom Commands ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_parser.html">→ Parsing Errors</a></nav> <table style="width:100%;"> <tr>@@ -149,86 +151,64 @@ <td>Returned by the <a href="/glyph/book/ref_commands.html#c_stats"><code>stats</code></a> command if the specified snippet is defined but unused.</td>
</tr> </table> - <div class="navigation"><a href="/glyph/book/extending/command.html">Defining Custom Commands ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_parser.html">→ Parsing Errors</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_43.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/extending/command.html">Defining Custom Commands ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_parser.html">→ Parsing Errors</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Macro Errors</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Macro Errors – Glyph Documentation</title> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> - <h2>Macro Errors</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_command.html">Command Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/ref_commands.html">→ Command Reference</a></div> + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> + + </header> + <article class="page"> + <header> + <hgroup> + <h1>Macro Errors</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> + + <nav><a href="/glyph/book/troubleshooting/errors_command.html">Command Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/ref_commands.html">→ Command Reference</a></nav> <p>The following errors are displayed in the form:</p> <p><em>message</em><br /> source: <em>macro_source</em><br />@@ -245,86 +247,64 @@ <td>Returned if a macro was used in the wrong place.</td>
</tr> </table> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_command.html">Command Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/ref_commands.html">→ Command Reference</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_46.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/troubleshooting/errors_command.html">Command Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/ref_commands.html">→ Command Reference</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> </script> - </body> - </html>+ <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -1,64 +1,66 @@
-<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> - <head> - <title>Glyph - Parsing Errors</title> - <meta name="author" content="Fabio Cevasco" /> - <meta name="copyright" content="Fabio Cevasco" /> - <meta name="robots" content="all, follow" /> - <meta name="Revisit-After" content="2 Days" /> - <meta name="language" content="en" /> - <meta name="target_country" content="en-us" /> - <meta name="country" content="United States" /> - <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> - <meta name="keywords" content="h3rald, fabio cevasco, glyph, technical writing, html, html5, book" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> - <meta content="44.388041;9.073248" name="ICBM" /> +<!DOCTYPE html> +<html lang="en"> + <head> + <title>Parsing Errors – Glyph Documentation</title> + + + + <meta charset="utf-8" /> + <meta name="author" content="Fabio Cevasco" /> + <meta name="copyright" content="Fabio Cevasco" /> + <meta name="robots" content="all, follow" /> + <meta name="Revisit-After" content="2 Days" /> + <meta name="language" content="en" /> + <meta name="target_country" content="en-us" /> + <meta name="country" content="United States" /> + <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> + + <meta name="keywords" content="h3rald, fabio cevasco, glyph" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> + <meta content="44.388041;9.073248" name="ICBM" /> + + + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> + </head> + <body> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> + + <section id="container"> + + <header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + + <nav class="section"> + /<a href="/glyph/" rel="archives">GLYPH</a> + </nav> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> - </head> - <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <li><span class="preload nav-archives"></span><a id="nav-archives" href="/archives/" title="ARCHIVES"></a></li> - <li><span class="preload nav-projects"></span><a id="nav-projects" href="/projects/" title="PROJECTS"></a></li> - <li><span class="preload nav-about"></span><a id="nav-about" href="/about/" title="ABOUT"></a></li> - <li><span class="preload nav-other"></span><a id="nav-other" href="/other/" title="OTHER"></a></li> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfixstandard"> - <div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - </div> + </header> + <article class="page"> + <header> + <hgroup> + <h1>Parsing Errors</h1> + <h2>Glyph Documentation</h2> + </hgroup> + </header> + <section id="body-text" class="hyphenate glyph-book"> - <h2>Parsing Errors</h2> - <hr /> - <div id="content-body"> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_generic.html">Generic Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_command.html">→ Command Errors</a></div> + <nav><a href="/glyph/book/troubleshooting/errors_generic.html">Generic Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_command.html">→ Command Errors</a></nav> <table style="width:100%;"> <tr>@@ -113,86 +115,64 @@ <td>Returned if a parameter delimiter is outside a macro or inside an attribute.</td>
</tr> </table> - <div class="navigation"><a href="/glyph/book/troubleshooting/errors_generic.html">Generic Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_command.html">→ Command Errors</a></div> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- - google_ad_client = "pub-2871497824158668"; - /* 728x90, h3rald 8.0 */ - google_ad_slot = "0081634732"; - google_ad_width = 728; - google_ad_height = 90; - //--> - </script> - <script type="text/javascript" - src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> - </div> <!-- SERVICES END --> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-2010 <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=/t_44.html" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src='http://www.google-analytics.com/ga.js' type='text/javascript'></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - - - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); + <nav><a href="/glyph/book/troubleshooting/errors_generic.html">Generic Errors ←</a><a href="/glyph/book/index.html">Contents</a><a href="/glyph/book/troubleshooting/errors_command.html">→ Command Errors</a></nav> + </section> + </article> + + + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> - </body> - </html>+ </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> + </body> +</html>
@@ -3,7 +3,8 @@ permalink: h3rald
filters_pre: - erb - redcloth -title: "Project: H3RALD Web Site" +title: "H3RALD Web Site" +subtitle: "The site you're looking at" type: project github: h3rald links:
@@ -1,6 +1,7 @@
----- permalink: herald-vim-color-scheme -title: "Project: herald.vim" +title: "herald.vim" +subtitle: "An easy to read, portable and pretty Vim Color Scheme" type: project ----- *herald* is a dark color scheme for "Vim":http://www.vim.org which aims to be easy to read, eye-appealing, portable on multiple terminals, and suitable for source code highlighting in multiple languages.
@@ -11,8 +11,6 @@ Looking for a peaceful and relaxing holiday in the Italian Riviera? I'm renting part of my family country home in the center of the old village of "Sessarego":http://italia.indettaglio.it/eng/liguria/genova_bogliasco_sessarego.html, on a peaceful hill a few minutes away from Bogliasco, a small coastal town on the _Golfo Paradiso_. The center of Genoa can be reached by car, bus or train in about 30 minutes and a lot of tourist locations like Camogli, Rapallo, Santa Margherita and Portofino are just a few train stops away.
The house was build in the XVIII century, and it has been renovated in 1929 and more recently in 2006, and it now features brand new wooden windows, doors and internal stairway as well as all the most common household appliances and services. -<hr class="spacer-100"> - h3. Photos <div id="gallery">@@ -102,7 +100,7 @@ <div style="padding: 10px;"></div>
h3. Contact -If you are interested in booking your stay or if you have any question, email me at "h3rald@h3rald.com":mailto://h3rald@h3rald.com. +If you are interested in booking your stay or if you have any question, "contact us":/contact/.
@@ -0,0 +1,113 @@
+----- +permalink: home +filters_pre: +- erb +title: Home +type: page +feed: '/' +feed_url: "http://feeds.feedburner.com/h3rald" +feed_title: 'Latest Articles' +----- +<% +max_items = 5 + +all_articles = latest_articles.length +latest = latest_articles 5 +popular = popular_articles 5 +all_projects = @items.select{|a| a[:type] == 'project'}.length +%> +<section id="topbar"> + <nav id="social"> + <ul> + <li><a href="http://www.h3rald.com/rss/" rel="external"><img src="/images/social/rss.png" alt="RSS" /></a></li> + <li><a href="http://blog.h3rald.com/" rel="external"><img src="/images/social/posterous.png" alt="posterous" /></a></li> + <li><a href="http://www.twitter.com/h3rald/" rel="external"><img src="/images/social/twitter.png" alt="RSS" /></a></li> + <li><a href="http://it.linkedin.com/in/fabiocevasco" rel="external"><img src="/images/social/linkedin.png" alt="linkedin" /></a></li> + <li><a href="http://www.delicious.com/h3rald/" rel="external"><img src="/images/social/delicious.png" alt="delicious" /></a></li> + <li><a href="http://www.reddit.com/user/h3rald/" rel="external"><img src="/images/social/reddit.png" alt="reddit" /></a></li> + </ul> + </nav> + <aside id="search"> + <section id="search_form"></section> + </aside> +</section><!-- #topbar end --> +<section id="search_results"></section> +<section class="left" id="main-content"> + <%= render 'article_intro', :item => latest[0], :classes => "three-columns hyphenate", :extended => true %> + <section class="clear-left left" id="#main-content-left"> + <script src="http://widgets.twimg.com/j/2/widget.js"></script> + <section id="twitter"> + <script> + new TWTR.Widget({ + version: 2, + type: 'profile', + rpp: 4, + interval: 6000, + width: 280, + height: 250, + theme: { + shell: { + background: '#ffffff', + color: '#333333' + }, + tweets: { + background: '#ffffff', + color: '#333333', + links: '#3b6deb' + } + }, + features: { + scrollbar: false, + loop: false, + live: false, + hashtags: true, + timestamp: true, + avatars: false, + behavior: 'all' + } + }).render().setUser('h3rald').start(); + </script> + </section><!-- #twitter end --> + <%= render 'article_intro', :item => latest[3], :classes => "hyphenate", :extended => false %> + <article class="feature"> + <header> + <p>FEATURED CONTENT</p> + <h1><a href="/holidays/">Holidays in Italy?</a></h1> + <h2>Yes, I am really renting my house in the countryside!</h2> + </header> + <section class="hyphenate"> + <img src="/images/sessarego.jpg" alt="Sessarego" style="margin: 0 5px;" /> + <p>Looking for a peaceful and relaxing holiday in the Italian Riviera? I'm renting part of my family country home in the center of the old village of Sessarego, on a peaceful hill a few minutes away from Bogliasco, a small coastal town on the Golfo Paradiso. </p> + <p>The center of Genoa can be reached by car, bus or train in about 30 minutes and a lot of tourist locations like Camogli, Rapallo, Santa Margherita and Portofino are just a few train stops away. <a href="/holidays/">» <strong>Read More</strong></a></p> + </section> + </article> + </section><!-- #main-content-left end --> + <section class="right border-left" id="main-content-right"> + <%= render 'article_intro', :item => latest[1], :classes => "hyphenate", :extended => false %> + <%= render 'article_intro', :item => latest[2], :classes => "hyphenate", :extended => false %> + <%= render 'article_intro', :item => latest[4], :classes => "hyphenate", :extended => false %> + </section><!-- #main-content-right end --> +</section><!-- #main-content end --> +<section class="right" id="secondary-content"> + <%= render 'article_intro', :item => popular[1], :classes => "two-columns hyphenate", :extended => true %> + <article class="feature"> + <header> + <p>FEATURED CONTENT</p> + <h1><a href="/glyph/">Glyph – Rapid Document Authoring Framework</a></h1> + <h2>A free and extensible solution for personal publishing, 100% open source!</h2> + </header> + <section class="hyphenate"> + <img src="/images/glyph.png" alt="Glyph Logo" class="img-right" /> + <p>With Glyph, creating and maintaining any kind of document becomes as easy as... programming. </p> + <p>Glyph enables you to minimize text duplication, focus on content rather than presentation, manage references seamlessly and automate tedious tasks through a simple but effective macro language, specifically geared towards customization and extensibility. <a href="/glyph/">» <strong>Read More</strong></a></p> + </section> + </article> + <section class="left border-right" id="secondary-content-left"> + <%= render 'article_intro', :item => popular[0], :classes => "hyphenate", :extended => false %> + <%= render 'article_intro', :item => popular[3], :classes => "hyphenate", :extended => false %> + </section><!-- #secondary-content-left end --> + <section class="right" id="secondary-content-right"> + <%= render 'article_intro', :item => popular[2], :classes => "hyphenate", :extended => false %> + <%= render 'article_intro', :item => popular[4], :classes => "hyphenate", :extended => false %> + </section><!-- #secondary-content-right end --> +</section><!-- #secondary-content-end -->
@@ -1,52 +0,0 @@
------ -permalink: home -filters_pre: -- erb -- redcloth -title: Home -type: page -feed: '/' -feed_url: "http://feeds.feedburner.com/h3rald" -feed_title: 'Latest Articles' ------ -<% -max_items = 5 - -all_articles = latest_articles.length -latest = latest_articles 5 -popular = popular_articles 5 -all_projects = @items.select{|a| a[:type] == 'project'}.length -%> -!>/images/theme/heraldry/lion.png! - -<span class="dropcap">Y</span>ou have reached Fabio Cevasco's web site. I am a full-time technical writer living and working in Genoa, Italy. In my free time, I enjoy reading and writing about IT-related topics and programming in different programming language, especially "Ruby":http://www.ruby-lang.org. This web site is a collection of my works, both in writing and coding, and it currently features *<%= all_articles %>* "articles":/archives/ and *<%= all_projects %>* "projects":/projects/. - -My articles cover a wide range of topics, ranging from "Ruby programming":/tags/ruby/ to "software and book reviews":/tags/reviews/, "web development":/tags/webdevelopment/ and even "travelling":/tags/travelling. This web site does not have a main theme, therefore if you want to keep up-to-date about a particular topic, simply subscribe to a specific tag feed. - -I update this site regularly, but not every day (and maybe not every week): I only write a new article when I have something important to write about. For more frivolous, extemporaneous stuff feel free to have a look at my "blog":http://blog.h3rald.com, which is updated more frequently. - -You can contact me by writing an email to _h3rald [at] h3rald [dot] com_, or through "Twitter":http://www.twitter.com/h3rald, "LinkedIn":http://www.linkedin.com/pub/dir/Fabio/Cevasco, "Delicious":http://www.delicious.com/h3rald, "Facebook":http://www.facebook.com/h3rald, "Shelfari":http://www.shelfari.com/h3rald, "FriendFeed":http://friendfeed.com/h3rald or "Posterous":http://posterous.com/people/4aAQcmIVQl7H. - -<br style="clear:both" /> - -<div class="article-list left-column" id="latest-articles"> - -h3. Latest Articles - -<% -latest.each do |a| -%> -<%= render 'article_item', :article => a %> -<% end %> -</div> -<div class="article-list right-column" id="popular-articles"> - -h3. Popular Articles - -<% -popular.each do |a| -%> -<%= render 'article_item', :article => a %> -<% end %> -</div> -<div class="clearleft"></div>
@@ -57,7 +57,7 @@
# Rewrite rules. <IfModule mod_rewrite.c> RewriteEngine on -RewriteRule ^$ /home/index.html [L] +#RewriteRule ^$ /home/index.html [L] RewriteRule ^(rss|atom)/?$ /$1.xml [L] RewriteRule ^tags/([^/\.]+)/(rss|atom)/?$ /tags/$1/$2.xml [L] RewriteRule ^(articles|blog|entries|tags)/?$ /archives/ [L,R=301]
@@ -68,3 +68,4 @@ transform="translate(87.179131,151.72462)"
id="text2816" /> </g> </svg> +
@@ -1,395 +1,22 @@
------ ------ -google.load( -'search' -, -'1' -,{nocss:1});function OnLoad(){ -var searchControl=new google.search.SearchControl(); -var draw_options=new google.search.DrawOptions();draw_options.setSearchFormRoot(document.getElementById( -"search_form" -)); -var webSearch=new google.search.WebSearch();webSearch.setSiteRestriction( -'h3rald.com' -);var search_options=new google.search.SearcherOptions();search_options.setExpandMode(google.search.SearchControl.EXPAND_MODE_OPEN);searchControl.addSearcher(webSearch,search_options);searchControl.setResultSetSize(google.search.Search.LARGE_RESULTSET);searchControl.draw(document.getElementById( -"search_results" -),draw_options);} -google.setOnLoadCallback(OnLoad);---------- -(function($){$.TableOfContents=function(el,scope,options){var base=this;base.$el=$(el);base.el=el;base.toc= -"" -;base.listStyle=null;base.tags=[ -"h1" -, -"h2" -, -"h3" -, -"h4" -, -"h5" -, -"h6" -];base.init=function(){base.options=$.extend({},$.TableOfContents.defaultOptions,options);if(typeof(scope)== -"undefined" -||scope==null)scope=document.body;base.$scope=$(scope);var $first=base.$scope.find(base.tags.join( -', ' -)).filter( -':first' -);if($first.length!=1)return;base.starting_depth=base.options.startLevel;if(base.options.depth<1)base.options.depth=1;var filtered_tags=base.tags.splice(base.options.startLevel-1,base.options.depth);base.$headings=base.$scope.find(filtered_tags.join( -', ' -));if(base.options.topLinks!==false){var id=$(document.body).attr( -'id' -);if(id== -"" -){id=base.options.topBodyId;document.body.id=id};base.topLinkId=id};if(base.$el.is( -'ul' -)){base.listStyle= -'ul' -}else if(base.$el.is( -'ol' -)){base.listStyle= -'ol' -};base.buildTOC();if(base.options.proportionateSpacing===true&&!base.tieredList()){base.addSpacing()};return base};base.tieredList=function(){return(base.listStyle== -'ul' -||base.listStyle== -'ol' -)};base.buildTOC=function(){base.current_depth=base.starting_depth;base.$headings.each(function(i,element){var depth=this.nodeName.toLowerCase().substr(1,1);if(i>0||(i==0&&depth!=base.current_depth)){base.changeDepth(depth)};base.toc+=base.formatLink(this,depth,i)+ -"\n" -;if(base.options.topLinks!==false)base.addTopLink(this)});base.changeDepth(base.starting_depth,true);if(base.tieredList())base.toc= -"<li>\n" -+base.toc+ -"</li>\n" -;base.$el.html(base.toc)};base.addTopLink=function(element){var text=(base.options.topLinks===true? -"Top" -:base.options.topLinks);var $a=$( -"<a href='#" -+base.topLinkId+ -"' class='" -+base.options.topLinkClass+ -"'></a>" -).html(text);$(element).append($a)};base.formatLink=function(element,depth,index){var id=element.id;if(id== -"" -){id=base.buildSlug($(element).text());element.id=id};var a= -"<a href='#" -+id+ -"'" -;if(!base.tieredList())a+= -" class='" -+base.depthClass(depth)+ -"'" -;a+= -">" -+base.options.levelText.replace( -'%' -,$(element).text())+ -'</a>' -;return a};base.changeDepth=function(new_depth,last){if(last!==true)last=false;if(!base.tieredList()){base.current_depth=new_depth;return true};if(new_depth>base.current_depth){var opening_tags=[];for(var i=base.current_depth;i<new_depth;i++){opening_tags.push( -'<' -+base.listStyle+ -'>' -+ -"\n" -)};var li= -"<li>\n" -;base.toc+=opening_tags.join(li)+li}else if(new_depth<base.current_depth){var closing_tags=[];for(var i=base.current_depth;i>new_depth;i--){closing_tags.push( -'</' -+base.listStyle+ -'>' -+ -"\n" -)};base.toc+= -"</li>\n" -+closing_tags.join( -'</li>' -+ -"\n" -);if(!last){base.toc+= -"</li>\n<li>\n" -}}else{if(!last){base.toc+= -"</li>\n<li>\n" -}};base.current_depth=new_depth};base.buildSlug=function(text){text=text.toLowerCase().replace( -/[^a-z0-9 -]/gi, -'' -).replace( -/ /gi, -'-' -);text=text.substr(0,50);return text};base.depthClass=function(depth){return base.options.levelClass.replace( -'%' -,(depth-(base.starting_depth-1)))};base.addSpacing=function(){var start=base.$headings.filter( -':first' -).position().top;base.$headings.each(function(i,el){var $a=base.$el.find( -'a:eq(' -+i+ -')' -);var pos=(($(this).position().top-start)/(base.$scope.height()-start))*base.$el.height();$a.css({position: -"absolute" -,top:pos})})};return base.init()};$.TableOfContents.defaultOptions={startLevel:1,depth:3,levelClass: -"toc-depth-%" -,levelText: -"%" -,topLinks:false,topLinkClass: -"toc-top-link" -,topBodyId: -"toc-top" -,proportionateSpacing:false};$.fn.tableOfContents=function(scope,options){return this.each(function(){var toc=new $.TableOfContents(this,scope,options);delete toc})}})(jQuery);----------$(function(){$( -'#gallery a' -).fancybox();$( -'.fancybox' -).fancybox({frameWidth:850,frameHeight:450});});function delicious_counter(data){var posts=data[0].total_posts;if (!posts) return;var text=posts+ -" bookmarks" -;if (posts==1){text=posts+ -" bookmark" -};$( -'#delcounter' -).text(text);} -$(document).ready(function(){$( -'.timeago' -).timeago(); -$( -"#toc ol" -).tableOfContents( -"#content-body" -,{startLevel:3,depth:6,topLinks: -"[top]" -}); -var first_paragraph=$( -'#content-body p:first' -);if (!first_paragraph) return false;var t=first_paragraph.html();var first_letter=t.substr(0,1);if (first_letter.match( -/[a-z]/i)){first_paragraph.html(t.slice(1,t.length));$( -'<span></span>' -).addClass( -'dropcap' -).html(first_letter).prependTo(first_paragraph);}});---------- -Date.CultureInfo={name: -"en-US" -,englishName: -"English (United States)" -,nativeName: -"English (United States)" -,dayNames:[ -"Sunday" -, -"Monday" -, -"Tuesday" -, -"Wednesday" -, -"Thursday" -, -"Friday" -, -"Saturday" -],abbreviatedDayNames:[ -"Sun" -, -"Mon" -, -"Tue" -, -"Wed" -, -"Thu" -, -"Fri" -, -"Sat" -],shortestDayNames:[ -"Su" -, -"Mo" -, -"Tu" -, -"We" -, -"Th" -, -"Fr" -, -"Sa" -],firstLetterDayNames:[ -"S" -, -"M" -, -"T" -, -"W" -, -"T" -, -"F" -, -"S" -],monthNames:[ -"January" -, -"February" -, -"March" -, -"April" -, -"May" -, -"June" -, -"July" -, -"August" -, -"September" -, -"October" -, -"November" -, -"December" -],abbreviatedMonthNames:[ -"Jan" -, -"Feb" -, -"Mar" -, -"Apr" -, -"May" -, -"Jun" -, -"Jul" -, -"Aug" -, -"Sep" -, -"Oct" -, -"Nov" -, -"Dec" -],amDesignator: -"AM" -,pmDesignator: -"PM" -,firstDayOfWeek:0,twoDigitYearMax:2029,dateElementOrder: -"mdy" -,formatPatterns:{shortDate: -"M/d/yyyy" -,longDate: -"dddd, MMMM dd, yyyy" -,shortTime: -"h:mm tt" -,longTime: -"h:mm:ss tt" -,fullDateTime: -"dddd, MMMM dd, yyyy h:mm:ss tt" -,sortableDateTime: -"yyyy-MM-ddTHH:mm:ss" -,universalSortableDateTime: -"yyyy-MM-dd HH:mm:ssZ" -,rfc1123: -"ddd, dd MMM yyyy HH:mm:ss GMT" -,monthDay: -"MMMM dd" -,yearMonth: -"MMMM, yyyy" -},regexPatterns:{jan: -/^jan(uary)?/i,feb: -/^feb(ruary)?/i,mar: -/^mar(ch)?/i,apr: -/^apr(il)?/i,may: -/^may/i,jun: -/^jun(e)?/i,jul: -/^jul(y)?/i,aug: -/^aug(ust)?/i,sep: -/^sep(t(ember)?)?/i,oct: -/^oct(ober)?/i,nov: -/^nov(ember)?/i,dec: -/^dec(ember)?/i,sun: -/^su(n(day)?)?/i,mon: -/^mo(n(day)?)?/i,tue: -/^tu(e(s(day)?)?)?/i,wed: -/^we(d(nesday)?)?/i,thu: -/^th(u(r(s(day)?)?)?)?/i,fri: -/^fr(i(day)?)?/i,sat: -/^sa(t(urday)?)?/i,future: -/^next/i,past: -/^last|past|prev(ious)?/i,add: -/^(\+|aft(er)?|from|hence)/i,subtract: -/^(\-|bef(ore)?|ago)/i,yesterday: -/^yes(terday)?/i,today: -/^t(od(ay)?)?/i,tomorrow: -/^tom(orrow)?/i,now: -/^n(ow)?/i,millisecond: -/^ms|milli(second)?s?/i,second: -/^sec(ond)?s?/i,minute: -/^mn|min(ute)?s?/i,hour: -/^h(our)?s?/i,week: -/^w(eek)?s?/i,month: -/^m(onth)?s?/i,day: -/^d(ay)?s?/i,year: -/^y(ear)?s?/i,shortMeridian: -/^(a|p)/i,longMeridian: -/^(a\.?m?\.?|p\.?m?\.?)/i,timezone: -/^((e(s|d)t|c(s|d)t|m(s|d)t|p(s|d)t)|((gmt)?\s*(\+|\-)\s*\d\d\d\d?)|gmt|utc)/i,ordinalSuffix: -/^\s*(st|nd|rd|th)/i,timeContext: -/^\s*(\:|a(?!u|p)|p)/i},timezones:[{name: -"UTC" -,offset: -"-000" -},{name: -"GMT" -,offset: -"-000" -},{name: -"EST" -,offset: -"-0500" -},{name: -"EDT" -,offset: -"-0400" -},{name: -"CST" -,offset: -"-0600" -},{name: -"CDT" -,offset: -"-0500" -},{name: -"MST" -,offset: -"-0700" -},{name: -"MDT" -,offset: -"-0600" -},{name: -"PST" -,offset: -"-0800" -},{name: -"PDT" -,offset: -"-0700" -}]};(function(){var $D=Date,$P=$D.prototype,$C=$D.CultureInfo,p=function(s,l){if(!l){l=2;} -return( -"000" -+s).slice(l*-1);};$P.clearTime=function(){this.setHours(0);this.setMinutes(0);this.setSeconds(0);this.setMilliseconds(0);return this;};$P.setTimeToNow=function(){var n=new Date();this.setHours(n.getHours());this.setMinutes(n.getMinutes());this.setSeconds(n.getSeconds());this.setMilliseconds(n.getMilliseconds());return this;};$D.today=function(){return new Date().clearTime();};$D.compare=function(date1,date2){if(isNaN(date1)||isNaN(date2)){throw new Error(date1+ -" - " -+date2);}else if(date1 instanceof Date&&date2 instanceof Date){return(date1<date2)?-1:(date1>date2)?1:0;}else{throw new TypeError(date1+ -" - " -+date2);}};$D.equals=function(date1,date2){return(date1.compareTo(date2)===0);};$D.getDayNumberFromName=function(name){var n=$C.dayNames,m=$C.abbreviatedDayNames,o=$C.shortestDayNames,s=name.toLowerCase();for(var i=0;i<n.length;i++){if(n[i].toLowerCase()==s||m[i].toLowerCase()==s||o[i].toLowerCase()==s){return i;}} + +(function($){$.timeago=function(timestamp){if(timestamp instanceof Date)return inWords(timestamp);else if(typeof timestamp=="string")return inWords($.timeago.parse(timestamp));else return inWords($.timeago.parse($(timestamp).attr("title")));};var $t=$.timeago;$.extend($.timeago,{settings:{refreshMillis:60000,allowFuture:false,strings:{prefixAgo:null,prefixFromNow:null,suffixAgo:"ago",suffixFromNow:"from now",ago:null,fromNow:null,seconds:"less than a minute",minute:"about a minute",minutes:"%d minutes",hour:"about an hour",hours:"about %d hours",day:"a day",days:"%d days",month:"about a month",months:"%d months",year:"about a year",years:"%d years"}},inWords:function(distanceMillis){var $l=this.settings.strings;var prefix=$l.prefixAgo;var suffix=$l.suffixAgo||$l.ago;if(this.settings.allowFuture){if(distanceMillis<0){prefix=$l.prefixFromNow;suffix=$l.suffixFromNow||$l.fromNow;} +distanceMillis=Math.abs(distanceMillis);} +var seconds=distanceMillis/1000;var minutes=seconds/60;var hours=minutes/60;var days=hours/24;var years=days/365;var words=seconds<45&&substitute($l.seconds,Math.round(seconds))||seconds<90&&substitute($l.minute,1)||minutes<45&&substitute($l.minutes,Math.round(minutes))||minutes<90&&substitute($l.hour,1)||hours<24&&substitute($l.hours,Math.round(hours))||hours<48&&substitute($l.day,1)||days<30&&substitute($l.days,Math.floor(days))||days<60&&substitute($l.month,1)||days<365&&substitute($l.months,Math.floor(days/30))||years<2&&substitute($l.year,1)||substitute($l.years,Math.floor(years));return $.trim([prefix,words,suffix].join(" "));},parse:function(iso8601){var s=$.trim(iso8601);s=s.replace(/-/,"/").replace(/-/,"/");s=s.replace(/T/," ").replace(/Z/," UTC");s=s.replace(/([\+-]\d\d)\:?(\d\d)/," $1$2");return new Date(s);}});$.fn.timeago=function(){var self=this;self.each(refresh);var $s=$t.settings;if($s.refreshMillis>0){setInterval(function(){self.each(refresh);},$s.refreshMillis);} +return self;};function refresh(){var date=$t.parse(this.title);if(!isNaN(date)){$(this).text(inWords(date));} +return this;} +function inWords(date){return $t.inWords(distance(date));} +function distance(date){return(new Date().getTime()-date.getTime());} +function substitute(stringOrFunction,value){var string=$.isFunction(stringOrFunction)?stringOrFunction(value):stringOrFunction;return string.replace(/%d/i,value);} +document.createElement('abbr');})(jQuery);jQuery.easing['jswing']=jQuery.easing['swing'];jQuery.extend(jQuery.easing,{def:'easeOutQuad',swing:function(x,t,b,c,d){return jQuery.easing[jQuery.easing.def](x,t,b,c,d);},easeInQuad:function(x,t,b,c,d){return c*(t/=d)*t+b;},easeOutQuad:function(x,t,b,c,d){return-c*(t/=d)*(t-2)+b;},easeInOutQuad:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t+b;return-c/2*((--t)*(t-2)-1)+b;},easeInCubic:function(x,t,b,c,d){return c*(t/=d)*t*t+b;},easeOutCubic:function(x,t,b,c,d){return c*((t=t/d-1)*t*t+1)+b;},easeInOutCubic:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t+b;return c/2*((t-=2)*t*t+2)+b;},easeInQuart:function(x,t,b,c,d){return c*(t/=d)*t*t*t+b;},easeOutQuart:function(x,t,b,c,d){return-c*((t=t/d-1)*t*t*t-1)+b;},easeInOutQuart:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t*t+b;return-c/2*((t-=2)*t*t*t-2)+b;},easeInQuint:function(x,t,b,c,d){return c*(t/=d)*t*t*t*t+b;},easeOutQuint:function(x,t,b,c,d){return c*((t=t/d-1)*t*t*t*t+1)+b;},easeInOutQuint:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t*t*t+b;return c/2*((t-=2)*t*t*t*t+2)+b;},easeInSine:function(x,t,b,c,d){return-c*Math.cos(t/d*(Math.PI/2))+c+b;},easeOutSine:function(x,t,b,c,d){return c*Math.sin(t/d*(Math.PI/2))+b;},easeInOutSine:function(x,t,b,c,d){return-c/2*(Math.cos(Math.PI*t/d)-1)+b;},easeInExpo:function(x,t,b,c,d){return(t==0)?b:c*Math.pow(2,10*(t/d-1))+b;},easeOutExpo:function(x,t,b,c,d){return(t==d)?b+c:c*(-Math.pow(2,-10*t/d)+1)+b;},easeInOutExpo:function(x,t,b,c,d){if(t==0)return b;if(t==d)return b+c;if((t/=d/2)<1)return c/2*Math.pow(2,10*(t-1))+b;return c/2*(-Math.pow(2,-10*--t)+2)+b;},easeInCirc:function(x,t,b,c,d){return-c*(Math.sqrt(1-(t/=d)*t)-1)+b;},easeOutCirc:function(x,t,b,c,d){return c*Math.sqrt(1-(t=t/d-1)*t)+b;},easeInOutCirc:function(x,t,b,c,d){if((t/=d/2)<1)return-c/2*(Math.sqrt(1-t*t)-1)+b;return c/2*(Math.sqrt(1-(t-=2)*t)+1)+b;},easeInElastic:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d)==1)return b+c;if(!p)p=d*.3;if(a<Math.abs(c)){a=c;var s=p/4;} +else var s=p/(2*Math.PI)*Math.asin(c/a);return-(a*Math.pow(2,10*(t-=1))*Math.sin((t*d-s)*(2*Math.PI)/p))+b;},easeOutElastic:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d)==1)return b+c;if(!p)p=d*.3;if(a<Math.abs(c)){a=c;var s=p/4;} +else var s=p/(2*Math.PI)*Math.asin(c/a);return a*Math.pow(2,-10*t)*Math.sin((t*d-s)*(2*Math.PI)/p)+c+b;},easeInOutElastic:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d/2)==2)return b+c;if(!p)p=d*(.3*1.5);if(a<Math.abs(c)){a=c;var s=p/4;} +else var s=p/(2*Math.PI)*Math.asin(c/a);if(t<1)return-.5*(a*Math.pow(2,10*(t-=1))*Math.sin((t*d-s)*(2*Math.PI)/p))+b;return a*Math.pow(2,-10*(t-=1))*Math.sin((t*d-s)*(2*Math.PI)/p)*.5+c+b;},easeInBack:function(x,t,b,c,d,s){if(s==undefined)s=1.70158;return c*(t/=d)*t*((s+1)*t-s)+b;},easeOutBack:function(x,t,b,c,d,s){if(s==undefined)s=1.70158;return c*((t=t/d-1)*t*((s+1)*t+s)+1)+b;},easeInOutBack:function(x,t,b,c,d,s){if(s==undefined)s=1.70158;if((t/=d/2)<1)return c/2*(t*t*(((s*=(1.525))+1)*t-s))+b;return c/2*((t-=2)*t*(((s*=(1.525))+1)*t+s)+2)+b;},easeInBounce:function(x,t,b,c,d){return c-jQuery.easing.easeOutBounce(x,d-t,0,c,d)+b;},easeOutBounce:function(x,t,b,c,d){if((t/=d)<(1/2.75)){return c*(7.5625*t*t)+b;}else if(t<(2/2.75)){return c*(7.5625*(t-=(1.5/2.75))*t+.75)+b;}else if(t<(2.5/2.75)){return c*(7.5625*(t-=(2.25/2.75))*t+.9375)+b;}else{return c*(7.5625*(t-=(2.625/2.75))*t+.984375)+b;}},easeInOutBounce:function(x,t,b,c,d){if(t<d/2)return jQuery.easing.easeInBounce(x,t*2,0,c,d)*.5+b;return jQuery.easing.easeOutBounce(x,t*2-d,0,c,d)*.5+c*.5+b;}});eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}(';(7($){$.b.2Q=7(){u B.2t(7(){9 1J=$(B).n(\'2Z\');5(1J.1c(/^3w\\(["\']?(.*\\.2p)["\']?\\)$/i)){1J=3t.$1;$(B).n({\'2Z\':\'45\',\'2o\':"3W:3R.4m.4d(3h=F, 3T="+($(B).n(\'41\')==\'2J-3Z\'?\'4c\':\'3N\')+", Q=\'"+1J+"\')"}).2t(7(){9 1b=$(B).n(\'1b\');5(1b!=\'2e\'&&1b!=\'2n\')$(B).n(\'1b\',\'2n\')})}})};9 A,4,16=D,s=1t 1o,1w,1v=1,1y=/\\.(3A|3Y|2p|3c|3d)(.*)?$/i;9 P=($.2q.3K&&2f($.2q.3z.2k(0,1))<8);$.b.c=7(Y){Y=$.3x({},$.b.c.2R,Y);9 2s=B;7 2h(){A=B;4=Y;2r();u D};7 2r(){5(16)u;5($.1O(4.2c)){4.2c()}4.j=[];4.h=0;5(Y.j.N>0){4.j=Y.j}t{9 O={};5(!A.1H||A.1H==\'\'){9 O={d:A.d,X:A.X};5($(A).1G("1m:1D").N){O.1a=$(A).1G("1m:1D")}4.j.2j(O)}t{9 Z=$(2s).2o("a[1H="+A.1H+"]");9 O={};3C(9 i=0;i<Z.N;i++){O={d:Z[i].d,X:Z[i].X};5($(Z[i]).1G("1m:1D").N){O.1a=$(Z[i]).1G("1m:1D")}4.j.2j(O)}3F(4.j[4.h].d!=A.d){4.h++}}}5(4.23){5(P){$(\'1U, 1Q, 1P\').n(\'1S\',\'3s\')}$("#1i").n(\'25\',4.2U).J()}1d()};7 1d(){$("#1f, #1e, #V, #G").S();9 d=4.j[4.h].d;5(d.1c(/#/)){9 U=11.3r.d.3f(\'#\')[0];U=d.3g(U,\'\');U=U.2k(U.2l(\'#\'));1k(\'<6 l="3e">\'+$(U).o()+\'</6>\',4.1I,4.1x)}t 5(d.1c(1y)){s=1t 1o;s.Q=d;5(s.3a){1K()}t{$.b.c.34();$(s).x().14(\'3b\',7(){$(".I").S();1K()})}}t 5(d.1c("17")||A.3j.2l("17")>=0){1k(\'<17 l="35" 3q="$.b.c.38()" 3o="3n\'+C.T(C.3l()*3m)+\'" 2K="0" 3E="0" Q="\'+d+\'"></17>\',4.1I,4.1x)}t{$.4p(d,7(2m){1k(\'<6 l="3L">\'+2m+\'</6>\',4.1I,4.1x)})}};7 1K(){5(4.30){9 w=$.b.c.1n();9 r=C.1M(C.1M(w[0]-36,s.g)/s.g,C.1M(w[1]-4b,s.f)/s.f);9 g=C.T(r*s.g);9 f=C.T(r*s.f)}t{9 g=s.g;9 f=s.f}1k(\'<1m 48="" l="49" Q="\'+s.Q+\'" />\',g,f)};7 2F(){5((4.j.N-1)>4.h){9 d=4.j[4.h+1].d;5(d.1c(1y)){1A=1t 1o();1A.Q=d}}5(4.h>0){9 d=4.j[4.h-1].d;5(d.1c(1y)){1A=1t 1o();1A.Q=d}}};7 1k(1j,g,f){16=F;9 L=4.2Y;5(P){$("#q")[0].1E.2u("f");$("#q")[0].1E.2u("g")}5(L>0){g+=L*2;f+=L*2;$("#q").n({\'v\':L+\'z\',\'2E\':L+\'z\',\'2i\':L+\'z\',\'y\':L+\'z\',\'g\':\'2B\',\'f\':\'2B\'});5(P){$("#q")[0].1E.2C(\'f\',\'(B.2D.4j - 20)\');$("#q")[0].1E.2C(\'g\',\'(B.2D.3S - 20)\')}}t{$("#q").n({\'v\':0,\'2E\':0,\'2i\':0,\'y\':0,\'g\':\'2z%\',\'f\':\'2z%\'})}5($("#k").1u(":19")&&g==$("#k").g()&&f==$("#k").f()){$("#q").1Z("2N",7(){$("#q").1C().1F($(1j)).21("1s",7(){1g()})});u}9 w=$.b.c.1n();9 2v=(g+36)>w[0]?w[2]:(w[2]+C.T((w[0]-g-36)/2));9 2w=(f+1z)>w[1]?w[3]:(w[3]+C.T((w[1]-f-1z)/2));9 K={\'y\':2v,\'v\':2w,\'g\':g+\'z\',\'f\':f+\'z\'};5($("#k").1u(":19")){$("#q").1Z("1s",7(){$("#q").1C();$("#k").24(K,4.2X,4.2T,7(){$("#q").1F($(1j)).21("1s",7(){1g()})})})}t{5(4.1W>0&&4.j[4.h].1a!==1L){$("#q").1C().1F($(1j));9 M=4.j[4.h].1a;9 15=$.b.c.1R(M);$("#k").n({\'y\':(15.y-18)+\'z\',\'v\':(15.v-18)+\'z\',\'g\':$(M).g(),\'f\':$(M).f()});5(4.1X){K.25=\'J\'}$("#k").24(K,4.1W,4.2W,7(){1g()})}t{$("#q").S().1C().1F($(1j)).J();$("#k").n(K).21("1s",7(){1g()})}}};7 2y(){5(4.h!=0){$("#1e, #2O").x().14("R",7(e){e.2x();4.h--;1d();u D});$("#1e").J()}5(4.h!=(4.j.N-1)){$("#1f, #2M").x().14("R",7(e){e.2x();4.h++;1d();u D});$("#1f").J()}};7 1g(){2y();2F();$(W).1B(7(e){5(e.29==27){$.b.c.1l();$(W).x("1B")}t 5(e.29==37&&4.h!=0){4.h--;1d();$(W).x("1B")}t 5(e.29==39&&4.h!=(4.j.N-1)){4.h++;1d();$(W).x("1B")}});5(4.1r){$(11).14("1N 1T",$.b.c.2g)}t{$("6#k").n("1b","2e")}5(4.2b){$("#22").R($.b.c.1l)}$("#1i, #V").14("R",$.b.c.1l);$("#V").J();5(4.j[4.h].X!==1L&&4.j[4.h].X.N>0){$(\'#G 6\').o(4.j[4.h].X);$(\'#G\').J()}5(4.23&&P){$(\'1U, 1Q, 1P\',$(\'#q\')).n(\'1S\',\'19\')}5($.1O(4.2a)){4.2a()}16=D};u B.x(\'R\').R(2h)};$.b.c.2g=7(){9 m=$.b.c.1n();$("#k").n(\'y\',(($("#k").g()+36)>m[0]?m[2]:m[2]+C.T((m[0]-$("#k").g()-36)/2)));$("#k").n(\'v\',(($("#k").f()+1z)>m[1]?m[3]:m[3]+C.T((m[1]-$("#k").f()-1z)/2)))};$.b.c.1h=7(H,2A){u 2f($.3I(H.3u?H[0]:H,2A,F))||0};$.b.c.1R=7(H){9 m=H.4g();m.v+=$.b.c.1h(H,\'3k\');m.v+=$.b.c.1h(H,\'3J\');m.y+=$.b.c.1h(H,\'3H\');m.y+=$.b.c.1h(H,\'3D\');u m};$.b.c.38=7(){$(".I").S();$("#35").J()};$.b.c.1n=7(){u[$(11).g(),$(11).f(),$(W).3i(),$(W).3p()]};$.b.c.2G=7(){5(!$("#I").1u(\':19\')){33(1w);u}$("#I > 6").n(\'v\',(1v*-40)+\'z\');1v=(1v+1)%12};$.b.c.34=7(){33(1w);9 m=$.b.c.1n();$("#I").n({\'y\':((m[0]-40)/2+m[2]),\'v\':((m[1]-40)/2+m[3])}).J();$("#I").14(\'R\',$.b.c.1l);1w=3Q($.b.c.2G,3X)};$.b.c.1l=7(){16=F;$(s).x();$("#1i, #V").x();5(4.2b){$("#22").x()}$("#V, .I, #1e, #1f, #G").S();5(4.1r){$(11).x("1N 1T")}1q=7(){$("#1i, #k").S();5(4.1r){$(11).x("1N 1T")}5(P){$(\'1U, 1Q, 1P\').n(\'1S\',\'19\')}5($.1O(4.1V)){4.1V()}16=D};5($("#k").1u(":19")!==D){5(4.26>0&&4.j[4.h].1a!==1L){9 M=4.j[4.h].1a;9 15=$.b.c.1R(M);9 K={\'y\':(15.y-18)+\'z\',\'v\':(15.v-18)+\'z\',\'g\':$(M).g(),\'f\':$(M).f()};5(4.1X){K.25=\'S\'}$("#k").31(D,F).24(K,4.26,4.2S,1q)}t{$("#k").31(D,F).1Z("2N",1q)}}t{1q()}u D};$.b.c.2V=7(){9 o=\'\';o+=\'<6 l="1i"></6>\';o+=\'<6 l="22">\';o+=\'<6 p="I" l="I"><6></6></6>\';o+=\'<6 l="k">\';o+=\'<6 l="2I">\';o+=\'<6 l="V"></6>\';o+=\'<6 l="E"><6 p="E 44"></6><6 p="E 43"></6><6 p="E 42"></6><6 p="E 3V"></6><6 p="E 3U"></6><6 p="E 3O"></6><6 p="E 3M"></6><6 p="E 3P"></6></6>\';o+=\'<a d="2P:;" l="1e"><1p p="1Y" l="2O"></1p></a><a d="2P:;" l="1f"><1p p="1Y" l="2M"></1p></a>\';o+=\'<6 l="q"></6>\';o+=\'<6 l="G"></6>\';o+=\'</6>\';o+=\'</6>\';o+=\'</6>\';$(o).2H("46");$(\'<32 4i="0" 4h="0" 4k="0"><2L><13 p="G" l="4l"></13><13 p="G" l="4o"><6></6></13><13 p="G" l="4n"></13></2L></32>\').2H(\'#G\');5(P){$("#2I").47(\'<17 p="4a" 4e="2J" 2K="0"></17>\');$("#V, .E, .G, .1Y").2Q()}};$.b.c.2R={2Y:10,30:F,1X:D,1W:0,26:0,2X:3G,2W:\'28\',2S:\'28\',2T:\'28\',1I:3B,1x:3v,23:F,2U:0.3,2b:F,1r:F,j:[],2c:2d,2a:2d,1V:2d};$(W).3y(7(){$.b.c.2V()})})(4f);',62,274,'||||opts|if|div|function||var||fn|fancybox|href||height|width|itemCurrent||itemArray|fancy_outer|id|pos|css|html|class|fancy_content||imagePreloader|else|return|top||unbind|left|px|elem|this|Math|false|fancy_bg|true|fancy_title|el|fancy_loading|show|itemOpts|pad|orig_item|length|item|isIE|src|click|hide|round|target|fancy_close|document|title|settings|subGroup||window||td|bind|orig_pos|busy|iframe||visible|orig|position|match|_change_item|fancy_left|fancy_right|_finish|getNumeric|fancy_overlay|value|_set_content|close|img|getViewport|Image|span|__cleanup|centerOnScroll|normal|new|is|loadingFrame|loadingTimer|frameHeight|imageRegExp|50|objNext|keydown|empty|first|style|append|children|rel|frameWidth|image|_proceed_image|undefined|min|resize|isFunction|select|object|getPosition|visibility|scroll|embed|callbackOnClose|zoomSpeedIn|zoomOpacity|fancy_ico|fadeOut||fadeIn|fancy_wrap|overlayShow|animate|opacity|zoomSpeedOut||swing|keyCode|callbackOnShow|hideOnContentClick|callbackOnStart|null|absolute|parseInt|scrollBox|_initialize|bottom|push|substr|indexOf|data|relative|filter|png|browser|_start|matchedGroup|each|removeExpression|itemLeft|itemTop|stopPropagation|_set_navigation|100|prop|auto|setExpression|parentNode|right|_preload_neighbor_images|animateLoading|appendTo|fancy_inner|no|frameborder|tr|fancy_right_ico|fast|fancy_left_ico|javascript|fixPNG|defaults|easingOut|easingChange|overlayOpacity|build|easingIn|zoomSpeedChange|padding|backgroundImage|imageScale|stop|table|clearInterval|showLoading|fancy_frame|||showIframe||complete|load|bmp|jpeg|fancy_div|split|replace|enabled|scrollLeft|className|paddingTop|random|1000|fancy_iframe|name|scrollTop|onload|location|hidden|RegExp|jquery|355|url|extend|ready|version|jpg|425|for|borderLeftWidth|hspace|while|300|paddingLeft|curCSS|borderTopWidth|msie|fancy_ajax|fancy_bg_w|scale|fancy_bg_sw|fancy_bg_nw|setInterval|DXImageTransform|clientWidth|sizingMethod|fancy_bg_s|fancy_bg_se|progid|66|gif|repeat||backgroundRepeat|fancy_bg_e|fancy_bg_ne|fancy_bg_n|none|body|prepend|alt|fancy_img|fancy_bigIframe|60|crop|AlphaImageLoader|scrolling|jQuery|offset|cellpadding|cellspacing|clientHeight|border|fancy_title_left|Microsoft|fancy_title_right|fancy_title_main|get'.split('|'),0,{})) +(function($){$.TableOfContents=function(el,scope,options){var base=this;base.$el=$(el);base.el=el;base.toc="";base.listStyle=null;base.tags=["h1","h2","h3","h4","h5","h6"];base.init=function(){base.options=$.extend({},$.TableOfContents.defaultOptions,options);if(typeof(scope)=="undefined"||scope==null)scope=document.body;base.$scope=$(scope);var $first=base.$scope.find(base.tags.join(', ')).filter(':first');if($first.length!=1)return;base.starting_depth=base.options.startLevel;if(base.options.depth<1)base.options.depth=1;var filtered_tags=base.tags.splice(base.options.startLevel-1,base.options.depth);base.$headings=base.$scope.find(filtered_tags.join(', '));if(base.options.topLinks!==false){var id=$(document.body).attr('id');if(id==""){id=base.options.topBodyId;document.body.id=id};base.topLinkId=id};if(base.$el.is('ul')){base.listStyle='ul'}else if(base.$el.is('ol')){base.listStyle='ol'};base.buildTOC();if(base.options.proportionateSpacing===true&&!base.tieredList()){base.addSpacing()};return base};base.tieredList=function(){return(base.listStyle=='ul'||base.listStyle=='ol')};base.buildTOC=function(){base.current_depth=base.starting_depth;base.$headings.each(function(i,element){var depth=this.nodeName.toLowerCase().substr(1,1);if(i>0||(i==0&&depth!=base.current_depth)){base.changeDepth(depth)};base.toc+=base.formatLink(this,depth,i)+"\n";if(base.options.topLinks!==false)base.addTopLink(this)});base.changeDepth(base.starting_depth,true);if(base.tieredList())base.toc="<li>\n"+base.toc+"</li>\n";base.$el.html(base.toc)};base.addTopLink=function(element){var text=(base.options.topLinks===true?"Top":base.options.topLinks);var $a=$("<a href='#"+base.topLinkId+"' class='"+base.options.topLinkClass+"'></a>").html(text);$(element).append($a)};base.formatLink=function(element,depth,index){var id=element.id;if(id==""){id=base.buildSlug($(element).text());element.id=id};var a="<a href='#"+id+"'";if(!base.tieredList())a+=" class='"+base.depthClass(depth)+"'";a+=">"+base.options.levelText.replace('%',$(element).text())+'</a>';return a};base.changeDepth=function(new_depth,last){if(last!==true)last=false;if(!base.tieredList()){base.current_depth=new_depth;return true};if(new_depth>base.current_depth){var opening_tags=[];for(var i=base.current_depth;i<new_depth;i++){opening_tags.push('<'+base.listStyle+'>'+"\n")};var li="<li>\n";base.toc+=opening_tags.join(li)+li}else if(new_depth<base.current_depth){var closing_tags=[];for(var i=base.current_depth;i>new_depth;i--){closing_tags.push('</'+base.listStyle+'>'+"\n")};base.toc+="</li>\n"+closing_tags.join('</li>'+"\n");if(!last){base.toc+="</li>\n<li>\n"}}else{if(!last){base.toc+="</li>\n<li>\n"}};base.current_depth=new_depth};base.buildSlug=function(text){text=text.toLowerCase().replace(/[^a-z0-9 -]/gi,'').replace(/ /gi,'-');text=text.substr(0,50);return text};base.depthClass=function(depth){return base.options.levelClass.replace('%',(depth-(base.starting_depth-1)))};base.addSpacing=function(){var start=base.$headings.filter(':first').position().top;base.$headings.each(function(i,el){var $a=base.$el.find('a:eq('+i+')');var pos=(($(this).position().top-start)/(base.$scope.height()-start))*base.$el.height();$a.css({position:"absolute",top:pos})})};return base.init()};$.TableOfContents.defaultOptions={startLevel:1,depth:3,levelClass:"toc-depth-%",levelText:"%",topLinks:false,topLinkClass:"toc-top-link",topBodyId:"toc-top",proportionateSpacing:false};$.fn.tableOfContents=function(scope,options){return this.each(function(){var toc=new $.TableOfContents(this,scope,options);delete toc})}})(jQuery);Date.CultureInfo={name:"en-US",englishName:"English (United States)",nativeName:"English (United States)",dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],abbreviatedDayNames:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],shortestDayNames:["Su","Mo","Tu","We","Th","Fr","Sa"],firstLetterDayNames:["S","M","T","W","T","F","S"],monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],abbreviatedMonthNames:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],amDesignator:"AM",pmDesignator:"PM",firstDayOfWeek:0,twoDigitYearMax:2029,dateElementOrder:"mdy",formatPatterns:{shortDate:"M/d/yyyy",longDate:"dddd, MMMM dd, yyyy",shortTime:"h:mm tt",longTime:"h:mm:ss tt",fullDateTime:"dddd, MMMM dd, yyyy h:mm:ss tt",sortableDateTime:"yyyy-MM-ddTHH:mm:ss",universalSortableDateTime:"yyyy-MM-dd HH:mm:ssZ",rfc1123:"ddd, dd MMM yyyy HH:mm:ss GMT",monthDay:"MMMM dd",yearMonth:"MMMM, yyyy"},regexPatterns:{jan:/^jan(uary)?/i,feb:/^feb(ruary)?/i,mar:/^mar(ch)?/i,apr:/^apr(il)?/i,may:/^may/i,jun:/^jun(e)?/i,jul:/^jul(y)?/i,aug:/^aug(ust)?/i,sep:/^sep(t(ember)?)?/i,oct:/^oct(ober)?/i,nov:/^nov(ember)?/i,dec:/^dec(ember)?/i,sun:/^su(n(day)?)?/i,mon:/^mo(n(day)?)?/i,tue:/^tu(e(s(day)?)?)?/i,wed:/^we(d(nesday)?)?/i,thu:/^th(u(r(s(day)?)?)?)?/i,fri:/^fr(i(day)?)?/i,sat:/^sa(t(urday)?)?/i,future:/^next/i,past:/^last|past|prev(ious)?/i,add:/^(\+|aft(er)?|from|hence)/i,subtract:/^(\-|bef(ore)?|ago)/i,yesterday:/^yes(terday)?/i,today:/^t(od(ay)?)?/i,tomorrow:/^tom(orrow)?/i,now:/^n(ow)?/i,millisecond:/^ms|milli(second)?s?/i,second:/^sec(ond)?s?/i,minute:/^mn|min(ute)?s?/i,hour:/^h(our)?s?/i,week:/^w(eek)?s?/i,month:/^m(onth)?s?/i,day:/^d(ay)?s?/i,year:/^y(ear)?s?/i,shortMeridian:/^(a|p)/i,longMeridian:/^(a\.?m?\.?|p\.?m?\.?)/i,timezone:/^((e(s|d)t|c(s|d)t|m(s|d)t|p(s|d)t)|((gmt)?\s*(\+|\-)\s*\d\d\d\d?)|gmt|utc)/i,ordinalSuffix:/^\s*(st|nd|rd|th)/i,timeContext:/^\s*(\:|a(?!u|p)|p)/i},timezones:[{name:"UTC",offset:"-000"},{name:"GMT",offset:"-000"},{name:"EST",offset:"-0500"},{name:"EDT",offset:"-0400"},{name:"CST",offset:"-0600"},{name:"CDT",offset:"-0500"},{name:"MST",offset:"-0700"},{name:"MDT",offset:"-0600"},{name:"PST",offset:"-0800"},{name:"PDT",offset:"-0700"}]};(function(){var $D=Date,$P=$D.prototype,$C=$D.CultureInfo,p=function(s,l){if(!l){l=2;} +return("000"+s).slice(l*-1);};$P.clearTime=function(){this.setHours(0);this.setMinutes(0);this.setSeconds(0);this.setMilliseconds(0);return this;};$P.setTimeToNow=function(){var n=new Date();this.setHours(n.getHours());this.setMinutes(n.getMinutes());this.setSeconds(n.getSeconds());this.setMilliseconds(n.getMilliseconds());return this;};$D.today=function(){return new Date().clearTime();};$D.compare=function(date1,date2){if(isNaN(date1)||isNaN(date2)){throw new Error(date1+" - "+date2);}else if(date1 instanceof Date&&date2 instanceof Date){return(date1<date2)?-1:(date1>date2)?1:0;}else{throw new TypeError(date1+" - "+date2);}};$D.equals=function(date1,date2){return(date1.compareTo(date2)===0);};$D.getDayNumberFromName=function(name){var n=$C.dayNames,m=$C.abbreviatedDayNames,o=$C.shortestDayNames,s=name.toLowerCase();for(var i=0;i<n.length;i++){if(n[i].toLowerCase()==s||m[i].toLowerCase()==s||o[i].toLowerCase()==s){return i;}} return-1;};$D.getMonthNumberFromName=function(name){var n=$C.monthNames,m=$C.abbreviatedMonthNames,s=name.toLowerCase();for(var i=0;i<n.length;i++){if(n[i].toLowerCase()==s||m[i].toLowerCase()==s){return i;}} return-1;};$D.isLeapYear=function(year){return((year%4===0&&year%100!==0)||year%400===0);};$D.getDaysInMonth=function(year,month){return[31,($D.isLeapYear(year)?29:28),31,30,31,30,31,31,30,31,30,31][month];};$D.getTimezoneAbbreviation=function(offset){var z=$C.timezones,p;for(var i=0;i<z.length;i++){if(z[i].offset===offset){return z[i].name;}} return null;};$D.getTimezoneOffset=function(name){var z=$C.timezones,p;for(var i=0;i<z.length;i++){if(z[i].name===name.toUpperCase()){return z[i].offset;}} -return null;};$P.clone=function(){return new Date(this.getTime());};$P.compareTo=function(date){return Date.compare(this,date);};$P.equals=function(date){return Date.equals(this,date||new Date());};$P.between=function(start,end){return this.getTime()>=start.getTime()&&this.getTime()<=end.getTime();};$P.isAfter=function(date){return this.compareTo(date||new Date())===1;};$P.isBefore=function(date){return(this.compareTo(date||new Date())===-1);};$P.isToday=function(){return this.isSameDay(new Date());};$P.isSameDay=function(date){return this.clone().clearTime().equals(date.clone().clearTime());};$P.addMilliseconds=function(value){this.setMilliseconds(this.getMilliseconds()+value);return this;};$P.addSeconds=function(value){return this.addMilliseconds(value*1000);};$P.addMinutes=function(value){return this.addMilliseconds(value*60000);};$P.addHours=function(value){return this.addMilliseconds(value*3600000);};$P.addDays=function(value){this.setDate(this.getDate()+value);return this;};$P.addWeeks=function(value){return this.addDays(value*7);};$P.addMonths=function(value){var n=this.getDate();this.setDate(1);this.setMonth(this.getMonth()+value);this.setDate(Math.min(n,$D.getDaysInMonth(this.getFullYear(),this.getMonth())));return this;};$P.addYears=function(value){return this.addMonths(value*12);};$P.add=function(config){if(typeof config== -"number" -){this._orient=config;return this;} +return null;};$P.clone=function(){return new Date(this.getTime());};$P.compareTo=function(date){return Date.compare(this,date);};$P.equals=function(date){return Date.equals(this,date||new Date());};$P.between=function(start,end){return this.getTime()>=start.getTime()&&this.getTime()<=end.getTime();};$P.isAfter=function(date){return this.compareTo(date||new Date())===1;};$P.isBefore=function(date){return(this.compareTo(date||new Date())===-1);};$P.isToday=function(){return this.isSameDay(new Date());};$P.isSameDay=function(date){return this.clone().clearTime().equals(date.clone().clearTime());};$P.addMilliseconds=function(value){this.setMilliseconds(this.getMilliseconds()+value);return this;};$P.addSeconds=function(value){return this.addMilliseconds(value*1000);};$P.addMinutes=function(value){return this.addMilliseconds(value*60000);};$P.addHours=function(value){return this.addMilliseconds(value*3600000);};$P.addDays=function(value){this.setDate(this.getDate()+value);return this;};$P.addWeeks=function(value){return this.addDays(value*7);};$P.addMonths=function(value){var n=this.getDate();this.setDate(1);this.setMonth(this.getMonth()+value);this.setDate(Math.min(n,$D.getDaysInMonth(this.getFullYear(),this.getMonth())));return this;};$P.addYears=function(value){return this.addMonths(value*12);};$P.add=function(config){if(typeof config=="number"){this._orient=config;return this;} var x=config;if(x.milliseconds){this.addMilliseconds(x.milliseconds);} if(x.seconds){this.addSeconds(x.seconds);} if(x.minutes){this.addMinutes(x.minutes);}@@ -398,41 +25,10 @@ if(x.weeks){this.addWeeks(x.weeks);}
if(x.months){this.addMonths(x.months);} if(x.years){this.addYears(x.years);} if(x.days){this.addDays(x.days);} -return this;};var $y,$m,$d;$P.getWeek=function(){var a,b,c,d,e,f,g,n,s,w;$y=(!$y)?this.getFullYear():$y;$m=(!$m)?this.getMonth()+1:$m;$d=(!$d)?this.getDate():$d;if($m<=2){a=$y-1;b=(a -/4|0)-(a/100|0)+(a -/400|0);c=((a-1)/4|0)-((a-1) -/100|0)+((a-1)/400|0);s=b-c;e=0;f=$d-1+(31*($m-1));}else{a=$y;b=(a -/4|0)-(a/100|0)+(a -/400|0);c=((a-1)/4|0)-((a-1) -/100|0)+((a-1)/400|0);s=b-c;e=s+1;f=$d+((153*($m-3)+2)/5)+58+s;} -g=(a+b)%7;d=(f+g-e)%7;n=(f+3-d)|0;if(n<0){w=53-((g-s) -/5|0);}else if(n>364+s){w=1;}else{w=(n/7|0)+1;} -$y=$m=$d=null;return w;};$P.getISOWeek=function(){$y=this.getUTCFullYear();$m=this.getUTCMonth()+1;$d=this.getUTCDate();return p(this.getWeek());};$P.setWeek=function(n){return this.moveToDayOfWeek(1).addWeeks(n-this.getWeek());};$D._validate=function(n,min,max,name){if(typeof n== -"undefined" -){return false;}else if(typeof n!= -"number" -){throw new TypeError(n+ -" is not a Number." -);}else if(n<min||n>max){throw new RangeError(n+ -" is not a valid value for " -+name+ -"." -);} -return true;};$D.validateMillisecond=function(value){return $D._validate(value,0,999, -"millisecond" -);};$D.validateSecond=function(value){return $D._validate(value,0,59, -"second" -);};$D.validateMinute=function(value){return $D._validate(value,0,59, -"minute" -);};$D.validateHour=function(value){return $D._validate(value,0,23, -"hour" -);};$D.validateDay=function(value,year,month){return $D._validate(value,1,$D.getDaysInMonth(year,month), -"day" -);};$D.validateMonth=function(value){return $D._validate(value,0,11, -"month" -);};$D.validateYear=function(value){return $D._validate(value,0,9999, -"year" -);};$P.set=function(config){if($D.validateMillisecond(config.millisecond)){this.addMilliseconds(config.millisecond-this.getMilliseconds());} +return this;};var $y,$m,$d;$P.getWeek=function(){var a,b,c,d,e,f,g,n,s,w;$y=(!$y)?this.getFullYear():$y;$m=(!$m)?this.getMonth()+1:$m;$d=(!$d)?this.getDate():$d;if($m<=2){a=$y-1;b=(a/4|0)-(a/100|0)+(a/400|0);c=((a-1)/4|0)-((a-1)/100|0)+((a-1)/400|0);s=b-c;e=0;f=$d-1+(31*($m-1));}else{a=$y;b=(a/4|0)-(a/100|0)+(a/400|0);c=((a-1)/4|0)-((a-1)/100|0)+((a-1)/400|0);s=b-c;e=s+1;f=$d+((153*($m-3)+2)/5)+58+s;} +g=(a+b)%7;d=(f+g-e)%7;n=(f+3-d)|0;if(n<0){w=53-((g-s)/5|0);}else if(n>364+s){w=1;}else{w=(n/7|0)+1;} +$y=$m=$d=null;return w;};$P.getISOWeek=function(){$y=this.getUTCFullYear();$m=this.getUTCMonth()+1;$d=this.getUTCDate();return p(this.getWeek());};$P.setWeek=function(n){return this.moveToDayOfWeek(1).addWeeks(n-this.getWeek());};$D._validate=function(n,min,max,name){if(typeof n=="undefined"){return false;}else if(typeof n!="number"){throw new TypeError(n+" is not a Number.");}else if(n<min||n>max){throw new RangeError(n+" is not a valid value for "+name+".");} +return true;};$D.validateMillisecond=function(value){return $D._validate(value,0,999,"millisecond");};$D.validateSecond=function(value){return $D._validate(value,0,59,"second");};$D.validateMinute=function(value){return $D._validate(value,0,59,"minute");};$D.validateHour=function(value){return $D._validate(value,0,23,"hour");};$D.validateDay=function(value,year,month){return $D._validate(value,1,$D.getDaysInMonth(year,month),"day");};$D.validateMonth=function(value){return $D._validate(value,0,11,"month");};$D.validateYear=function(value){return $D._validate(value,0,9999,"year");};$P.set=function(config){if($D.validateMillisecond(config.millisecond)){this.addMilliseconds(config.millisecond-this.getMilliseconds());} if($D.validateSecond(config.second)){this.addSeconds(config.second-this.getSeconds());} if($D.validateMinute(config.minute)){this.addMinutes(config.minute-this.getMinutes());} if($D.validateHour(config.hour)){this.addHours(config.hour-this.getHours());}@@ -441,189 +37,39 @@ if($D.validateYear(config.year)){this.addYears(config.year-this.getFullYear());}
if($D.validateDay(config.day,this.getFullYear(),this.getMonth())){this.addDays(config.day-this.getDate());} if(config.timezone){this.setTimezone(config.timezone);} if(config.timezoneOffset){this.setTimezoneOffset(config.timezoneOffset);} -if(config.week&&$D._validate(config.week,0,53, -"week" -)){this.setWeek(config.week);} +if(config.week&&$D._validate(config.week,0,53,"week")){this.setWeek(config.week);} return this;};$P.moveToFirstDayOfMonth=function(){return this.set({day:1});};$P.moveToLastDayOfMonth=function(){return this.set({day:$D.getDaysInMonth(this.getFullYear(),this.getMonth())});};$P.moveToNthOccurrence=function(dayOfWeek,occurrence){var shift=0;if(occurrence>0){shift=occurrence-1;} else if(occurrence===-1){this.moveToLastDayOfMonth();if(this.getDay()!==dayOfWeek){this.moveToDayOfWeek(dayOfWeek,-1);} return this;} -return this.moveToFirstDayOfMonth().addDays(-1).moveToDayOfWeek(dayOfWeek,+1).addWeeks(shift);};$P.moveToDayOfWeek=function(dayOfWeek,orient){var diff=(dayOfWeek-this.getDay()+7*(orient||+1))%7;return this.addDays((diff===0)?diff+=7*(orient||+1):diff);};$P.moveToMonth=function(month,orient){var diff=(month-this.getMonth()+12*(orient||+1))%12;return this.addMonths((diff===0)?diff+=12*(orient||+1):diff);};$P.getOrdinalNumber=function(){return Math.ceil((this.clone().clearTime()-new Date(this.getFullYear(),0,1)) -/86400000)+1;};$P.getTimezone=function(){return $D.getTimezoneAbbreviation(this.getUTCOffset());};$P.setTimezoneOffset=function(offset){var here=this.getTimezoneOffset(),there=Number(offset)*-6/10;return this.addMinutes(there-here);};$P.setTimezone=function(offset){return this.setTimezoneOffset($D.getTimezoneOffset(offset));};$P.hasDaylightSavingTime=function(){return(Date.today().set({month:0,day:1}).getTimezoneOffset()!==Date.today().set({month:6,day:1}).getTimezoneOffset());};$P.isDaylightSavingTime=function(){return(this.hasDaylightSavingTime()&&new Date().getTimezoneOffset()===Date.today().set({month:6,day:1}).getTimezoneOffset());};$P.getUTCOffset=function(){var n=this.getTimezoneOffset()*-10/6,r;if(n<0){r=(n-10000).toString();return r.charAt(0)+r.substr(2);}else{r=(n+10000).toString();return -"+" -+r.substr(1);}};$P.getElapsed=function(date){return(date||new Date())-this;};if(!$P.toISOString){$P.toISOString=function(){function f(n){return n<10? -'0' -+n:n;} -return -'"' -+this.getUTCFullYear()+ -'-' -+f(this.getUTCMonth()+1)+ -'-' -+f(this.getUTCDate())+ -'T' -+f(this.getUTCHours())+ -':' -+f(this.getUTCMinutes())+ -':' -+f(this.getUTCSeconds())+ -'Z"' -;};} -$P._toString=$P.toString;$P.toString=function(format){var x=this;if(format&&format.length==1){var c=$C.formatPatterns;x.t=x.toString;switch(format){case -"d" -:return x.t(c.shortDate);case -"D" -:return x.t(c.longDate);case -"F" -:return x.t(c.fullDateTime);case -"m" -:return x.t(c.monthDay);case -"r" -:return x.t(c.rfc1123);case -"s" -:return x.t(c.sortableDateTime);case -"t" -:return x.t(c.shortTime);case -"T" -:return x.t(c.longTime);case -"u" -:return x.t(c.universalSortableDateTime);case -"y" -:return x.t(c.yearMonth);}} -var ord=function(n){switch(n*1){case 1:case 21:case 31:return -"st" -;case 2:case 22:return -"nd" -;case 3:case 23:return -"rd" -;default:return -"th" -;}};return format?format.replace( -/(\\)?(dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|S)/g,function(m){if(m.charAt(0)=== -"\\" -){return m.replace( -"\\" -, -"" -);} -x.h=x.getHours;switch(m){case -"hh" -:return p(x.h()<13?(x.h()===0?12:x.h()):(x.h()-12));case -"h" -:return x.h()<13?(x.h()===0?12:x.h()):(x.h()-12);case -"HH" -:return p(x.h());case -"H" -:return x.h();case -"mm" -:return p(x.getMinutes());case -"m" -:return x.getMinutes();case -"ss" -:return p(x.getSeconds());case -"s" -:return x.getSeconds();case -"yyyy" -:return p(x.getFullYear(),4);case -"yy" -:return p(x.getFullYear());case -"dddd" -:return $C.dayNames[x.getDay()];case -"ddd" -:return $C.abbreviatedDayNames[x.getDay()];case -"dd" -:return p(x.getDate());case -"d" -:return x.getDate();case -"MMMM" -:return $C.monthNames[x.getMonth()];case -"MMM" -:return $C.abbreviatedMonthNames[x.getMonth()];case -"MM" -:return p((x.getMonth()+1));case -"M" -:return x.getMonth()+1;case -"t" -:return x.h()<12?$C.amDesignator.substring(0,1):$C.pmDesignator.substring(0,1);case -"tt" -:return x.h()<12?$C.amDesignator:$C.pmDesignator;case -"S" -:return ord(x.getDate());default:return m;}}):this._toString();};}());(function(){var $D=Date,$P=$D.prototype,$C=$D.CultureInfo,$N=Number.prototype;$P._orient=+1;$P._nth=null;$P._is=false;$P._same=false;$P._isSecond=false;$N._dateElement= -"day" -;$P.next=function(){this._orient=+1;return this;};$D.next=function(){return $D.today().next();};$P.last=$P.prev=$P.previous=function(){this._orient=-1;return this;};$D.last=$D.prev=$D.previous=function(){return $D.today().last();};$P.is=function(){this._is=true;return this;};$P.same=function(){this._same=true;this._isSecond=false;return this;};$P.today=function(){return this.same().day();};$P.weekday=function(){if(this._is){this._is=false;return(!this.is().sat()&&!this.is().sun());} -return false;};$P.at=function(time){return(typeof time=== -"string" -)?$D.parse(this.toString( -"d" -)+ -" " -+time):this.set(time);};$N.fromNow=$N.after=function(date){var c={};c[this._dateElement]=this;return((!date)?new Date():date.clone()).add(c);};$N.ago=$N.before=function(date){var c={};c[this._dateElement]=this*-1;return((!date)?new Date():date.clone()).add(c);};var dx=( -"sunday monday tuesday wednesday thursday friday saturday" -).split( -/\s/),mx=( -"january february march april may june july august september october november december" -).split( -/\s/),px=( -"Millisecond Second Minute Hour Day Week Month Year" -).split( -/\s/),pxf=( -"Milliseconds Seconds Minutes Hours Date Week Month FullYear" -).split( -/\s/),nth=( -"final first second third fourth fifth" -).split( -/\s/),de;$P.toObject=function(){var o={};for(var i=0;i<px.length;i++){o[px[i].toLowerCase()]=this[ -"get" -+pxf[i]]();} +return this.moveToFirstDayOfMonth().addDays(-1).moveToDayOfWeek(dayOfWeek,+1).addWeeks(shift);};$P.moveToDayOfWeek=function(dayOfWeek,orient){var diff=(dayOfWeek-this.getDay()+7*(orient||+1))%7;return this.addDays((diff===0)?diff+=7*(orient||+1):diff);};$P.moveToMonth=function(month,orient){var diff=(month-this.getMonth()+12*(orient||+1))%12;return this.addMonths((diff===0)?diff+=12*(orient||+1):diff);};$P.getOrdinalNumber=function(){return Math.ceil((this.clone().clearTime()-new Date(this.getFullYear(),0,1))/86400000)+1;};$P.getTimezone=function(){return $D.getTimezoneAbbreviation(this.getUTCOffset());};$P.setTimezoneOffset=function(offset){var here=this.getTimezoneOffset(),there=Number(offset)*-6/10;return this.addMinutes(there-here);};$P.setTimezone=function(offset){return this.setTimezoneOffset($D.getTimezoneOffset(offset));};$P.hasDaylightSavingTime=function(){return(Date.today().set({month:0,day:1}).getTimezoneOffset()!==Date.today().set({month:6,day:1}).getTimezoneOffset());};$P.isDaylightSavingTime=function(){return(this.hasDaylightSavingTime()&&new Date().getTimezoneOffset()===Date.today().set({month:6,day:1}).getTimezoneOffset());};$P.getUTCOffset=function(){var n=this.getTimezoneOffset()*-10/6,r;if(n<0){r=(n-10000).toString();return r.charAt(0)+r.substr(2);}else{r=(n+10000).toString();return"+"+r.substr(1);}};$P.getElapsed=function(date){return(date||new Date())-this;};if(!$P.toISOString){$P.toISOString=function(){function f(n){return n<10?'0'+n:n;} +return'"'+this.getUTCFullYear()+'-'+ +f(this.getUTCMonth()+1)+'-'+ +f(this.getUTCDate())+'T'+ +f(this.getUTCHours())+':'+ +f(this.getUTCMinutes())+':'+ +f(this.getUTCSeconds())+'Z"';};} +$P._toString=$P.toString;$P.toString=function(format){var x=this;if(format&&format.length==1){var c=$C.formatPatterns;x.t=x.toString;switch(format){case"d":return x.t(c.shortDate);case"D":return x.t(c.longDate);case"F":return x.t(c.fullDateTime);case"m":return x.t(c.monthDay);case"r":return x.t(c.rfc1123);case"s":return x.t(c.sortableDateTime);case"t":return x.t(c.shortTime);case"T":return x.t(c.longTime);case"u":return x.t(c.universalSortableDateTime);case"y":return x.t(c.yearMonth);}} +var ord=function(n){switch(n*1){case 1:case 21:case 31:return"st";case 2:case 22:return"nd";case 3:case 23:return"rd";default:return"th";}};return format?format.replace(/(\\)?(dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|S)/g,function(m){if(m.charAt(0)==="\\"){return m.replace("\\","");} +x.h=x.getHours;switch(m){case"hh":return p(x.h()<13?(x.h()===0?12:x.h()):(x.h()-12));case"h":return x.h()<13?(x.h()===0?12:x.h()):(x.h()-12);case"HH":return p(x.h());case"H":return x.h();case"mm":return p(x.getMinutes());case"m":return x.getMinutes();case"ss":return p(x.getSeconds());case"s":return x.getSeconds();case"yyyy":return p(x.getFullYear(),4);case"yy":return p(x.getFullYear());case"dddd":return $C.dayNames[x.getDay()];case"ddd":return $C.abbreviatedDayNames[x.getDay()];case"dd":return p(x.getDate());case"d":return x.getDate();case"MMMM":return $C.monthNames[x.getMonth()];case"MMM":return $C.abbreviatedMonthNames[x.getMonth()];case"MM":return p((x.getMonth()+1));case"M":return x.getMonth()+1;case"t":return x.h()<12?$C.amDesignator.substring(0,1):$C.pmDesignator.substring(0,1);case"tt":return x.h()<12?$C.amDesignator:$C.pmDesignator;case"S":return ord(x.getDate());default:return m;}}):this._toString();};}());(function(){var $D=Date,$P=$D.prototype,$C=$D.CultureInfo,$N=Number.prototype;$P._orient=+1;$P._nth=null;$P._is=false;$P._same=false;$P._isSecond=false;$N._dateElement="day";$P.next=function(){this._orient=+1;return this;};$D.next=function(){return $D.today().next();};$P.last=$P.prev=$P.previous=function(){this._orient=-1;return this;};$D.last=$D.prev=$D.previous=function(){return $D.today().last();};$P.is=function(){this._is=true;return this;};$P.same=function(){this._same=true;this._isSecond=false;return this;};$P.today=function(){return this.same().day();};$P.weekday=function(){if(this._is){this._is=false;return(!this.is().sat()&&!this.is().sun());} +return false;};$P.at=function(time){return(typeof time==="string")?$D.parse(this.toString("d")+" "+time):this.set(time);};$N.fromNow=$N.after=function(date){var c={};c[this._dateElement]=this;return((!date)?new Date():date.clone()).add(c);};$N.ago=$N.before=function(date){var c={};c[this._dateElement]=this*-1;return((!date)?new Date():date.clone()).add(c);};var dx=("sunday monday tuesday wednesday thursday friday saturday").split(/\s/),mx=("january february march april may june july august september october november december").split(/\s/),px=("Millisecond Second Minute Hour Day Week Month Year").split(/\s/),pxf=("Milliseconds Seconds Minutes Hours Date Week Month FullYear").split(/\s/),nth=("final first second third fourth fifth").split(/\s/),de;$P.toObject=function(){var o={};for(var i=0;i<px.length;i++){o[px[i].toLowerCase()]=this["get"+pxf[i]]();} return o;};$D.fromObject=function(config){config.week=null;return Date.today().set(config);};var df=function(n){return function(){if(this._is){this._is=false;return this.getDay()==n;} if(this._nth!==null){if(this._isSecond){this.addSeconds(this._orient*-1);} -this._isSecond=false;var ntemp=this._nth;this._nth=null;var temp=this.clone().moveToLastDayOfMonth();this.moveToNthOccurrence(n,ntemp);if(this>temp){throw new RangeError($D.getDayName(n)+ -" does not occur " -+ntemp+ -" times in the month of " -+$D.getMonthName(temp.getMonth())+ -" " -+temp.getFullYear()+ -"." -);} +this._isSecond=false;var ntemp=this._nth;this._nth=null;var temp=this.clone().moveToLastDayOfMonth();this.moveToNthOccurrence(n,ntemp);if(this>temp){throw new RangeError($D.getDayName(n)+" does not occur "+ntemp+" times in the month of "+$D.getMonthName(temp.getMonth())+" "+temp.getFullYear()+".");} return this;} return this.moveToDayOfWeek(n,this._orient);};};var sdf=function(n){return function(){var t=$D.today(),shift=n-t.getDay();if(n===0&&$C.firstDayOfWeek===1&&t.getDay()!==0){shift=shift+7;} return t.addDays(shift);};};for(var i=0;i<dx.length;i++){$D[dx[i].toUpperCase()]=$D[dx[i].toUpperCase().substring(0,3)]=i;$D[dx[i]]=$D[dx[i].substring(0,3)]=sdf(i);$P[dx[i]]=$P[dx[i].substring(0,3)]=df(i);} var mf=function(n){return function(){if(this._is){this._is=false;return this.getMonth()===n;} return this.moveToMonth(n,this._orient);};};var smf=function(n){return function(){return $D.today().set({month:n,day:1});};};for(var j=0;j<mx.length;j++){$D[mx[j].toUpperCase()]=$D[mx[j].toUpperCase().substring(0,3)]=j;$D[mx[j]]=$D[mx[j].substring(0,3)]=smf(j);$P[mx[j]]=$P[mx[j].substring(0,3)]=mf(j);} var ef=function(j){return function(){if(this._isSecond){this._isSecond=false;return this;} -if(this._same){this._same=this._is=false;var o1=this.toObject(),o2=(arguments[0]||new Date()).toObject(),v= -"" -,k=j.toLowerCase();for(var m=(px.length-1);m>-1;m--){v=px[m].toLowerCase();if(o1[v]!=o2[v]){return false;} +if(this._same){this._same=this._is=false;var o1=this.toObject(),o2=(arguments[0]||new Date()).toObject(),v="",k=j.toLowerCase();for(var m=(px.length-1);m>-1;m--){v=px[m].toLowerCase();if(o1[v]!=o2[v]){return false;} if(k==v){break;}} return true;} -if(j.substring(j.length-1)!= -"s" -){j+= -"s" -;} -return this[ -"add" -+j](this._orient);};};var nf=function(n){return function(){this._dateElement=n;return this;};};for(var k=0;k<px.length;k++){de=px[k].toLowerCase();$P[de]=$P[de+ -"s" -]=ef(px[k]);$N[de]=$N[de+ -"s" -]=nf(de);} -$P._ss=ef( -"Second" -);var nthfn=function(n){return function(dayOfWeek){if(this._same){return this._ss(arguments[0]);} +if(j.substring(j.length-1)!="s"){j+="s";} +return this["add"+j](this._orient);};};var nf=function(n){return function(){this._dateElement=n;return this;};};for(var k=0;k<px.length;k++){de=px[k].toLowerCase();$P[de]=$P[de+"s"]=ef(px[k]);$N[de]=$N[de+"s"]=nf(de);} +$P._ss=ef("Second");var nthfn=function(n){return function(dayOfWeek){if(this._same){return this._ss(arguments[0]);} if(dayOfWeek||dayOfWeek===0){return this.moveToNthOccurrence(dayOfWeek,n);} this._nth=n;if(n===2&&(dayOfWeek===undefined||dayOfWeek===null)){this._isSecond=true;return this.addSeconds(this._orient);} -return this;};};for(var l=0;l<nth.length;l++){$P[nth[l]]=(l===0)?nthfn(-1):nthfn(l);}}());(function(){Date.Parsing={Exception:function(s){this.message= -"Parse error at '" -+s.substring(0,10)+ -" ...'" -;}};var $P=Date.Parsing;var _=$P.Operators={rtoken:function(r){return function(s){var mx=s.match(r);if(mx){return([mx[0],s.substring(mx[0].length)]);}else{throw new $P.Exception(s);}};},token:function(s){return function(s){return _.rtoken(new RegExp( -"^\s*" -+s+ -"\s*" -))(s);};},stoken:function(s){return _.rtoken(new RegExp( -"^" -+s));},until:function(p){return function(s){var qx=[],rx=null;while(s.length){try{rx=p.call(this,s);}catch(e){qx.push(rx[0]);s=rx[1];continue;} +return this;};};for(var l=0;l<nth.length;l++){$P[nth[l]]=(l===0)?nthfn(-1):nthfn(l);}}());(function(){Date.Parsing={Exception:function(s){this.message="Parse error at '"+s.substring(0,10)+" ...'";}};var $P=Date.Parsing;var _=$P.Operators={rtoken:function(r){return function(s){var mx=s.match(r);if(mx){return([mx[0],s.substring(mx[0].length)]);}else{throw new $P.Exception(s);}};},token:function(s){return function(s){return _.rtoken(new RegExp("^\s*"+s+"\s*"))(s);};},stoken:function(s){return _.rtoken(new RegExp("^"+s));},until:function(p){return function(s){var qx=[],rx=null;while(s.length){try{rx=p.call(this,s);}catch(e){qx.push(rx[0]);s=rx[1];continue;} break;} return[qx,s];};},many:function(p){return function(s){var rx=[],r=null;while(s.length){try{r=p.call(this,s);}catch(e){return[rx,s];} rx.push(r[0]);s=r[1];}@@ -637,17 +83,14 @@ if(r){return r;}}
throw new $P.Exception(s);};},each:function(){var px=arguments;return function(s){var rx=[],r=null;for(var i=0;i<px.length;i++){if(px[i]==null){continue;} try{r=(px[i].call(this,s));}catch(e){throw new $P.Exception(s);} rx.push(r[0]);s=r[1];} -return[rx,s];};},all:function(){var px=arguments,_=_;return _.each(_.optional(px));},sequence:function(px,d,c){d=d||_.rtoken( -/^\s*/);c=c||null;if(px.length==1){return px[0];} +return[rx,s];};},all:function(){var px=arguments,_=_;return _.each(_.optional(px));},sequence:function(px,d,c){d=d||_.rtoken(/^\s*/);c=c||null;if(px.length==1){return px[0];} return function(s){var r=null,q=null;var rx=[];for(var i=0;i<px.length;i++){try{r=px[i].call(this,s);}catch(e){break;} rx.push(r[0]);try{q=d.call(this,r[1]);}catch(ex){q=null;break;} s=q[1];} if(!r){throw new $P.Exception(s);} if(q){throw new $P.Exception(q[1]);} if(c){try{r=c.call(this,r[1]);}catch(ey){throw new $P.Exception(r[1]);}} -return[rx,(r?r[1]:s)];};},between:function(d1,p,d2){d2=d2||d1;var _fn=_.each(_.ignore(d1),p,_.ignore(d2));return function(s){var rx=_fn.call(this,s);return[[rx[0][0],r[0][2]],rx[1]];};},list:function(p,d,c){d=d||_.rtoken( -/^\s*/);c=c||null;return(p instanceof Array?_.each(_.product(p.slice(0,-1),_.ignore(d)),p.slice(-1),_.ignore(c)):_.each(_.many(_.each(p,_.ignore(d))),px,_.ignore(c)));},set:function(px,d,c){d=d||_.rtoken( -/^\s*/);c=c||null;return function(s){var r=null,p=null,q=null,rx=null,best=[[],s],last=false;for(var i=0;i<px.length;i++){q=null;p=null;r=null;last=(px.length==1);try{r=px[i].call(this,s);}catch(e){continue;} +return[rx,(r?r[1]:s)];};},between:function(d1,p,d2){d2=d2||d1;var _fn=_.each(_.ignore(d1),p,_.ignore(d2));return function(s){var rx=_fn.call(this,s);return[[rx[0][0],r[0][2]],rx[1]];};},list:function(p,d,c){d=d||_.rtoken(/^\s*/);c=c||null;return(p instanceof Array?_.each(_.product(p.slice(0,-1),_.ignore(d)),p.slice(-1),_.ignore(c)):_.each(_.many(_.each(p,_.ignore(d))),px,_.ignore(c)));},set:function(px,d,c){d=d||_.rtoken(/^\s*/);c=c||null;return function(s){var r=null,p=null,q=null,rx=null,best=[[],s],last=false;for(var i=0;i<px.length;i++){q=null;p=null;r=null;last=(px.length==1);try{r=px[i].call(this,s);}catch(e){continue;} rx=[[r[0]],r[1]];if(r[1].length>0&&!last){try{q=d.call(this,r[1]);}catch(ex){last=true;}}else{last=true;} if(!last&&q[1].length===0){last=true;} if(!last){var qx=[];for(var j=0;j<px.length;j++){if(i!=j){qx.push(px[j]);}}@@ -659,29 +102,9 @@ if(c){try{q=c.call(this,best[1]);}catch(ey){throw new $P.Exception(best[1]);}
best[1]=q[1];} return best;};},forward:function(gr,fname){return function(s){return gr[fname].call(this,s);};},replace:function(rule,repl){return function(s){var r=rule.call(this,s);return[repl,r[1]];};},process:function(rule,fn){return function(s){var r=rule.call(this,s);return[fn.call(this,r[0]),r[1]];};},min:function(min,rule){return function(s){var rx=rule.call(this,s);if(rx[0].length<min){throw new $P.Exception(s);} return rx;};}};var _generator=function(op){return function(){var args=null,rx=[];if(arguments.length>1){args=Array.prototype.slice.call(arguments);}else if(arguments[0]instanceof Array){args=arguments[0];} -if(args){for(var i=0,px=args.shift();i<px.length;i++){args.unshift(px[i]);rx.push(op.apply(null,args));args.shift();return rx;}}else{return op.apply(null,arguments);}};};var gx= -"optional not ignore cache" -.split( -/\s/);for(var i=0;i<gx.length;i++){_[gx[i]]=_generator(_[gx[i]]);} -var _vector=function(op){return function(){if(arguments[0]instanceof Array){return op.apply(null,arguments[0]);}else{return op.apply(null,arguments);}};};var vx= -"each any all" -.split( -/\s/);for(var j=0;j<vx.length;j++){_[vx[j]]=_vector(_[vx[j]]);}}());(function(){var $D=Date,$P=$D.prototype,$C=$D.CultureInfo;var flattenAndCompact=function(ax){var rx=[];for(var i=0;i<ax.length;i++){if(ax[i]instanceof Array){rx=rx.concat(flattenAndCompact(ax[i]));}else{if(ax[i]){rx.push(ax[i]);}}} -return rx;};$D.Grammar={};$D.Translator={hour:function(s){return function(){this.hour=Number(s);};},minute:function(s){return function(){this.minute=Number(s);};},second:function(s){return function(){this.second=Number(s);};},meridian:function(s){return function(){this.meridian=s.slice(0,1).toLowerCase();};},timezone:function(s){return function(){var n=s.replace( -/[^\d\+\-]/g, -"" -);if(n.length){this.timezoneOffset=Number(n);}else{this.timezone=s.toLowerCase();}};},day:function(x){var s=x[0];return function(){this.day=Number(s.match( -/\d+/)[0]);};},month:function(s){return function(){this.month=(s.length==3)? -"jan feb mar apr may jun jul aug sep oct nov dec" -.indexOf(s)/4:Number(s)-1;};},year:function(s){return function(){var n=Number(s);this.year=((s.length>2)?n:(n+(((n+2000)<$C.twoDigitYearMax)?2000:1900)));};},rday:function(s){return function(){switch(s){case -"yesterday" -:this.days=-1;break;case -"tomorrow" -:this.days=1;break;case -"today" -:this.days=0;break;case -"now" -:this.days=0;this.now=true;break;}};},finishExact:function(x){x=(x instanceof Array)?x:[x];for(var i=0;i<x.length;i++){if(x[i]){x[i].call(this);}} +if(args){for(var i=0,px=args.shift();i<px.length;i++){args.unshift(px[i]);rx.push(op.apply(null,args));args.shift();return rx;}}else{return op.apply(null,arguments);}};};var gx="optional not ignore cache".split(/\s/);for(var i=0;i<gx.length;i++){_[gx[i]]=_generator(_[gx[i]]);} +var _vector=function(op){return function(){if(arguments[0]instanceof Array){return op.apply(null,arguments[0]);}else{return op.apply(null,arguments);}};};var vx="each any all".split(/\s/);for(var j=0;j<vx.length;j++){_[vx[j]]=_vector(_[vx[j]]);}}());(function(){var $D=Date,$P=$D.prototype,$C=$D.CultureInfo;var flattenAndCompact=function(ax){var rx=[];for(var i=0;i<ax.length;i++){if(ax[i]instanceof Array){rx=rx.concat(flattenAndCompact(ax[i]));}else{if(ax[i]){rx.push(ax[i]);}}} +return rx;};$D.Grammar={};$D.Translator={hour:function(s){return function(){this.hour=Number(s);};},minute:function(s){return function(){this.minute=Number(s);};},second:function(s){return function(){this.second=Number(s);};},meridian:function(s){return function(){this.meridian=s.slice(0,1).toLowerCase();};},timezone:function(s){return function(){var n=s.replace(/[^\d\+\-]/g,"");if(n.length){this.timezoneOffset=Number(n);}else{this.timezone=s.toLowerCase();}};},day:function(x){var s=x[0];return function(){this.day=Number(s.match(/\d+/)[0]);};},month:function(s){return function(){this.month=(s.length==3)?"jan feb mar apr may jun jul aug sep oct nov dec".indexOf(s)/4:Number(s)-1;};},year:function(s){return function(){var n=Number(s);this.year=((s.length>2)?n:(n+(((n+2000)<$C.twoDigitYearMax)?2000:1900)));};},rday:function(s){return function(){switch(s){case"yesterday":this.days=-1;break;case"tomorrow":this.days=1;break;case"today":this.days=0;break;case"now":this.days=0;this.now=true;break;}};},finishExact:function(x){x=(x instanceof Array)?x:[x];for(var i=0;i<x.length;i++){if(x[i]){x[i].call(this);}} var now=new Date();if((this.hour||this.minute)&&(!this.month&&!this.year&&!this.day)){this.day=now.getDate();} if(!this.year){this.year=now.getFullYear();} if(!this.month&&this.month!==0){this.month=now.getMonth();}@@ -689,2609 +112,45 @@ if(!this.day){this.day=1;}
if(!this.hour){this.hour=0;} if(!this.minute){this.minute=0;} if(!this.second){this.second=0;} -if(this.meridian&&this.hour){if(this.meridian== -"p" -&&this.hour<12){this.hour=this.hour+12;}else if(this.meridian== -"a" -&&this.hour==12){this.hour=0;}} -if(this.day>$D.getDaysInMonth(this.year,this.month)){throw new RangeError(this.day+ -" is not a valid value for days." -);} +if(this.meridian&&this.hour){if(this.meridian=="p"&&this.hour<12){this.hour=this.hour+12;}else if(this.meridian=="a"&&this.hour==12){this.hour=0;}} +if(this.day>$D.getDaysInMonth(this.year,this.month)){throw new RangeError(this.day+" is not a valid value for days.");} var r=new Date(this.year,this.month,this.day,this.hour,this.minute,this.second);if(this.timezone){r.set({timezone:this.timezone});}else if(this.timezoneOffset){r.set({timezoneOffset:this.timezoneOffset});} return r;},finish:function(x){x=(x instanceof Array)?flattenAndCompact(x):[x];if(x.length===0){return null;} -for(var i=0;i<x.length;i++){if(typeof x[i]== -"function" -){x[i].call(this);}} +for(var i=0;i<x.length;i++){if(typeof x[i]=="function"){x[i].call(this);}} var today=$D.today();if(this.now&&!this.unit&&!this.operator){return new Date();}else if(this.now){today=new Date();} -var expression=!!(this.days&&this.days!==null||this.orient||this.operator);var gap,mod,orient;orient=((this.orient== -"past" -||this.operator== -"subtract" -)?-1:1);if(!this.now&& -"hour minute second" -.indexOf(this.unit)!=-1){today.setTimeToNow();} -if(this.month||this.month===0){if( -"year day hour minute second" -.indexOf(this.unit)!=-1){this.value=this.month+1;this.month=null;expression=true;}} +var expression=!!(this.days&&this.days!==null||this.orient||this.operator);var gap,mod,orient;orient=((this.orient=="past"||this.operator=="subtract")?-1:1);if(!this.now&&"hour minute second".indexOf(this.unit)!=-1){today.setTimeToNow();} +if(this.month||this.month===0){if("year day hour minute second".indexOf(this.unit)!=-1){this.value=this.month+1;this.month=null;expression=true;}} if(!expression&&this.weekday&&!this.day&&!this.days){var temp=Date[this.weekday]();this.day=temp.getDate();if(!this.month){this.month=temp.getMonth();} this.year=temp.getFullYear();} -if(expression&&this.weekday&&this.unit!= -"month" -){this.unit= -"day" -;gap=($D.getDayNumberFromName(this.weekday)-today.getDay());mod=7;this.days=gap?((gap+(orient*mod))%mod):(orient*mod);} -if(this.month&&this.unit== -"day" -&&this.operator){this.value=(this.month+1);this.month=null;} +if(expression&&this.weekday&&this.unit!="month"){this.unit="day";gap=($D.getDayNumberFromName(this.weekday)-today.getDay());mod=7;this.days=gap?((gap+(orient*mod))%mod):(orient*mod);} +if(this.month&&this.unit=="day"&&this.operator){this.value=(this.month+1);this.month=null;} if(this.value!=null&&this.month!=null&&this.year!=null){this.day=this.value*1;} if(this.month&&!this.day&&this.value){today.set({day:this.value*1});if(!expression){this.day=this.value*1;}} -if(!this.month&&this.value&&this.unit== -"month" -&&!this.now){this.month=this.value;expression=true;} -if(expression&&(this.month||this.month===0)&&this.unit!= -"year" -){this.unit= -"month" -;gap=(this.month-today.getMonth());mod=12;this.months=gap?((gap+(orient*mod))%mod):(orient*mod);this.month=null;} -if(!this.unit){this.unit= -"day" -;} -if(!this.value&&this.operator&&this.operator!==null&&this[this.unit+ -"s" -]&&this[this.unit+ -"s" -]!==null){this[this.unit+ -"s" -]=this[this.unit+ -"s" -]+((this.operator== -"add" -)?1:-1)+(this.value||0)*orient;}else if(this[this.unit+ -"s" -]==null||this.operator!=null){if(!this.value){this.value=1;} -this[this.unit+ -"s" -]=this.value*orient;} -if(this.meridian&&this.hour){if(this.meridian== -"p" -&&this.hour<12){this.hour=this.hour+12;}else if(this.meridian== -"a" -&&this.hour==12){this.hour=0;}} +if(!this.month&&this.value&&this.unit=="month"&&!this.now){this.month=this.value;expression=true;} +if(expression&&(this.month||this.month===0)&&this.unit!="year"){this.unit="month";gap=(this.month-today.getMonth());mod=12;this.months=gap?((gap+(orient*mod))%mod):(orient*mod);this.month=null;} +if(!this.unit){this.unit="day";} +if(!this.value&&this.operator&&this.operator!==null&&this[this.unit+"s"]&&this[this.unit+"s"]!==null){this[this.unit+"s"]=this[this.unit+"s"]+((this.operator=="add")?1:-1)+(this.value||0)*orient;}else if(this[this.unit+"s"]==null||this.operator!=null){if(!this.value){this.value=1;} +this[this.unit+"s"]=this.value*orient;} +if(this.meridian&&this.hour){if(this.meridian=="p"&&this.hour<12){this.hour=this.hour+12;}else if(this.meridian=="a"&&this.hour==12){this.hour=0;}} if(this.weekday&&!this.day&&!this.days){var temp=Date[this.weekday]();this.day=temp.getDate();if(temp.getMonth()!==today.getMonth()){this.month=temp.getMonth();}} if((this.month||this.month===0)&&!this.day){this.day=1;} -if(!this.orient&&!this.operator&&this.unit== -"week" -&&this.value&&!this.day&&!this.month){return Date.today().setWeek(this.value);} +if(!this.orient&&!this.operator&&this.unit=="week"&&this.value&&!this.day&&!this.month){return Date.today().setWeek(this.value);} if(expression&&this.timezone&&this.day&&this.days){this.day=this.days;} -return(expression)?today.add(this):today.set(this);}};var _=$D.Parsing.Operators,g=$D.Grammar,t=$D.Translator,_fn;g.datePartDelimiter=_.rtoken( -/^([\s\-\.\,\/\x27]+)/);g.timePartDelimiter=_.stoken( -":" -);g.whiteSpace=_.rtoken( -/^\s*/);g.generalDelimiter=_.rtoken( -/^(([\s\,]|at|@|on)+)/);var _C={};g.ctoken=function(keys){var fn=_C[keys];if(!fn){var c=$C.regexPatterns;var kx=keys.split( -/\s+/),px=[];for(var i=0;i<kx.length;i++){px.push(_.replace(_.rtoken(c[kx[i]]),kx[i]));} +return(expression)?today.add(this):today.set(this);}};var _=$D.Parsing.Operators,g=$D.Grammar,t=$D.Translator,_fn;g.datePartDelimiter=_.rtoken(/^([\s\-\.\,\/\x27]+)/);g.timePartDelimiter=_.stoken(":");g.whiteSpace=_.rtoken(/^\s*/);g.generalDelimiter=_.rtoken(/^(([\s\,]|at|@|on)+)/);var _C={};g.ctoken=function(keys){var fn=_C[keys];if(!fn){var c=$C.regexPatterns;var kx=keys.split(/\s+/),px=[];for(var i=0;i<kx.length;i++){px.push(_.replace(_.rtoken(c[kx[i]]),kx[i]));} fn=_C[keys]=_.any.apply(null,px);} -return fn;};g.ctoken2=function(key){return _.rtoken($C.regexPatterns[key]);};g.h=_.cache(_.process(_.rtoken( -/^(0[0-9]|1[0-2]|[1-9])/),t.hour));g.hh=_.cache(_.process(_.rtoken( -/^(0[0-9]|1[0-2])/),t.hour));g.H=_.cache(_.process(_.rtoken( -/^([0-1][0-9]|2[0-3]|[0-9])/),t.hour));g.HH=_.cache(_.process(_.rtoken( -/^([0-1][0-9]|2[0-3])/),t.hour));g.m=_.cache(_.process(_.rtoken( -/^([0-5][0-9]|[0-9])/),t.minute));g.mm=_.cache(_.process(_.rtoken( -/^[0-5][0-9]/),t.minute));g.s=_.cache(_.process(_.rtoken( -/^([0-5][0-9]|[0-9])/),t.second));g.ss=_.cache(_.process(_.rtoken( -/^[0-5][0-9]/),t.second));g.hms=_.cache(_.sequence([g.H,g.m,g.s],g.timePartDelimiter));g.t=_.cache(_.process(g.ctoken2( -"shortMeridian" -),t.meridian));g.tt=_.cache(_.process(g.ctoken2( -"longMeridian" -),t.meridian));g.z=_.cache(_.process(_.rtoken( -/^((\+|\-)\s*\d\d\d\d)|((\+|\-)\d\d\:?\d\d)/),t.timezone));g.zz=_.cache(_.process(_.rtoken( -/^((\+|\-)\s*\d\d\d\d)|((\+|\-)\d\d\:?\d\d)/),t.timezone));g.zzz=_.cache(_.process(g.ctoken2( -"timezone" -),t.timezone));g.timeSuffix=_.each(_.ignore(g.whiteSpace),_.set([g.tt,g.zzz]));g.time=_.each(_.optional(_.ignore(_.stoken( -"T" -))),g.hms,g.timeSuffix);g.d=_.cache(_.process(_.each(_.rtoken( -/^([0-2]\d|3[0-1]|\d)/),_.optional(g.ctoken2( -"ordinalSuffix" -))),t.day));g.dd=_.cache(_.process(_.each(_.rtoken( -/^([0-2]\d|3[0-1])/),_.optional(g.ctoken2( -"ordinalSuffix" -))),t.day));g.ddd=g.dddd=_.cache(_.process(g.ctoken( -"sun mon tue wed thu fri sat" -),function(s){return function(){this.weekday=s;};}));g.M=_.cache(_.process(_.rtoken( -/^(1[0-2]|0\d|\d)/),t.month));g.MM=_.cache(_.process(_.rtoken( -/^(1[0-2]|0\d)/),t.month));g.MMM=g.MMMM=_.cache(_.process(g.ctoken( -"jan feb mar apr may jun jul aug sep oct nov dec" -),t.month));g.y=_.cache(_.process(_.rtoken( -/^(\d\d?)/),t.year));g.yy=_.cache(_.process(_.rtoken( -/^(\d\d)/),t.year));g.yyy=_.cache(_.process(_.rtoken( -/^(\d\d?\d?\d?)/),t.year));g.yyyy=_.cache(_.process(_.rtoken( -/^(\d\d\d\d)/),t.year));_fn=function(){return _.each(_.any.apply(null,arguments),_.not(g.ctoken2( -"timeContext" -)));};g.day=_fn(g.d,g.dd);g.month=_fn(g.M,g.MMM);g.year=_fn(g.yyyy,g.yy);g.orientation=_.process(g.ctoken( -"past future" -),function(s){return function(){this.orient=s;};});g.operator=_.process(g.ctoken( -"add subtract" -),function(s){return function(){this.operator=s;};});g.rday=_.process(g.ctoken( -"yesterday tomorrow today now" -),t.rday);g.unit=_.process(g.ctoken( -"second minute hour day week month year" -),function(s){return function(){this.unit=s;};});g.value=_.process(_.rtoken( -/^\d\d?(st|nd|rd|th)?/),function(s){return function(){this.value=s.replace( -/\D/g, -"" -);};});g.expression=_.set([g.rday,g.operator,g.value,g.unit,g.orientation,g.ddd,g.MMM]);_fn=function(){return _.set(arguments,g.datePartDelimiter);};g.mdy=_fn(g.ddd,g.month,g.day,g.year);g.ymd=_fn(g.ddd,g.year,g.month,g.day);g.dmy=_fn(g.ddd,g.day,g.month,g.year);g.date=function(s){return((g[$C.dateElementOrder]||g.mdy).call(this,s));};g.format=_.process(_.many(_.any(_.process(_.rtoken( -/^(dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|zz?z?)/),function(fmt){if(g[fmt]){return g[fmt];}else{throw $D.Parsing.Exception(fmt);}}),_.process(_.rtoken( -/^[^dMyhHmstz]+/),function(s){return _.ignore(_.stoken(s));}))),function(rules){return _.process(_.each.apply(null,rules),t.finishExact);});var _F={};var _get=function(f){return _F[f]=(_F[f]||g.format(f)[0]);};g.formats=function(fx){if(fx instanceof Array){var rx=[];for(var i=0;i<fx.length;i++){rx.push(_get(fx[i]));} -return _.any.apply(null,rx);}else{return _get(fx);}};g._formats=g.formats([ -"\"yyyy-MM-ddTHH:mm:ssZ\"" -, -"yyyy-MM-ddTHH:mm:ssZ" -, -"yyyy-MM-ddTHH:mm:ssz" -, -"yyyy-MM-ddTHH:mm:ss" -, -"yyyy-MM-ddTHH:mmZ" -, -"yyyy-MM-ddTHH:mmz" -, -"yyyy-MM-ddTHH:mm" -, -"ddd, MMM dd, yyyy H:mm:ss tt" -, -"ddd MMM d yyyy HH:mm:ss zzz" -, -"MMddyyyy" -, -"ddMMyyyy" -, -"Mddyyyy" -, -"ddMyyyy" -, -"Mdyyyy" -, -"dMyyyy" -, -"yyyy" -, -"Mdyy" -, -"dMyy" -, -"d" -]);g._start=_.process(_.set([g.date,g.time,g.expression],g.generalDelimiter,g.whiteSpace),t.finish);g.start=function(s){try{var r=g._formats.call({},s);if(r[1].length===0){return r;}}catch(e){} +return fn;};g.ctoken2=function(key){return _.rtoken($C.regexPatterns[key]);};g.h=_.cache(_.process(_.rtoken(/^(0[0-9]|1[0-2]|[1-9])/),t.hour));g.hh=_.cache(_.process(_.rtoken(/^(0[0-9]|1[0-2])/),t.hour));g.H=_.cache(_.process(_.rtoken(/^([0-1][0-9]|2[0-3]|[0-9])/),t.hour));g.HH=_.cache(_.process(_.rtoken(/^([0-1][0-9]|2[0-3])/),t.hour));g.m=_.cache(_.process(_.rtoken(/^([0-5][0-9]|[0-9])/),t.minute));g.mm=_.cache(_.process(_.rtoken(/^[0-5][0-9]/),t.minute));g.s=_.cache(_.process(_.rtoken(/^([0-5][0-9]|[0-9])/),t.second));g.ss=_.cache(_.process(_.rtoken(/^[0-5][0-9]/),t.second));g.hms=_.cache(_.sequence([g.H,g.m,g.s],g.timePartDelimiter));g.t=_.cache(_.process(g.ctoken2("shortMeridian"),t.meridian));g.tt=_.cache(_.process(g.ctoken2("longMeridian"),t.meridian));g.z=_.cache(_.process(_.rtoken(/^((\+|\-)\s*\d\d\d\d)|((\+|\-)\d\d\:?\d\d)/),t.timezone));g.zz=_.cache(_.process(_.rtoken(/^((\+|\-)\s*\d\d\d\d)|((\+|\-)\d\d\:?\d\d)/),t.timezone));g.zzz=_.cache(_.process(g.ctoken2("timezone"),t.timezone));g.timeSuffix=_.each(_.ignore(g.whiteSpace),_.set([g.tt,g.zzz]));g.time=_.each(_.optional(_.ignore(_.stoken("T"))),g.hms,g.timeSuffix);g.d=_.cache(_.process(_.each(_.rtoken(/^([0-2]\d|3[0-1]|\d)/),_.optional(g.ctoken2("ordinalSuffix"))),t.day));g.dd=_.cache(_.process(_.each(_.rtoken(/^([0-2]\d|3[0-1])/),_.optional(g.ctoken2("ordinalSuffix"))),t.day));g.ddd=g.dddd=_.cache(_.process(g.ctoken("sun mon tue wed thu fri sat"),function(s){return function(){this.weekday=s;};}));g.M=_.cache(_.process(_.rtoken(/^(1[0-2]|0\d|\d)/),t.month));g.MM=_.cache(_.process(_.rtoken(/^(1[0-2]|0\d)/),t.month));g.MMM=g.MMMM=_.cache(_.process(g.ctoken("jan feb mar apr may jun jul aug sep oct nov dec"),t.month));g.y=_.cache(_.process(_.rtoken(/^(\d\d?)/),t.year));g.yy=_.cache(_.process(_.rtoken(/^(\d\d)/),t.year));g.yyy=_.cache(_.process(_.rtoken(/^(\d\d?\d?\d?)/),t.year));g.yyyy=_.cache(_.process(_.rtoken(/^(\d\d\d\d)/),t.year));_fn=function(){return _.each(_.any.apply(null,arguments),_.not(g.ctoken2("timeContext")));};g.day=_fn(g.d,g.dd);g.month=_fn(g.M,g.MMM);g.year=_fn(g.yyyy,g.yy);g.orientation=_.process(g.ctoken("past future"),function(s){return function(){this.orient=s;};});g.operator=_.process(g.ctoken("add subtract"),function(s){return function(){this.operator=s;};});g.rday=_.process(g.ctoken("yesterday tomorrow today now"),t.rday);g.unit=_.process(g.ctoken("second minute hour day week month year"),function(s){return function(){this.unit=s;};});g.value=_.process(_.rtoken(/^\d\d?(st|nd|rd|th)?/),function(s){return function(){this.value=s.replace(/\D/g,"");};});g.expression=_.set([g.rday,g.operator,g.value,g.unit,g.orientation,g.ddd,g.MMM]);_fn=function(){return _.set(arguments,g.datePartDelimiter);};g.mdy=_fn(g.ddd,g.month,g.day,g.year);g.ymd=_fn(g.ddd,g.year,g.month,g.day);g.dmy=_fn(g.ddd,g.day,g.month,g.year);g.date=function(s){return((g[$C.dateElementOrder]||g.mdy).call(this,s));};g.format=_.process(_.many(_.any(_.process(_.rtoken(/^(dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|zz?z?)/),function(fmt){if(g[fmt]){return g[fmt];}else{throw $D.Parsing.Exception(fmt);}}),_.process(_.rtoken(/^[^dMyhHmstz]+/),function(s){return _.ignore(_.stoken(s));}))),function(rules){return _.process(_.each.apply(null,rules),t.finishExact);});var _F={};var _get=function(f){return _F[f]=(_F[f]||g.format(f)[0]);};g.formats=function(fx){if(fx instanceof Array){var rx=[];for(var i=0;i<fx.length;i++){rx.push(_get(fx[i]));} +return _.any.apply(null,rx);}else{return _get(fx);}};g._formats=g.formats(["\"yyyy-MM-ddTHH:mm:ssZ\"","yyyy-MM-ddTHH:mm:ssZ","yyyy-MM-ddTHH:mm:ssz","yyyy-MM-ddTHH:mm:ss","yyyy-MM-ddTHH:mmZ","yyyy-MM-ddTHH:mmz","yyyy-MM-ddTHH:mm","ddd, MMM dd, yyyy H:mm:ss tt","ddd MMM d yyyy HH:mm:ss zzz","MMddyyyy","ddMMyyyy","Mddyyyy","ddMyyyy","Mdyyyy","dMyyyy","yyyy","Mdyy","dMyy","d"]);g._start=_.process(_.set([g.date,g.time,g.expression],g.generalDelimiter,g.whiteSpace),t.finish);g.start=function(s){try{var r=g._formats.call({},s);if(r[1].length===0){return r;}}catch(e){} return g._start.call({},s);};$D._parse=$D.parse;$D.parse=function(s){var r=null;if(!s){return null;} if(s instanceof Date){return s;} -try{r=$D.Grammar.start.call({},s.replace( -/^\s*(\S*(\s+\S+)*)\s*$/, -"$1" -));}catch(e){return null;} +try{r=$D.Grammar.start.call({},s.replace(/^\s*(\S*(\s+\S+)*)\s*$/,"$1"));}catch(e){return null;} return((r[1].length===0)?r[0]:null);};$D.getParseFunction=function(fx){var fn=$D.Grammar.formats(fx);return function(s){var r=null;try{r=fn.call({},s);}catch(e){return null;} -return((r[1].length===0)?r[0]:null);};};$D.parseExact=function(s,fx){return $D.getParseFunction(fx)(s);};}());---------- -(function($){$.timeago=function(timestamp){if (timestamp instanceof Date) return inWords(timestamp);else if (typeof timestamp== -"string" -) return inWords($.timeago.parse(timestamp));else return inWords($.timeago.parse($(timestamp).attr( -"title" -)));};var $t=$.timeago;$.extend($.timeago,{settings:{refreshMillis:60000,allowFuture:false,strings:{prefixAgo:null,prefixFromNow:null,suffixAgo: -"ago" -,suffixFromNow: -"from now" -,ago:null, -fromNow:null, -seconds: -"less than a minute" -,minute: -"about a minute" -,minutes: -"%d minutes" -,hour: -"about an hour" -,hours: -"about %d hours" -,day: -"a day" -,days: -"%d days" -,month: -"about a month" -,months: -"%d months" -,year: -"about a year" -,years: -"%d years" -}},inWords:function(distanceMillis){var $l=this.settings.strings;var prefix=$l.prefixAgo;var suffix=$l.suffixAgo||$l.ago;if (this.settings.allowFuture){if (distanceMillis<0){prefix=$l.prefixFromNow;suffix=$l.suffixFromNow||$l.fromNow;} -distanceMillis=Math.abs(distanceMillis);} -var seconds=distanceMillis / 1000;var minutes=seconds / 60;var hours=minutes / 60;var days=hours / 24;var years=days / 365;var words=seconds<45&&substitute($l.seconds,Math.round(seconds))||seconds<90&&substitute($l.minute,1)||minutes<45&&substitute($l.minutes,Math.round(minutes))||minutes<90&&substitute($l.hour,1)||hours<24&&substitute($l.hours,Math.round(hours))||hours<48&&substitute($l.day,1)||days<30&&substitute($l.days,Math.floor(days))||days<60&&substitute($l.month,1)||days<365&&substitute($l.months,Math.floor(days / 30))||years<2&&substitute($l.year,1)||substitute($l.years,Math.floor(years));return $.trim([prefix,words,suffix].join( -" " -));},parse:function(iso8601){var s=$.trim(iso8601);s=s.replace( -/-/, -"/" -).replace( -/-/, -"/" -);s=s.replace( -/T/, -" " -).replace( -/Z/, -" UTC" -);s=s.replace( -/([\+-]\d\d)\:?(\d\d)/, -" $1$2" -); -return new Date(s);}});$.fn.timeago=function(){var self=this;self.each(refresh);var $s=$t.settings;if ($s.refreshMillis>0){setInterval(function(){self.each(refresh);},$s.refreshMillis);} -return self;};function refresh(){var date=$t.parse(this.title);if (!isNaN(date)){$(this).text(inWords(date));} -return this;} -function inWords(date){return $t.inWords(distance(date));} -function distance(date){return (new Date().getTime()-date.getTime());} -function substitute(stringOrFunction,value){var string=$.isFunction(stringOrFunction)?stringOrFunction(value):stringOrFunction;return string.replace( -/%d/i,value);} -document.createElement( -'abbr' -);})(jQuery);---------- -jQuery.easing[ -'jswing' -]=jQuery.easing[ -'swing' -];jQuery.extend(jQuery.easing,{def: -'easeOutQuad' -,swing:function (x,t,b,c,d){ -return jQuery.easing[jQuery.easing.def](x,t,b,c,d);},easeInQuad:function (x,t,b,c,d){return c*(t/=d)*t+b;},easeOutQuad:function (x,t,b,c,d){return-c *(t/=d)*(t-2)+b;},easeInOutQuad:function (x,t,b,c,d){if ((t -/=d/2)<1) return c/2*t*t+b;return-c/2 * ((--t)*(t-2)-1)+b;},easeInCubic:function (x,t,b,c,d){return c*(t/=d)*t*t+b;},easeOutCubic:function (x,t,b,c,d){return c*((t=t/d-1)*t*t+1)+b;},easeInOutCubic:function (x,t,b,c,d){if ((t -/=d/2)<1) return c/2*t*t*t+b;return c/2*((t-=2)*t*t+2)+b;},easeInQuart:function (x,t,b,c,d){return c*(t/=d)*t*t*t+b;},easeOutQuart:function (x,t,b,c,d){return-c * ((t=t/d-1)*t*t*t-1)+b;},easeInOutQuart:function (x,t,b,c,d){if ((t -/=d/2)<1) return c/2*t*t*t*t+b;return-c/2 * ((t-=2)*t*t*t-2)+b;},easeInQuint:function (x,t,b,c,d){return c*(t/=d)*t*t*t*t+b;},easeOutQuint:function (x,t,b,c,d){return c*((t=t/d-1)*t*t*t*t+1)+b;},easeInOutQuint:function (x,t,b,c,d){if ((t -/=d/2)<1) return c/2*t*t*t*t*t+b;return c/2*((t-=2)*t*t*t*t+2)+b;},easeInSine:function (x,t,b,c,d){return-c * Math.cos(t -/d * (Math.PI/2))+c+b;},easeOutSine:function (x,t,b,c,d){return c * Math.sin(t -/d * (Math.PI/2))+b;},easeInOutSine:function (x,t,b,c,d){return-c -/2 * (Math.cos(Math.PI*t/d)-1)+b;},easeInExpo:function (x,t,b,c,d){return (t==0)?b:c * Math.pow(2,10 * (t/d-1))+b;},easeOutExpo:function (x,t,b,c,d){return (t==d)?b+c:c * (-Math.pow(2,-10 * t/d)+1)+b;},easeInOutExpo:function (x,t,b,c,d){if (t==0) return b;if (t==d) return b+c;if ((t -/=d/2)<1) return c/2 * Math.pow(2,10 * (t-1))+b;return c/2 * (-Math.pow(2,-10 *--t)+2)+b;},easeInCirc:function (x,t,b,c,d){return-c * (Math.sqrt(1-(t/=d)*t)-1)+b;},easeOutCirc:function (x,t,b,c,d){return c * Math.sqrt(1-(t=t/d-1)*t)+b;},easeInOutCirc:function (x,t,b,c,d){if ((t -/=d/2)<1) return-c/2 * (Math.sqrt(1-t*t)-1)+b;return c/2 * (Math.sqrt(1-(t-=2)*t)+1)+b;},easeInElastic:function (x,t,b,c,d){var s=1.70158;var p=0;var a=c;if (t==0) return b;if ((t/=d)==1) return b+c;if (!p) p=d*.3;if (a<Math.abs(c)){a=c;var s=p/4;} -else var s=p -/(2*Math.PI) * Math.asin (c/a);return-(a*Math.pow(2,10*(t-=1)) * Math.sin((t*d-s)*(2*Math.PI)/p))+b;},easeOutElastic:function (x,t,b,c,d){var s=1.70158;var p=0;var a=c;if (t==0) return b;if ((t/=d)==1) return b+c;if (!p) p=d*.3;if (a<Math.abs(c)){a=c;var s=p/4;} -else var s=p -/(2*Math.PI) * Math.asin (c/a);return a*Math.pow(2,-10*t) * Math.sin((t*d-s)*(2*Math.PI)/p)+c+b;},easeInOutElastic:function (x,t,b,c,d){var s=1.70158;var p=0;var a=c;if (t==0) return b;if ((t -/=d/2)==2) return b+c;if (!p) p=d*(.3*1.5);if (a<Math.abs(c)){a=c;var s=p/4;} -else var s=p -/(2*Math.PI) * Math.asin (c/a);if (t<1) return-.5*(a*Math.pow(2,10*(t-=1)) * Math.sin((t*d-s)*(2*Math.PI)/p))+b;return a*Math.pow(2,-10*(t-=1)) * Math.sin((t*d-s)*(2*Math.PI)/p)*.5+c+b;},easeInBack:function (x,t,b,c,d,s){if (s==undefined) s=1.70158;return c*(t/=d)*t*((s+1)*t-s)+b;},easeOutBack:function (x,t,b,c,d,s){if (s==undefined) s=1.70158;return c*((t=t/d-1)*t*((s+1)*t+s)+1)+b;},easeInOutBack:function (x,t,b,c,d,s){if (s==undefined) s=1.70158;if ((t -/=d/2)<1) return c/2*(t*t*(((s*=(1.525))+1)*t-s))+b;return c/2*((t-=2)*t*(((s*=(1.525))+1)*t+s)+2)+b;},easeInBounce:function (x,t,b,c,d){return c-jQuery.easing.easeOutBounce (x,d-t,0,c,d)+b;},easeOutBounce:function (x,t,b,c,d){if ((t -/=d) < (1/2.75)){return c*(7.5625*t*t)+b;} else if (t<(2/2.75)){return c*(7.5625*(t-=(1.5/2.75))*t+.75)+b;} else if (t<(2.5/2.75)){return c*(7.5625*(t-=(2.25/2.75))*t+.9375)+b;} else {return c*(7.5625*(t-=(2.625/2.75))*t+.984375)+b;}},easeInOutBounce:function (x,t,b,c,d){if (t<d/2) return jQuery.easing.easeInBounce (x,t*2,0,c,d) * .5+b;return jQuery.easing.easeOutBounce (x,t*2-d,0,c,d) * .5+c*.5+b;}}); ----------- -(function(){var -window=this, -undefined, -_jQuery=window.jQuery, -_$=window.$,jQuery=window.jQuery=window.$=function(selector,context){ -return new jQuery.fn.init(selector,context);}, -quickExpr= -/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/, -isSimple= -/^.[^:#\[\.,]*$/;jQuery.fn=jQuery.prototype={init:function(selector,context){ -selector=selector||document; -if (selector.nodeType){this[0]=selector;this.length=1;this.context=selector;return this;} -if (typeof selector=== -"string" -){ -var match=quickExpr.exec(selector); -if (match&&(match[1]||!context)){ -if (match[1]) -selector=jQuery.clean([ match[1] ],context); -else {var elem=document.getElementById(match[3]); -if (elem&&elem.id !=match[3]) -return jQuery().find(selector); -var ret=jQuery(elem||[]);ret.context=document;ret.selector=selector;return ret;} -} else -return jQuery(context).find(selector); -} else if (jQuery.isFunction(selector)) -return jQuery(document).ready(selector); -if (selector.selector&&selector.context){this.selector=selector.selector;this.context=selector.context;} -return this.setArray(jQuery.isArray(selector)?selector:jQuery.makeArray(selector));}, -selector: -"" -, -jquery: -"1.3.2" -, -size:function(){return this.length;}, -get:function(num){return num===undefined? -Array.prototype.slice.call(this): -this[ num ];}, -pushStack:function(elems,name,selector){ -var ret=jQuery(elems); -ret.prevObject=this;ret.context=this.context;if (name=== -"find" -) -ret.selector=this.selector+(this.selector? -" " -: -"" -)+selector;else if (name) -ret.selector=this.selector+ -"." -+name+ -"(" -+selector+ -")" -; -return ret;}, -setArray:function(elems){ -this.length=0;Array.prototype.push.apply(this,elems);return this;}, -each:function(callback,args){return jQuery.each(this,callback,args);}, -index:function(elem){ -return jQuery.inArray( -elem&&elem.jquery?elem[0]:elem,this);},attr:function(name,value,type){var options=name; -if (typeof name=== -"string" -) -if (value===undefined) -return this[0]&&jQuery[ type|| -"attr" -](this[0],name);else {options={};options[ name ]=value;} -return this.each(function(i){ -for (name in options) -jQuery.attr(type?this.style:this,name,jQuery.prop(this,options[ name ],type,i,name));});},css:function(key,value){ -if ((key== -'width' -||key== -'height' -)&&parseFloat(value)<0) -value=undefined;return this.attr(key,value, -"curCSS" -);},text:function(text){if (typeof text !== -"object" -&&text !=null) -return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(text));var ret= -"" -;jQuery.each(text||this,function(){jQuery.each(this.childNodes,function(){if (this.nodeType !=8) -ret+=this.nodeType !=1?this.nodeValue:jQuery.fn.text([ this ]);});});return ret;},wrapAll:function(html){if (this[0]){ -var wrap=jQuery(html,this[0].ownerDocument).clone();if (this[0].parentNode) -wrap.insertBefore(this[0]);wrap.map(function(){var elem=this;while (elem.firstChild) -elem=elem.firstChild;return elem;}).append(this);} -return this;},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html);});},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html);});},append:function(){return this.domManip(arguments,true,function(elem){if (this.nodeType==1) -this.appendChild(elem);});},prepend:function(){return this.domManip(arguments,true,function(elem){if (this.nodeType==1) -this.insertBefore(elem,this.firstChild);});},before:function(){return this.domManip(arguments,false,function(elem){this.parentNode.insertBefore(elem,this);});},after:function(){return this.domManip(arguments,false,function(elem){this.parentNode.insertBefore(elem,this.nextSibling);});},end:function(){return this.prevObject||jQuery([]);}, -push:[].push,sort:[].sort,splice:[].splice,find:function(selector){if (this.length===1){var ret=this.pushStack([], -"find" -,selector);ret.length=0;jQuery.find(selector,this[0],ret);return ret;} else {return this.pushStack(jQuery.unique(jQuery.map(this,function(elem){return jQuery.find(selector,elem);})), -"find" -,selector);}},clone:function(events){ -var ret=this.map(function(){if (!jQuery.support.noCloneEvent&&!jQuery.isXMLDoc(this)){ -var html=this.outerHTML;if (!html){var div=this.ownerDocument.createElement( -"div" -);div.appendChild(this.cloneNode(true));html=div.innerHTML;} -return jQuery.clean([html.replace( -/ jQuery\d+="(?:\d+|null)"/g, -"" -).replace( -/^\s*/, -"" -)])[0];} else -return this.cloneNode(true);}); -if (events===true){var orig=this.find( -"*" -).andSelf(),i=0;ret.find( -"*" -).andSelf().each(function(){if (this.nodeName !==orig[i].nodeName) -return;var events=jQuery.data(orig[i], -"events" -);for (var type in events){for (var handler in events[ type ]){jQuery.event.add(this,type,events[ type ][ handler ],events[ type ][ handler ].data);}} -i++;});} -return ret;},filter:function(selector){return this.pushStack(jQuery.isFunction(selector)&&jQuery.grep(this,function(elem,i){return selector.call(elem,i);})||jQuery.multiFilter(selector,jQuery.grep(this,function(elem){return elem.nodeType===1;})), -"filter" -,selector);},closest:function(selector){var pos=jQuery.expr.match.POS.test(selector)?jQuery(selector):null,closer=0;return this.map(function(){var cur=this;while (cur&&cur.ownerDocument){if (pos?pos.index(cur)>-1:jQuery(cur).is(selector)){jQuery.data(cur, -"closest" -,closer);return cur;} -cur=cur.parentNode;closer++;}});},not:function(selector){if (typeof selector=== -"string" -) -if (isSimple.test(selector)) -return this.pushStack(jQuery.multiFilter(selector,this,true), -"not" -,selector);else -selector=jQuery.multiFilter(selector,this);var isArrayLike=selector.length&&selector[selector.length-1] !==undefined&&!selector.nodeType;return this.filter(function(){return isArrayLike?jQuery.inArray(this,selector)<0:this !=selector;});},add:function(selector){return this.pushStack(jQuery.unique(jQuery.merge(this.get(),typeof selector=== -"string" -?jQuery(selector):jQuery.makeArray(selector))));},is:function(selector){return !!selector&&jQuery.multiFilter(selector,this).length>0;},hasClass:function(selector){return !!selector&&this.is( -"." -+selector);},val:function(value){if (value===undefined){var elem=this[0];if (elem){if(jQuery.nodeName(elem, -'option' -)) -return (elem.attributes.value||{}).specified?elem.value:elem.text; -if (jQuery.nodeName(elem, -"select" -)){var index=elem.selectedIndex,values=[],options=elem.options,one=elem.type== -"select-one" -; -if (index<0) -return null; -for (var i=one?index:0,max=one?index+1:options.length;i<max;i++){var option=options[ i ];if (option.selected){ -value=jQuery(option).val(); -if (one) -return value; -values.push(value);}} -return values;} -return (elem.value|| -"" -).replace( -/\r/g, -"" -);} -return undefined;} -if (typeof value=== -"number" -) -value+= -'' -;return this.each(function(){if (this.nodeType !=1) -return;if (jQuery.isArray(value)&& -/radio|checkbox/.test(this.type)) -this.checked=(jQuery.inArray(this.value,value)>=0||jQuery.inArray(this.name,value)>=0);else if (jQuery.nodeName(this, -"select" -)){var values=jQuery.makeArray(value);jQuery( -"option" -,this).each(function(){this.selected=(jQuery.inArray(this.value,values)>=0||jQuery.inArray(this.text,values)>=0);});if (!values.length) -this.selectedIndex=-1;} else -this.value=value;});},html:function(value){return value===undefined?(this[0]?this[0].innerHTML.replace( -/ jQuery\d+="(?:\d+|null)"/g, -"" -):null):this.empty().append(value);},replaceWith:function(value){return this.after(value).remove();},eq:function(i){return this.slice(i,+i+1);},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments), -"slice" -,Array.prototype.slice.call(arguments).join( -"," -));},map:function(callback){return this.pushStack(jQuery.map(this,function(elem,i){return callback.call(elem,i,elem);}));},andSelf:function(){return this.add(this.prevObject);},domManip:function(args,table,callback){if (this[0]){var fragment=(this[0].ownerDocument||this[0]).createDocumentFragment(),scripts=jQuery.clean(args,(this[0].ownerDocument||this[0]),fragment),first=fragment.firstChild;if (first) -for (var i=0,l=this.length;i<l;i++) -callback.call(root(this[i],first),this.length>1||i>0?fragment.cloneNode(true):fragment);if (scripts) -jQuery.each(scripts,evalScript);} -return this;function root(elem,cur){return table&&jQuery.nodeName(elem, -"table" -)&&jQuery.nodeName(cur, -"tr" -)?(elem.getElementsByTagName( -"tbody" -)[0]||elem.appendChild(elem.ownerDocument.createElement( -"tbody" -))):elem;}}}; -jQuery.fn.init.prototype=jQuery.fn;function evalScript(i,elem){if (elem.src) -jQuery.ajax({url:elem.src,async:false,dataType: -"script" -});else -jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML|| -"" -);if (elem.parentNode) -elem.parentNode.removeChild(elem);} -function now(){return+new Date;} -jQuery.extend=jQuery.fn.extend=function(){ -var target=arguments[0]||{},i=1,length=arguments.length,deep=false,options; -if (typeof target=== -"boolean" -){deep=target;target=arguments[1]||{}; -i=2;} -if (typeof target !== -"object" -&&!jQuery.isFunction(target)) -target={}; -if (length==i){target=this;--i;} -for (;i<length;i++) -if ((options=arguments[ i ]) !=null) -for (var name in options){var src=target[ name ],copy=options[ name ]; -if (target===copy) -continue; -if (deep&©&&typeof copy=== -"object" -&&!copy.nodeType) -target[ name ]=jQuery.extend(deep, -src||(copy.length !=null?[ ]:{}),copy); -else if (copy !==undefined) -target[ name ]=copy;} -return target;}; -var exclude= -/z-?index|font-?weight|opacity|zoom|line-?height/i, -defaultView=document.defaultView||{},toString=Object.prototype.toString;jQuery.extend({noConflict:function(deep){window.$=_$;if (deep) -window.jQuery=_jQuery;return jQuery;}, -isFunction:function(obj){return toString.call(obj)=== -"[object Function]" -;},isArray:function(obj){return toString.call(obj)=== -"[object Array]" -;}, -isXMLDoc:function(elem){return elem.nodeType===9&&elem.documentElement.nodeName !== -"HTML" -||!!elem.ownerDocument&&jQuery.isXMLDoc(elem.ownerDocument);}, -globalEval:function(data){if (data&& -/\S/.test(data)){ -var head=document.getElementsByTagName( -"head" -)[0]||document.documentElement,script=document.createElement( -"script" -);script.type= -"text/javascript" -;if (jQuery.support.scriptEval) -script.appendChild(document.createTextNode(data));else -script.text=data; -head.insertBefore(script,head.firstChild);head.removeChild(script);}},nodeName:function(elem,name){return elem.nodeName&&elem.nodeName.toUpperCase()==name.toUpperCase();}, -each:function(object,callback,args){var name,i=0,length=object.length;if (args){if (length===undefined){for (name in object) -if (callback.apply(object[ name ],args)===false) -break;} else -for (;i<length;) -if (callback.apply(object[ i++],args)===false) -break; -} else {if (length===undefined){for (name in object) -if (callback.call(object[ name ],name,object[ name ])===false) -break;} else -for (var value=object[0];i<length&&callback.call(value,i,value) !==false;value=object[++i]){}} -return object;},prop:function(elem,value,type,i,name){ -if (jQuery.isFunction(value)) -value=value.call(elem,i); -return typeof value=== -"number" -&&type== -"curCSS" -&&!exclude.test(name)?value+ -"px" -:value;},className:{ -add:function(elem,classNames){jQuery.each((classNames|| -"" -).split( -/\s+/),function(i,className){if (elem.nodeType==1&&!jQuery.className.has(elem.className,className)) -elem.className+=(elem.className? -" " -: -"" -)+className;});}, -remove:function(elem,classNames){if (elem.nodeType==1) -elem.className=classNames !==undefined?jQuery.grep(elem.className.split( -/\s+/),function(className){return !jQuery.className.has(classNames,className);}).join( -" " -): -"" -;}, -has:function(elem,className){return elem&&jQuery.inArray(className,(elem.className||elem).toString().split( -/\s+/))>-1;}}, -swap:function(elem,options,callback){var old={}; -for (var name in options){old[ name ]=elem.style[ name ];elem.style[ name ]=options[ name ];} -callback.call(elem); -for (var name in options) -elem.style[ name ]=old[ name ];},css:function(elem,name,force,extra){if (name== -"width" -||name== -"height" -){var val,props={position: -"absolute" -,visibility: -"hidden" -,display: -"block" -},which=name== -"width" -?[ -"Left" -, -"Right" -]:[ -"Top" -, -"Bottom" -];function getWH(){val=name== -"width" -?elem.offsetWidth:elem.offsetHeight;if (extra=== -"border" -) -return;jQuery.each(which,function(){if (!extra) -val-=parseFloat(jQuery.curCSS(elem, -"padding" -+this,true))||0;if (extra=== -"margin" -) -val+=parseFloat(jQuery.curCSS(elem, -"margin" -+this,true))||0;else -val-=parseFloat(jQuery.curCSS(elem, -"border" -+this+ -"Width" -,true))||0;});} -if (elem.offsetWidth !==0) -getWH();else -jQuery.swap(elem,props,getWH);return Math.max(0,Math.round(val));} -return jQuery.curCSS(elem,name,force);},curCSS:function(elem,name,force){var ret,style=elem.style; -if (name== -"opacity" -&&!jQuery.support.opacity){ret=jQuery.attr(style, -"opacity" -);return ret== -"" -? -"1" -:ret;} -if (name.match( -/float/i)) -name=styleFloat;if (!force&&style&&style[ name ]) -ret=style[ name ];else if (defaultView.getComputedStyle){ -if (name.match( -/float/i)) -name= -"float" -;name=name.replace( -/([A-Z])/g, -"-$1" -).toLowerCase();var computedStyle=defaultView.getComputedStyle(elem,null);if (computedStyle) -ret=computedStyle.getPropertyValue(name); -if (name== -"opacity" -&&ret== -"" -) -ret= -"1" -;} else if (elem.currentStyle){var camelCase=name.replace( -/\-(\w)/g,function(all,letter){return letter.toUpperCase();});ret=elem.currentStyle[ name ]||elem.currentStyle[ camelCase ]; -if (! -/^\d+(px)?$/i.test(ret)&& -/^\d/.test(ret)){ -var left=style.left,rsLeft=elem.runtimeStyle.left; -elem.runtimeStyle.left=elem.currentStyle.left;style.left=ret||0;ret=style.pixelLeft+ -"px" -; -style.left=left;elem.runtimeStyle.left=rsLeft;}} -return ret;},clean:function(elems,context,fragment){context=context||document; -if (typeof context.createElement=== -"undefined" -) -context=context.ownerDocument||context[0]&&context[0].ownerDocument||document; -if (!fragment&&elems.length===1&&typeof elems[0]=== -"string" -){var match= -/^<(\w+)\s*\/?>$/.exec(elems[0]);if (match) -return [ context.createElement(match[1]) ];} -var ret=[],scripts=[],div=context.createElement( -"div" -);jQuery.each(elems,function(i,elem){if (typeof elem=== -"number" -) -elem+= -'' -;if (!elem) -return; -if (typeof elem=== -"string" -){ -elem=elem.replace( -/(<(\w+)[^>]*?)\/>/g,function(all,front,tag){return tag.match( -/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?all:front+ -"></" -+tag+ -">" -;}); -var tags=elem.replace( -/^\s+/, -"" -).substring(0,10).toLowerCase();var wrap= -!tags.indexOf( -"<opt" -)&&[ 1, -"<select multiple='multiple'>" -, -"</select>" -]||!tags.indexOf( -"<leg" -)&&[ 1, -"<fieldset>" -, -"</fieldset>" -]||tags.match( -/^<(thead|tbody|tfoot|colg|cap)/)&&[ 1, -"<table>" -, -"</table>" -]||!tags.indexOf( -"<tr" -)&&[ 2, -"<table><tbody>" -, -"</tbody></table>" -]|| -(!tags.indexOf( -"<td" -)||!tags.indexOf( -"<th" -))&&[ 3, -"<table><tbody><tr>" -, -"</tr></tbody></table>" -]||!tags.indexOf( -"<col" -)&&[ 2, -"<table><tbody></tbody><colgroup>" -, -"</colgroup></table>" -]|| -!jQuery.support.htmlSerialize&&[ 1, -"div<div>" -, -"</div>" -]||[ 0, -"" -, -"" -]; -div.innerHTML=wrap[1]+elem+wrap[2]; -while (wrap[0]--) -div=div.lastChild; -if (!jQuery.support.tbody){ -var hasBody= -/<tbody/i.test(elem),tbody=!tags.indexOf( -"<table" -)&&!hasBody?div.firstChild&&div.firstChild.childNodes: -wrap[1]== -"<table>" -&&!hasBody?div.childNodes:[];for (var j=tbody.length-1;j>=0;--j) -if (jQuery.nodeName(tbody[ j ], -"tbody" -)&&!tbody[ j ].childNodes.length) -tbody[ j ].parentNode.removeChild(tbody[ j ]);} -if (!jQuery.support.leadingWhitespace&& -/^\s/.test(elem)) -div.insertBefore(context.createTextNode(elem.match( -/^\s*/)[0]),div.firstChild);elem=jQuery.makeArray(div.childNodes);} -if (elem.nodeType) -ret.push(elem);else -ret=jQuery.merge(ret,elem);});if (fragment){for (var i=0;ret[i];i++){if (jQuery.nodeName(ret[i], -"script" -)&&(!ret[i].type||ret[i].type.toLowerCase()=== -"text/javascript" -)){scripts.push(ret[i].parentNode?ret[i].parentNode.removeChild(ret[i]):ret[i]);} else {if (ret[i].nodeType===1) -ret.splice.apply(ret,[i+1,0].concat(jQuery.makeArray(ret[i].getElementsByTagName( -"script" -))));fragment.appendChild(ret[i]);}} -return scripts;} -return ret;},attr:function(elem,name,value){ -if (!elem||elem.nodeType==3||elem.nodeType==8) -return undefined;var notxml=!jQuery.isXMLDoc(elem), -set=value !==undefined; -name=notxml&&jQuery.props[ name ]||name; -if (elem.tagName){ -var special= -/href|src|style/.test(name); -if (name== -"selected" -&&elem.parentNode) -elem.parentNode.selectedIndex; -if (name in elem&¬xml&&!special){if (set){ -if (name== -"type" -&&jQuery.nodeName(elem, -"input" -)&&elem.parentNode) -throw -"type property can't be changed" -;elem[ name ]=value;} -if(jQuery.nodeName(elem, -"form" -)&&elem.getAttributeNode(name)) -return elem.getAttributeNode(name).nodeValue; -if (name== -"tabIndex" -){var attributeNode=elem.getAttributeNode( -"tabIndex" -);return attributeNode&&attributeNode.specified?attributeNode.value:elem.nodeName.match( -/(button|input|object|select|textarea)/i)?0:elem.nodeName.match( -/^(a|area)$/i)&&elem.href?0:undefined;} -return elem[ name ];} -if (!jQuery.support.style&¬xml&&name== -"style" -) -return jQuery.attr(elem.style, -"cssText" -,value);if (set) -elem.setAttribute(name, -"" -+value);var attr=!jQuery.support.hrefNormalized&¬xml&&special -?elem.getAttribute(name,2):elem.getAttribute(name); -return attr===null?undefined:attr;} -if (!jQuery.support.opacity&&name== -"opacity" -){if (set){ -elem.zoom=1; -elem.filter=(elem.filter|| -"" -).replace( -/alpha\([^)]*\)/, -"" -)+(parseInt(value)+ -'' -== -"NaN" -? -"" -: -"alpha(opacity=" -+value * 100+ -")" -);} -return elem.filter&&elem.filter.indexOf( -"opacity=" -)>=0?(parseFloat(elem.filter.match( -/opacity=([^)]*)/)[1]) / 100)+ -'' -: -"" -;} -name=name.replace( -/-([a-z])/ig,function(all,letter){return letter.toUpperCase();});if (set) -elem[ name ]=value;return elem[ name ];},trim:function(text){return (text|| -"" -).replace( -/^\s+|\s+$/g, -"" -);},makeArray:function(array){var ret=[];if(array !=null){var i=array.length; -if(i==null||typeof array=== -"string" -||jQuery.isFunction(array)||array.setInterval) -ret[0]=array;else -while(i) -ret[--i]=array[i];} -return ret;},inArray:function(elem,array){for (var i=0,length=array.length;i<length;i++) -if (array[ i ]===elem) -return i;return-1;},merge:function(first,second){ -var i=0,elem,pos=first.length; -if (!jQuery.support.getAll){while ((elem=second[ i++]) !=null) -if (elem.nodeType !=8) -first[ pos++]=elem;} else -while ((elem=second[ i++]) !=null) -first[ pos++]=elem;return first;},unique:function(array){var ret=[],done={};try {for (var i=0,length=array.length;i<length;i++){var id=jQuery.data(array[ i ]);if (!done[ id ]){done[ id ]=true;ret.push(array[ i ]);}}} catch(e){ret=array;} -return ret;},grep:function(elems,callback,inv){var ret=[]; -for (var i=0,length=elems.length;i<length;i++) -if (!inv !=!callback(elems[ i ],i)) -ret.push(elems[ i ]);return ret;},map:function(elems,callback){var ret=[]; -for (var i=0,length=elems.length;i<length;i++){var value=callback(elems[ i ],i);if (value !=null) -ret[ ret.length ]=value;} -return ret.concat.apply([],ret);}}); -var userAgent=navigator.userAgent.toLowerCase(); -jQuery.browser={version:(userAgent.match( -/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[0, -'0' -])[1],safari: -/webkit/.test(userAgent),opera: -/opera/.test(userAgent),msie: -/msie/.test(userAgent)&&! -/opera/.test(userAgent),mozilla: -/mozilla/.test(userAgent)&&! -/(compatible|webkit)/.test(userAgent)};jQuery.each({parent:function(elem){return elem.parentNode;},parents:function(elem){return jQuery.dir(elem, -"parentNode" -);},next:function(elem){return jQuery.nth(elem,2, -"nextSibling" -);},prev:function(elem){return jQuery.nth(elem,2, -"previousSibling" -);},nextAll:function(elem){return jQuery.dir(elem, -"nextSibling" -);},prevAll:function(elem){return jQuery.dir(elem, -"previousSibling" -);},siblings:function(elem){return jQuery.sibling(elem.parentNode.firstChild,elem);},children:function(elem){return jQuery.sibling(elem.firstChild);},contents:function(elem){return jQuery.nodeName(elem, -"iframe" -)?elem.contentDocument||elem.contentWindow.document:jQuery.makeArray(elem.childNodes);}},function(name,fn){jQuery.fn[ name ]=function(selector){var ret=jQuery.map(this,fn);if (selector&&typeof selector== -"string" -) -ret=jQuery.multiFilter(selector,ret);return this.pushStack(jQuery.unique(ret),name,selector);};});jQuery.each({appendTo: -"append" -,prependTo: -"prepend" -,insertBefore: -"before" -,insertAfter: -"after" -,replaceAll: -"replaceWith" -},function(name,original){jQuery.fn[ name ]=function(selector){var ret=[],insert=jQuery(selector);for (var i=0,l=insert.length;i<l;i++){var elems=(i>0?this.clone(true):this).get();jQuery.fn[ original ].apply(jQuery(insert[i]),elems);ret=ret.concat(elems);} -return this.pushStack(ret,name,selector);};});jQuery.each({removeAttr:function(name){jQuery.attr(this,name, -"" -);if (this.nodeType==1) -this.removeAttribute(name);},addClass:function(classNames){jQuery.className.add(this,classNames);},removeClass:function(classNames){jQuery.className.remove(this,classNames);},toggleClass:function(classNames,state){if(typeof state !== -"boolean" -) -state=!jQuery.className.has(this,classNames);jQuery.className[ state? -"add" -: -"remove" -](this,classNames);},remove:function(selector){if (!selector||jQuery.filter(selector,[ this ]).length){ -jQuery( -"*" -,this).add([this]).each(function(){jQuery.event.remove(this);jQuery.removeData(this);});if (this.parentNode) -this.parentNode.removeChild(this);}},empty:function(){ -jQuery(this).children().remove(); -while (this.firstChild) -this.removeChild(this.firstChild);}},function(name,fn){jQuery.fn[ name ]=function(){return this.each(fn,arguments);};}); -function num(elem,prop){return elem[0]&&parseInt(jQuery.curCSS(elem[0],prop,true),10)||0;} -var expando= -"jQuery" -+now(),uuid=0,windowData={};jQuery.extend({cache:{},data:function(elem,name,data){elem=elem==window?windowData:elem;var id=elem[ expando ]; -if (!id) -id=elem[ expando ]=++uuid; -if (name&&!jQuery.cache[ id ]) -jQuery.cache[ id ]={}; -if (data !==undefined) -jQuery.cache[ id ][ name ]=data; -return name?jQuery.cache[ id ][ name ]:id;},removeData:function(elem,name){elem=elem==window?windowData:elem;var id=elem[ expando ]; -if (name){if (jQuery.cache[ id ]){ -delete jQuery.cache[ id ][ name ]; -name= -"" -;for (name in jQuery.cache[ id ]) -break;if (!name) -jQuery.removeData(elem);} -} else { -try {delete elem[ expando ];} catch(e){ -if (elem.removeAttribute) -elem.removeAttribute(expando);} -delete jQuery.cache[ id ];}},queue:function(elem,type,data){if (elem){type=(type|| -"fx" -)+ -"queue" -;var q=jQuery.data(elem,type);if (!q||jQuery.isArray(data)) -q=jQuery.data(elem,type,jQuery.makeArray(data));else if(data) -q.push(data);} -return q;},dequeue:function(elem,type){var queue=jQuery.queue(elem,type),fn=queue.shift();if(!type||type=== -"fx" -) -fn=queue[0];if(fn !==undefined) -fn.call(elem);}});jQuery.fn.extend({data:function(key,value){var parts=key.split( -"." -);parts[1]=parts[1]? -"." -+parts[1]: -"" -;if (value===undefined){var data=this.triggerHandler( -"getData" -+parts[1]+ -"!" -,[parts[0]]);if (data===undefined&&this.length) -data=jQuery.data(this[0],key);return data===undefined&&parts[1]?this.data(parts[0]):data;} else -return this.trigger( -"setData" -+parts[1]+ -"!" -,[parts[0],value]).each(function(){jQuery.data(this,key,value);});},removeData:function(key){return this.each(function(){jQuery.removeData(this,key);});},queue:function(type,data){if (typeof type !== -"string" -){data=type;type= -"fx" -;} -if (data===undefined) -return jQuery.queue(this[0],type);return this.each(function(){var queue=jQuery.queue(this,type,data);if(type== -"fx" -&&queue.length==1) -queue[0].call(this);});},dequeue:function(type){return this.each(function(){jQuery.dequeue(this,type);});}}); -(function(){var chunker= -/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,done=0,toString=Object.prototype.toString;var Sizzle=function(selector,context,results,seed){results=results||[];context=context||document;if (context.nodeType !==1&&context.nodeType !==9) -return [];if (!selector||typeof selector !== -"string" -){return results;} -var parts=[],m,set,checkSet,check,mode,extra,prune=true; -chunker.lastIndex=0;while ((m=chunker.exec(selector)) !==null){parts.push(m[1]);if (m[2]){extra=RegExp.rightContext;break;}} -if (parts.length>1&&origPOS.exec(selector)){if (parts.length===2&&Expr.relative[ parts[0] ]){set=posProcess(parts[0]+parts[1],context);} else {set=Expr.relative[ parts[0] ]?[ context ]:Sizzle(parts.shift(),context);while (parts.length){selector=parts.shift();if (Expr.relative[ selector ]) -selector+=parts.shift();set=posProcess(selector,set);}}} else {var ret=seed?{expr:parts.pop(),set:makeArray(seed)}:Sizzle.find(parts.pop(),parts.length===1&&context.parentNode?context.parentNode:context,isXML(context));set=Sizzle.filter(ret.expr,ret.set);if (parts.length>0){checkSet=makeArray(set);} else {prune=false;} -while (parts.length){var cur=parts.pop(),pop=cur;if (!Expr.relative[ cur ]){cur= -"" -;} else {pop=parts.pop();} -if (pop==null){pop=context;} -Expr.relative[ cur ](checkSet,pop,isXML(context));}} -if (!checkSet){checkSet=set;} -if (!checkSet){throw -"Syntax error, unrecognized expression: " -+(cur||selector);} -if (toString.call(checkSet)=== -"[object Array]" -){if (!prune){results.push.apply(results,checkSet);} else if (context.nodeType===1){for (var i=0;checkSet[i] !=null;i++){if (checkSet[i]&&(checkSet[i]===true||checkSet[i].nodeType===1&&contains(context,checkSet[i]))){results.push(set[i]);}}} else {for (var i=0;checkSet[i] !=null;i++){if (checkSet[i]&&checkSet[i].nodeType===1){results.push(set[i]);}}}} else {makeArray(checkSet,results);} -if (extra){Sizzle(extra,context,results,seed);if (sortOrder){hasDuplicate=false;results.sort(sortOrder);if (hasDuplicate){for (var i=1;i<results.length;i++){if (results[i]===results[i-1]){results.splice(i--,1);}}}}} -return results;};Sizzle.matches=function(expr,set){return Sizzle(expr,null,null,set);};Sizzle.find=function(expr,context,isXML){var set,match;if (!expr){return [];} -for (var i=0,l=Expr.order.length;i<l;i++){var type=Expr.order[i],match;if ((match=Expr.match[ type ].exec(expr))){var left=RegExp.leftContext;if (left.substr(left.length-1) !== -"\\" -){match[1]=(match[1]|| -"" -).replace( -/\\/g, -"" -);set=Expr.find[ type ](match,context,isXML);if (set !=null){expr=expr.replace(Expr.match[ type ], -"" -);break;}}}} -if (!set){set=context.getElementsByTagName( -"*" -);} -return {set:set,expr:expr};};Sizzle.filter=function(expr,set,inplace,not){var old=expr,result=[],curLoop=set,match,anyFound,isXMLFilter=set&&set[0]&&isXML(set[0]);while (expr&&set.length){for (var type in Expr.filter){if ((match=Expr.match[ type ].exec(expr)) !=null){var filter=Expr.filter[ type ],found,item;anyFound=false;if (curLoop==result){result=[];} -if (Expr.preFilter[ type ]){match=Expr.preFilter[ type ](match,curLoop,inplace,result,not,isXMLFilter);if (!match){anyFound=found=true;} else if (match===true){continue;}} -if (match){for (var i=0;(item=curLoop[i]) !=null;i++){if (item){found=filter(item,match,i,curLoop);var pass=not ^ !!found;if (inplace&&found !=null){if (pass){anyFound=true;} else {curLoop[i]=false;}} else if (pass){result.push(item);anyFound=true;}}}} -if (found !==undefined){if (!inplace){curLoop=result;} -expr=expr.replace(Expr.match[ type ], -"" -);if (!anyFound){return [];} -break;}}} -if (expr==old){if (anyFound==null){throw -"Syntax error, unrecognized expression: " -+expr;} else {break;}} -old=expr;} -return curLoop;};var Expr=Sizzle.selectors={order:[ -"ID" -, -"NAME" -, -"TAG" -],match:{ID: -/#((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,CLASS: -/\.((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,NAME: -/\[name=['"]*((?:[\w\u00c0-\uFFFF_-]|\\.)+)['"]*\]/,ATTR: -/\[\s*((?:[\w\u00c0-\uFFFF_-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG: -/^((?:[\w\u00c0-\uFFFF\*_-]|\\.)+)/,CHILD: -/:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,POS: -/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,PSEUDO: -/:((?:[\w\u00c0-\uFFFF_-]|\\.)+)(?:\((['"]*)((?:\([^\)]+\)|[^\2\(\)]*)+)\2\))?/},attrMap:{ -"class" -: -"className" -, -"for" -: -"htmlFor" -},attrHandle:{href:function(elem){return elem.getAttribute( -"href" -);}},relative:{ -"+" -:function(checkSet,part,isXML){var isPartStr=typeof part=== -"string" -,isTag=isPartStr&&! -/\W/.test(part),isPartStrNotTag=isPartStr&&!isTag;if (isTag&&!isXML){part=part.toUpperCase();} -for (var i=0,l=checkSet.length,elem;i<l;i++){if ((elem=checkSet[i])){while ((elem=elem.previousSibling)&&elem.nodeType !==1){} -checkSet[i]=isPartStrNotTag||elem&&elem.nodeName===part?elem||false:elem===part;}} -if (isPartStrNotTag){Sizzle.filter(part,checkSet,true);}}, -">" -:function(checkSet,part,isXML){var isPartStr=typeof part=== -"string" -;if (isPartStr&&! -/\W/.test(part)){part=isXML?part:part.toUpperCase();for (var i=0,l=checkSet.length;i<l;i++){var elem=checkSet[i];if (elem){var parent=elem.parentNode;checkSet[i]=parent.nodeName===part?parent:false;}}} else {for (var i=0,l=checkSet.length;i<l;i++){var elem=checkSet[i];if (elem){checkSet[i]=isPartStr?elem.parentNode:elem.parentNode===part;}} -if (isPartStr){Sizzle.filter(part,checkSet,true);}}}, -"" -:function(checkSet,part,isXML){var doneName=done++,checkFn=dirCheck;if (!part.match( -/\W/)){var nodeCheck=part=isXML?part:part.toUpperCase();checkFn=dirNodeCheck;} -checkFn( -"parentNode" -,part,doneName,checkSet,nodeCheck,isXML);}, -"~" -:function(checkSet,part,isXML){var doneName=done++,checkFn=dirCheck;if (typeof part=== -"string" -&&!part.match( -/\W/)){var nodeCheck=part=isXML?part:part.toUpperCase();checkFn=dirNodeCheck;} -checkFn( -"previousSibling" -,part,doneName,checkSet,nodeCheck,isXML);}},find:{ID:function(match,context,isXML){if (typeof context.getElementById !== -"undefined" -&&!isXML){var m=context.getElementById(match[1]);return m?[m]:[];}},NAME:function(match,context,isXML){if (typeof context.getElementsByName !== -"undefined" -){var ret=[],results=context.getElementsByName(match[1]);for (var i=0,l=results.length;i<l;i++){if (results[i].getAttribute( -"name" -)===match[1]){ret.push(results[i]);}} -return ret.length===0?null:ret;}},TAG:function(match,context){return context.getElementsByTagName(match[1]);}},preFilter:{CLASS:function(match,curLoop,inplace,result,not,isXML){match= -" " -+match[1].replace( -/\\/g, -"" -)+ -" " -;if (isXML){return match;} -for (var i=0,elem;(elem=curLoop[i]) !=null;i++){if (elem){if (not ^ (elem.className&&( -" " -+elem.className+ -" " -).indexOf(match)>=0)){if (!inplace) -result.push(elem);} else if (inplace){curLoop[i]=false;}}} -return false;},ID:function(match){return match[1].replace( -/\\/g, -"" -);},TAG:function(match,curLoop){for (var i=0;curLoop[i]===false;i++){} -return curLoop[i]&&isXML(curLoop[i])?match[1]:match[1].toUpperCase();},CHILD:function(match){if (match[1]== -"nth" -){ -var test= -/(-?)(\d*)n((?:\+|-)?\d*)/.exec(match[2]== -"even" -&& -"2n" -||match[2]== -"odd" -&& -"2n+1" -||! -/\D/.test(match[2])&& -"0n+" -+match[2]||match[2]); -match[2]=(test[1]+(test[2]||1))-0;match[3]=test[3]-0;} -match[0]=done++;return match;},ATTR:function(match,curLoop,inplace,result,not,isXML){var name=match[1].replace( -/\\/g, -"" -);if (!isXML&&Expr.attrMap[name]){match[1]=Expr.attrMap[name];} -if (match[2]=== -"~=" -){match[4]= -" " -+match[4]+ -" " -;} -return match;},PSEUDO:function(match,curLoop,inplace,result,not){if (match[1]=== -"not" -){ -if (match[3].match(chunker).length>1|| -/^\w/.test(match[3])){match[3]=Sizzle(match[3],null,null,curLoop);} else {var ret=Sizzle.filter(match[3],curLoop,inplace,true ^ not);if (!inplace){result.push.apply(result,ret);} -return false;}} else if (Expr.match.POS.test(match[0])||Expr.match.CHILD.test(match[0])){return true;} -return match;},POS:function(match){match.unshift(true);return match;}},filters:{enabled:function(elem){return elem.disabled===false&&elem.type !== -"hidden" -;},disabled:function(elem){return elem.disabled===true;},checked:function(elem){return elem.checked===true;},selected:function(elem){ -elem.parentNode.selectedIndex;return elem.selected===true;},parent:function(elem){return !!elem.firstChild;},empty:function(elem){return !elem.firstChild;},has:function(elem,i,match){return !!Sizzle(match[3],elem).length;},header:function(elem){return -/h\d/i.test(elem.nodeName);},text:function(elem){return -"text" -===elem.type;},radio:function(elem){return -"radio" -===elem.type;},checkbox:function(elem){return -"checkbox" -===elem.type;},file:function(elem){return -"file" -===elem.type;},password:function(elem){return -"password" -===elem.type;},submit:function(elem){return -"submit" -===elem.type;},image:function(elem){return -"image" -===elem.type;},reset:function(elem){return -"reset" -===elem.type;},button:function(elem){return -"button" -===elem.type||elem.nodeName.toUpperCase()=== -"BUTTON" -;},input:function(elem){return -/input|select|textarea|button/i.test(elem.nodeName);}},setFilters:{first:function(elem,i){return i===0;},last:function(elem,i,match,array){return i===array.length-1;},even:function(elem,i){return i%2===0;},odd:function(elem,i){return i%2===1;},lt:function(elem,i,match){return i<match[3]-0;},gt:function(elem,i,match){return i>match[3]-0;},nth:function(elem,i,match){return match[3]-0==i;},eq:function(elem,i,match){return match[3]-0==i;}},filter:{PSEUDO:function(elem,match,i,array){var name=match[1],filter=Expr.filters[ name ];if (filter){return filter(elem,i,match,array);} else if (name=== -"contains" -){return (elem.textContent||elem.innerText|| -"" -).indexOf(match[3])>=0;} else if (name=== -"not" -){var not=match[3];for (var i=0,l=not.length;i<l;i++){if (not[i]===elem){return false;}} -return true;}},CHILD:function(elem,match){var type=match[1],node=elem;switch (type){case -'only' -:case -'first' -:while (node=node.previousSibling){if (node.nodeType===1) return false;} -if (type== -'first' -) return true;node=elem;case -'last' -:while (node=node.nextSibling){if (node.nodeType===1) return false;} -return true;case -'nth' -:var first=match[2],last=match[3];if (first==1&&last==0){return true;} -var doneName=match[0],parent=elem.parentNode;if (parent&&(parent.sizcache !==doneName||!elem.nodeIndex)){var count=0;for (node=parent.firstChild;node;node=node.nextSibling){if (node.nodeType===1){node.nodeIndex=++count;}} - parent.sizcache=doneName;} -var diff=elem.nodeIndex-last;if (first==0){return diff==0;} else {return (diff%first==0&&diff / first>=0);}}},ID:function(elem,match){return elem.nodeType===1&&elem.getAttribute( -"id" -)===match;},TAG:function(elem,match){return (match=== -"*" -&&elem.nodeType===1)||elem.nodeName===match;},CLASS:function(elem,match){return ( -" " -+(elem.className||elem.getAttribute( -"class" -))+ -" " -) -.indexOf(match)>-1;},ATTR:function(elem,match){var name=match[1],result=Expr.attrHandle[ name ]?Expr.attrHandle[ name ](elem):elem[ name ] !=null?elem[ name ]:elem.getAttribute(name),value=result+ -"" -,type=match[2],check=match[4];return result==null?type=== -"!=" -:type=== -"=" -?value===check:type=== -"*=" -?value.indexOf(check)>=0:type=== -"~=" -?( -" " -+value+ -" " -).indexOf(check)>=0:!check?value&&result !==false:type=== -"!=" -?value !=check:type=== -"^=" -?value.indexOf(check)===0:type=== -"$=" -?value.substr(value.length-check.length)===check:type=== -"|=" -?value===check||value.substr(0,check.length+1)===check+ -"-" -:false;},POS:function(elem,match,i,array){var name=match[2],filter=Expr.setFilters[ name ];if (filter){return filter(elem,i,match,array);}}}};var origPOS=Expr.match.POS;for (var type in Expr.match){Expr.match[ type ]=RegExp(Expr.match[ type ].source+ -/(?![^\[]*\])(?![^\(]*\))/.source);} -var makeArray=function(array,results){array=Array.prototype.slice.call(array);if (results){results.push.apply(results,array);return results;} -return array;}; -try {Array.prototype.slice.call(document.documentElement.childNodes); -} catch(e){makeArray=function(array,results){var ret=results||[];if (toString.call(array)=== -"[object Array]" -){Array.prototype.push.apply(ret,array);} else {if (typeof array.length=== -"number" -){for (var i=0,l=array.length;i<l;i++){ret.push(array[i]);}} else {for (var i=0;array[i];i++){ret.push(array[i]);}}} -return ret;};} -var sortOrder;if (document.documentElement.compareDocumentPosition){sortOrder=function(a,b){var ret=a.compareDocumentPosition(b)&4?-1:a===b?0:1;if (ret===0){hasDuplicate=true;} -return ret;};} else if ( -"sourceIndex" -in document.documentElement){sortOrder=function(a,b){var ret=a.sourceIndex-b.sourceIndex;if (ret===0){hasDuplicate=true;} -return ret;};} else if (document.createRange){sortOrder=function(a,b){var aRange=a.ownerDocument.createRange(),bRange=b.ownerDocument.createRange();aRange.selectNode(a);aRange.collapse(true);bRange.selectNode(b);bRange.collapse(true);var ret=aRange.compareBoundaryPoints(Range.START_TO_END,bRange);if (ret===0){hasDuplicate=true;} -return ret;};} -(function(){ -var form=document.createElement( -"form" -),id= -"script" -+(new Date).getTime();form.innerHTML= -"<input name='" -+id+ -"'/>" -; -var root=document.documentElement;root.insertBefore(form,root.firstChild); -if (!!document.getElementById(id)){Expr.find.ID=function(match,context,isXML){if (typeof context.getElementById !== -"undefined" -&&!isXML){var m=context.getElementById(match[1]);return m?m.id===match[1]||typeof m.getAttributeNode !== -"undefined" -&&m.getAttributeNode( -"id" -).nodeValue===match[1]?[m]:undefined:[];}};Expr.filter.ID=function(elem,match){var node=typeof elem.getAttributeNode !== -"undefined" -&&elem.getAttributeNode( -"id" -);return elem.nodeType===1&&node&&node.nodeValue===match;};} -root.removeChild(form);})();(function(){ -var div=document.createElement( -"div" -);div.appendChild(document.createComment( -"" -)); -if (div.getElementsByTagName( -"*" -).length>0){Expr.find.TAG=function(match,context){var results=context.getElementsByTagName(match[1]); -if (match[1]=== -"*" -){var tmp=[];for (var i=0;results[i];i++){if (results[i].nodeType===1){tmp.push(results[i]);}} -results=tmp;} -return results;};} -div.innerHTML= -"<a href='#'></a>" -;if (div.firstChild&&typeof div.firstChild.getAttribute !== -"undefined" -&&div.firstChild.getAttribute( -"href" -) !== -"#" -){Expr.attrHandle.href=function(elem){return elem.getAttribute( -"href" -,2);};}})();if (document.querySelectorAll) (function(){var oldSizzle=Sizzle,div=document.createElement( -"div" -);div.innerHTML= -"<p class='TEST'></p>" -; -if (div.querySelectorAll&&div.querySelectorAll( -".TEST" -).length===0){return;} -Sizzle=function(query,context,extra,seed){context=context||document; -if (!seed&&context.nodeType===9&&!isXML(context)){try {return makeArray(context.querySelectorAll(query),extra);} catch(e){}} -return oldSizzle(query,context,extra,seed);};Sizzle.find=oldSizzle.find;Sizzle.filter=oldSizzle.filter;Sizzle.selectors=oldSizzle.selectors;Sizzle.matches=oldSizzle.matches;})();if (document.getElementsByClassName&&document.documentElement.getElementsByClassName) (function(){var div=document.createElement( -"div" -);div.innerHTML= -"<div class='test e'></div><div class='test'></div>" -; -if (div.getElementsByClassName( -"e" -).length===0) -return; -div.lastChild.className= -"e" -;if (div.getElementsByClassName( -"e" -).length===1) -return;Expr.order.splice(1,0, -"CLASS" -);Expr.find.CLASS=function(match,context,isXML){if (typeof context.getElementsByClassName !== -"undefined" -&&!isXML){return context.getElementsByClassName(match[1]);}};})();function dirNodeCheck(dir,cur,doneName,checkSet,nodeCheck,isXML){var sibDir=dir== -"previousSibling" -&&!isXML;for (var i=0,l=checkSet.length;i<l;i++){var elem=checkSet[i];if (elem){if (sibDir&&elem.nodeType===1){elem.sizcache=doneName;elem.sizset=i;} -elem=elem[dir];var match=false;while (elem){if (elem.sizcache===doneName){match=checkSet[elem.sizset];break;} -if (elem.nodeType===1&&!isXML){elem.sizcache=doneName;elem.sizset=i;} -if (elem.nodeName===cur){match=elem;break;} -elem=elem[dir];} -checkSet[i]=match;}}} -function dirCheck(dir,cur,doneName,checkSet,nodeCheck,isXML){var sibDir=dir== -"previousSibling" -&&!isXML;for (var i=0,l=checkSet.length;i<l;i++){var elem=checkSet[i];if (elem){if (sibDir&&elem.nodeType===1){elem.sizcache=doneName;elem.sizset=i;} -elem=elem[dir];var match=false;while (elem){if (elem.sizcache===doneName){match=checkSet[elem.sizset];break;} -if (elem.nodeType===1){if (!isXML){elem.sizcache=doneName;elem.sizset=i;} -if (typeof cur !== -"string" -){if (elem===cur){match=true;break;}} else if (Sizzle.filter(cur,[elem]).length>0){match=elem;break;}} -elem=elem[dir];} -checkSet[i]=match;}}} -var contains=document.compareDocumentPosition?function(a,b){return a.compareDocumentPosition(b)&16;}:function(a,b){return a !==b&&(a.contains?a.contains(b):true);};var isXML=function(elem){return elem.nodeType===9&&elem.documentElement.nodeName !== -"HTML" -||!!elem.ownerDocument&&isXML(elem.ownerDocument);};var posProcess=function(selector,context){var tmpSet=[],later= -"" -,match,root=context.nodeType?[context]:context; -while ((match=Expr.match.PSEUDO.exec(selector))){later+=match[0];selector=selector.replace(Expr.match.PSEUDO, -"" -);} -selector=Expr.relative[selector]?selector+ -"*" -:selector;for (var i=0,l=root.length;i<l;i++){Sizzle(selector,root[i],tmpSet);} -return Sizzle.filter(later,tmpSet);}; -jQuery.find=Sizzle;jQuery.filter=Sizzle.filter;jQuery.expr=Sizzle.selectors;jQuery.expr[ -":" -]=jQuery.expr.filters;Sizzle.selectors.filters.hidden=function(elem){return elem.offsetWidth===0||elem.offsetHeight===0;};Sizzle.selectors.filters.visible=function(elem){return elem.offsetWidth>0||elem.offsetHeight>0;};Sizzle.selectors.filters.animated=function(elem){return jQuery.grep(jQuery.timers,function(fn){return elem===fn.elem;}).length;};jQuery.multiFilter=function(expr,elems,not){if (not){expr= -":not(" -+expr+ -")" -;} -return Sizzle.matches(expr,elems);};jQuery.dir=function(elem,dir){var matched=[],cur=elem[dir];while (cur&&cur !=document){if (cur.nodeType==1) -matched.push(cur);cur=cur[dir];} -return matched;};jQuery.nth=function(cur,result,dir,elem){result=result||1;var num=0;for (;cur;cur=cur[dir]) -if (cur.nodeType==1&&++num==result) -break;return cur;};jQuery.sibling=function(n,elem){var r=[];for (;n;n=n.nextSibling){if (n.nodeType==1&&n !=elem) -r.push(n);} -return r;};return;window.Sizzle=Sizzle;})(); -jQuery.event={ -add:function(elem,types,handler,data){if (elem.nodeType==3||elem.nodeType==8) -return; -if (elem.setInterval&&elem !=window) -elem=window; -if (!handler.guid) -handler.guid=this.guid++; -if (data !==undefined){ -var fn=handler; -handler=this.proxy(fn); -handler.data=data;} -var events=jQuery.data(elem, -"events" -)||jQuery.data(elem, -"events" -,{}),handle=jQuery.data(elem, -"handle" -)||jQuery.data(elem, -"handle" -,function(){ -return typeof jQuery !== -"undefined" -&&!jQuery.event.triggered?jQuery.event.handle.apply(arguments.callee.elem,arguments):undefined;}); -handle.elem=elem; -jQuery.each(types.split( -/\s+/),function(index,type){ -var namespaces=type.split( -"." -);type=namespaces.shift();handler.type=namespaces.slice().sort().join( -"." -); -var handlers=events[type];if (jQuery.event.specialAll[type]) -jQuery.event.specialAll[type].setup.call(elem,data,namespaces); -if (!handlers){handlers=events[type]={}; -if (!jQuery.event.special[type]||jQuery.event.special[type].setup.call(elem,data,namespaces)===false){ -if (elem.addEventListener) -elem.addEventListener(type,handle,false);else if (elem.attachEvent) -elem.attachEvent( -"on" -+type,handle);}} -handlers[handler.guid]=handler; -jQuery.event.global[type]=true;}); -elem=null;},guid:1,global:{}, -remove:function(elem,types,handler){ -if (elem.nodeType==3||elem.nodeType==8) -return;var events=jQuery.data(elem, -"events" -),ret,index;if (events){ -if (types===undefined||(typeof types=== -"string" -&&types.charAt(0)== -"." -)) -for (var type in events) -this.remove(elem,type+(types|| -"" -));else { -if (types.type){handler=types.handler;types=types.type;} -jQuery.each(types.split( -/\s+/),function(index,type){ -var namespaces=type.split( -"." -);type=namespaces.shift();var namespace=RegExp( -"(^|\\.)" -+namespaces.slice().sort().join( -".*\\." -)+ -"(\\.|$)" -);if (events[type]){ -if (handler) -delete events[type][handler.guid]; -else -for (var handle in events[type]) -if (namespace.test(events[type][handle].type)) -delete events[type][handle];if (jQuery.event.specialAll[type]) -jQuery.event.specialAll[type].teardown.call(elem,namespaces); -for (ret in events[type]) break;if (!ret){if (!jQuery.event.special[type]||jQuery.event.special[type].teardown.call(elem,namespaces)===false){if (elem.removeEventListener) -elem.removeEventListener(type,jQuery.data(elem, -"handle" -),false);else if (elem.detachEvent) -elem.detachEvent( -"on" -+type,jQuery.data(elem, -"handle" -));} -ret=null;delete events[type];}}});} -for (ret in events) break;if (!ret){var handle=jQuery.data(elem, -"handle" -);if (handle) handle.elem=null;jQuery.removeData(elem, -"events" -);jQuery.removeData(elem, -"handle" -);}}}, -trigger:function(event,data,elem,bubbling){ -var type=event.type||event;if(!bubbling){event=typeof event=== -"object" -? -event[expando]?event: -jQuery.extend(jQuery.Event(type),event): -jQuery.Event(type);if (type.indexOf( -"!" -)>=0){event.type=type=type.slice(0,-1);event.exclusive=true;} -if (!elem){ -event.stopPropagation(); -if (this.global[type]) -jQuery.each(jQuery.cache,function(){if (this.events&&this.events[type]) -jQuery.event.trigger(event,data,this.handle.elem);});} -if (!elem||elem.nodeType==3||elem.nodeType==8) -return undefined; -event.result=undefined;event.target=elem; -data=jQuery.makeArray(data);data.unshift(event);} -event.currentTarget=elem; -var handle=jQuery.data(elem, -"handle" -);if (handle) -handle.apply(elem,data); -if ((!elem[type]||(jQuery.nodeName(elem, -'a' -)&&type== -"click" -))&&elem[ -"on" -+type]&&elem[ -"on" -+type].apply(elem,data)===false) -event.result=false; -if (!bubbling&&elem[type]&&!event.isDefaultPrevented()&&!(jQuery.nodeName(elem, -'a' -)&&type== -"click" -)){this.triggered=true;try {elem[ type ](); -} catch (e){}} -this.triggered=false;if (!event.isPropagationStopped()){var parent=elem.parentNode||elem.ownerDocument;if (parent) -jQuery.event.trigger(event,data,parent,true);}},handle:function(event){ -var all,handlers;event=arguments[0]=jQuery.event.fix(event||window.event);event.currentTarget=this; -var namespaces=event.type.split( -"." -);event.type=namespaces.shift(); -all=!namespaces.length&&!event.exclusive;var namespace=RegExp( -"(^|\\.)" -+namespaces.slice().sort().join( -".*\\." -)+ -"(\\.|$)" -);handlers=(jQuery.data(this, -"events" -)||{})[event.type];for (var j in handlers){var handler=handlers[j]; -if (all||namespace.test(handler.type)){ -event.handler=handler;event.data=handler.data;var ret=handler.apply(this,arguments);if(ret !==undefined){event.result=ret;if (ret===false){event.preventDefault();event.stopPropagation();}} -if(event.isImmediatePropagationStopped()) -break;}}},props: -"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which" -.split( -" " -),fix:function(event){if (event[expando]) -return event; -var originalEvent=event;event=jQuery.Event(originalEvent);for (var i=this.props.length,prop;i;){prop=this.props[--i ];event[ prop ]=originalEvent[ prop ];} -if (!event.target) -event.target=event.srcElement||document; -if (event.target.nodeType==3) -event.target=event.target.parentNode; -if (!event.relatedTarget&&event.fromElement) -event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement; -if (event.pageX==null&&event.clientX !=null){var doc=document.documentElement,body=document.body;event.pageX=event.clientX+(doc&&doc.scrollLeft||body&&body.scrollLeft||0)-(doc.clientLeft||0);event.pageY=event.clientY+(doc&&doc.scrollTop||body&&body.scrollTop||0)-(doc.clientTop||0);} -if (!event.which&&((event.charCode||event.charCode===0)?event.charCode:event.keyCode)) -event.which=event.charCode||event.keyCode; -if (!event.metaKey&&event.ctrlKey) -event.metaKey=event.ctrlKey; -if (!event.which&&event.button) -event.which=(event.button&1?1:(event.button&2?3:(event.button&4?2:0)));return event;},proxy:function(fn,proxy){proxy=proxy||function(){return fn.apply(this,arguments);}; -proxy.guid=fn.guid=fn.guid||proxy.guid||this.guid++; -return proxy;},special:{ready:{ -setup:bindReady,teardown:function(){}}},specialAll:{live:{setup:function(selector,namespaces){jQuery.event.add(this,namespaces[0],liveHandler);},teardown:function(namespaces){if (namespaces.length){var remove=0,name=RegExp( -"(^|\\.)" -+namespaces[0]+ -"(\\.|$)" -);jQuery.each((jQuery.data(this, -"events" -).live||{}),function(){if (name.test(this.type)) -remove++;});if (remove<1) -jQuery.event.remove(this,namespaces[0],liveHandler);}}}}};jQuery.Event=function(src){ -if(!this.preventDefault) -return new jQuery.Event(src); -if(src&&src.type){this.originalEvent=src;this.type=src.type; -}else -this.type=src; -this.timeStamp=now(); -this[expando]=true;};function returnFalse(){return false;} -function returnTrue(){return true;} -jQuery.Event.prototype={preventDefault:function(){this.isDefaultPrevented=returnTrue;var e=this.originalEvent;if(!e) -return; -if (e.preventDefault) -e.preventDefault(); -e.returnValue=false;},stopPropagation:function(){this.isPropagationStopped=returnTrue;var e=this.originalEvent;if(!e) -return; -if (e.stopPropagation) -e.stopPropagation(); -e.cancelBubble=true;},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=returnTrue;this.stopPropagation();},isDefaultPrevented:returnFalse,isPropagationStopped:returnFalse,isImmediatePropagationStopped:returnFalse}; -var withinElement=function(event){ -var parent=event.relatedTarget; -while (parent&&parent !=this) -try {parent=parent.parentNode;} -catch(e){parent=this;} -if(parent !=this){ -event.type=event.data; -jQuery.event.handle.apply(this,arguments);}};jQuery.each({mouseover: -'mouseenter' -,mouseout: -'mouseleave' -},function(orig,fix){jQuery.event.special[ fix ]={setup:function(){jQuery.event.add(this,orig,withinElement,fix);},teardown:function(){jQuery.event.remove(this,orig,withinElement);}};});jQuery.fn.extend({bind:function(type,data,fn){return type== -"unload" -?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&&data);});},one:function(type,data,fn){var one=jQuery.event.proxy(fn||data,function(event){jQuery(this).unbind(event,one);return (fn||data).apply(this,arguments);});return this.each(function(){jQuery.event.add(this,type,one,fn&&data);});},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn);});},trigger:function(type,data){return this.each(function(){jQuery.event.trigger(type,data,this);});},triggerHandler:function(type,data){if(this[0]){var event=jQuery.Event(type);event.preventDefault();event.stopPropagation();jQuery.event.trigger(event,data,this[0]);return event.result;}},toggle:function(fn){ -var args=arguments,i=1; -while(i<args.length) -jQuery.event.proxy(fn,args[i++]);return this.click(jQuery.event.proxy(fn,function(event){ -this.lastToggle=(this.lastToggle||0)%i; -event.preventDefault(); -return args[ this.lastToggle++].apply(this,arguments)||false;}));},hover:function(fnOver,fnOut){return this.mouseenter(fnOver).mouseleave(fnOut);},ready:function(fn){ -bindReady(); -if (jQuery.isReady) -fn.call(document,jQuery); -else -jQuery.readyList.push(fn);return this;},live:function(type,fn){var proxy=jQuery.event.proxy(fn);proxy.guid+=this.selector+type;jQuery(document).bind(liveConvert(type,this.selector),this.selector,proxy);return this;},die:function(type,fn){jQuery(document).unbind(liveConvert(type,this.selector),fn?{guid:fn.guid+this.selector+type}:null);return this;}});function liveHandler(event){var check=RegExp( -"(^|\\.)" -+event.type+ -"(\\.|$)" -),stop=true,elems=[];jQuery.each(jQuery.data(this, -"events" -).live||[],function(i,fn){if (check.test(fn.type)){var elem=jQuery(event.target).closest(fn.data)[0];if (elem) -elems.push({elem:elem,fn:fn});}});elems.sort(function(a,b){return jQuery.data(a.elem, -"closest" -)-jQuery.data(b.elem, -"closest" -);});jQuery.each(elems,function(){if (this.fn.call(this.elem,event,this.fn.data)===false) -return (stop=false);});return stop;} -function liveConvert(type,selector){return [ -"live" -,type,selector.replace( -/\./g, -"`" -).replace( -/ /g, -"|" -)].join( -"." -);} -jQuery.extend({isReady:false,readyList:[], -ready:function(){ -if (!jQuery.isReady){ -jQuery.isReady=true; -if (jQuery.readyList){ -jQuery.each(jQuery.readyList,function(){this.call(document,jQuery);}); -jQuery.readyList=null;} -jQuery(document).triggerHandler( -"ready" -);}}});var readyBound=false;function bindReady(){if (readyBound) return;readyBound=true; -if (document.addEventListener){ -document.addEventListener( -"DOMContentLoaded" -,function(){document.removeEventListener( -"DOMContentLoaded" -,arguments.callee,false);jQuery.ready();},false); -} else if (document.attachEvent){ -document.attachEvent( -"onreadystatechange" -,function(){if (document.readyState=== -"complete" -){document.detachEvent( -"onreadystatechange" -,arguments.callee);jQuery.ready();}}); -if (document.documentElement.doScroll&&window==window.top) (function(){if (jQuery.isReady) return;try { -document.documentElement.doScroll( -"left" -);} catch(error){setTimeout(arguments.callee,0);return;} -jQuery.ready();})();} -jQuery.event.add(window, -"load" -,jQuery.ready);} -jQuery.each(( -"blur,focus,load,resize,scroll,unload,click,dblclick," -+ -"mousedown,mouseup,mousemove,mouseover,mouseout,mouseenter,mouseleave," -+ -"change,select,submit,keydown,keypress,keyup,error" -).split( -"," -),function(i,name){ -jQuery.fn[name]=function(fn){return fn?this.bind(name,fn):this.trigger(name);};}); -jQuery(window).bind( -'unload' -,function(){for (var id in jQuery.cache) -if (id !=1&&jQuery.cache[ id ].handle) -jQuery.event.remove(jQuery.cache[ id ].handle.elem);});(function(){jQuery.support={};var root=document.documentElement,script=document.createElement( -"script" -),div=document.createElement( -"div" -),id= -"script" -+(new Date).getTime();div.style.display= -"none" -;div.innerHTML= -' <link/><table></table><a href="/a" style="color:red;float:left;opacity:.5;">a</a><select><option>text</option></select><object><param/></object>' -;var all=div.getElementsByTagName( -"*" -),a=div.getElementsByTagName( -"a" -)[0]; -if (!all||!all.length||!a){return;} -jQuery.support={ -leadingWhitespace:div.firstChild.nodeType==3, -tbody:!div.getElementsByTagName( -"tbody" -).length, -objectAll:!!div.getElementsByTagName( -"object" -)[0] -.getElementsByTagName( -"*" -).length, -htmlSerialize:!!div.getElementsByTagName( -"link" -).length, -style: -/red/.test(a.getAttribute( -"style" -)), -hrefNormalized:a.getAttribute( -"href" -)=== -"/a" -, -opacity:a.style.opacity=== -"0.5" -, -cssFloat:!!a.style.cssFloat, -scriptEval:false,noCloneEvent:true,boxModel:null};script.type= -"text/javascript" -;try {script.appendChild(document.createTextNode( -"window." -+id+ -"=1;" -));} catch(e){} -root.insertBefore(script,root.firstChild); -if (window[ id ]){jQuery.support.scriptEval=true;delete window[ id ];} -root.removeChild(script);if (div.attachEvent&&div.fireEvent){div.attachEvent( -"onclick" -,function(){ -jQuery.support.noCloneEvent=false;div.detachEvent( -"onclick" -,arguments.callee);});div.cloneNode(true).fireEvent( -"onclick" -);} -jQuery(function(){var div=document.createElement( -"div" -);div.style.width=div.style.paddingLeft= -"1px" -;document.body.appendChild(div);jQuery.boxModel=jQuery.support.boxModel=div.offsetWidth===2;document.body.removeChild(div).style.display= -'none' -;});})();var styleFloat=jQuery.support.cssFloat? -"cssFloat" -: -"styleFloat" -;jQuery.props={ -"for" -: -"htmlFor" -, -"class" -: -"className" -, -"float" -:styleFloat,cssFloat:styleFloat,styleFloat:styleFloat,readonly: -"readOnly" -,maxlength: -"maxLength" -,cellspacing: -"cellSpacing" -,rowspan: -"rowSpan" -,tabindex: -"tabIndex" -};jQuery.fn.extend({ -_load:jQuery.fn.load,load:function(url,params,callback){if (typeof url !== -"string" -) -return this._load(url);var off=url.indexOf( -" " -);if (off>=0){var selector=url.slice(off,url.length);url=url.slice(0,off);} -var type= -"GET" -; -if (params) -if (jQuery.isFunction(params)){ -callback=params;params=null; -} else if(typeof params=== -"object" -){params=jQuery.param(params);type= -"POST" -;} -var self=this; -jQuery.ajax({url:url,type:type,dataType: -"html" -,data:params,complete:function(res,status){ -if (status== -"success" -||status== -"notmodified" -) -self.html(selector? -jQuery( -"<div/>" -) -.append(res.responseText.replace( -/<script(.|\s)*?\/script>/g, -"" -)) -.find(selector): -res.responseText);if(callback) -self.each(callback,[res.responseText,status,res]);}});return this;},serialize:function(){return jQuery.param(this.serializeArray());},serializeArray:function(){return this.map(function(){return this.elements?jQuery.makeArray(this.elements):this;}) -.filter(function(){return this.name&&!this.disabled&&(this.checked|| -/select|textarea/i.test(this.nodeName)|| -/text|hidden|password|search/i.test(this.type));}) -.map(function(i,elem){var val=jQuery(this).val();return val==null?null:jQuery.isArray(val)?jQuery.map(val,function(val,i){return {name:elem.name,value:val};}):{name:elem.name,value:val};}).get();}}); -jQuery.each( -"ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend" -.split( -"," -),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f);};});var jsc=now();jQuery.extend({get:function(url,data,callback,type){ -if (jQuery.isFunction(data)){callback=data;data=null;} -return jQuery.ajax({type: -"GET" -,url:url,data:data,success:callback,dataType:type});},getScript:function(url,callback){return jQuery.get(url,null,callback, -"script" -);},getJSON:function(url,data,callback){return jQuery.get(url,data,callback, -"json" -);},post:function(url,data,callback,type){if (jQuery.isFunction(data)){callback=data;data={};} -return jQuery.ajax({type: -"POST" -,url:url,data:data,success:callback,dataType:type});},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings);},ajaxSettings:{url:location.href,global:true,type: -"GET" -,contentType: -"application/x-www-form-urlencoded" -,processData:true,async:true, -xhr:function(){return window.ActiveXObject?new ActiveXObject( -"Microsoft.XMLHTTP" -):new XMLHttpRequest();},accepts:{xml: -"application/xml, text/xml" -,html: -"text/html" -,script: -"text/javascript, application/javascript" -,json: -"application/json, text/javascript" -,text: -"text/plain" -,_default: -"*/*" -}}, -lastModified:{},ajax:function(s){ -s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));var jsonp,jsre= -/=\?(&|$)/g,status,data,type=s.type.toUpperCase(); -if (s.data&&s.processData&&typeof s.data !== -"string" -) -s.data=jQuery.param(s.data); -if (s.dataType== -"jsonp" -){if (type== -"GET" -){if (!s.url.match(jsre)) -s.url+=(s.url.match( -/\?/)? -"&" -: -"?" -)+(s.jsonp|| -"callback" -)+ -"=?" -;} else if (!s.data||!s.data.match(jsre)) -s.data=(s.data?s.data+ -"&" -: -"" -)+(s.jsonp|| -"callback" -)+ -"=?" -;s.dataType= -"json" -;} -if (s.dataType== -"json" -&&(s.data&&s.data.match(jsre)||s.url.match(jsre))){jsonp= -"jsonp" -+jsc++; -if (s.data) -s.data=(s.data+ -"" -).replace(jsre, -"=" -+jsonp+ -"$1" -);s.url=s.url.replace(jsre, -"=" -+jsonp+ -"$1" -); -s.dataType= -"script" -; -window[ jsonp ]=function(tmp){data=tmp;success();complete(); -window[ jsonp ]=undefined;try{delete window[ jsonp ];} catch(e){} -if (head) -head.removeChild(script);};} -if (s.dataType== -"script" -&&s.cache==null) -s.cache=false;if (s.cache===false&&type== -"GET" -){var ts=now(); -var ret=s.url.replace( -/(\?|&)_=.*?(&|$)/, -"$1_=" -+ts+ -"$2" -); -s.url=ret+((ret==s.url)?(s.url.match( -/\?/)? -"&" -: -"?" -)+ -"_=" -+ts: -"" -);} -if (s.data&&type== -"GET" -){s.url+=(s.url.match( -/\?/)? -"&" -: -"?" -)+s.data; -s.data=null;} -if (s.global&&! jQuery.active++) -jQuery.event.trigger( -"ajaxStart" -); -var parts= -/^(\w+:)?\/\/([^\/?#]+)/.exec(s.url); -if (s.dataType== -"script" -&&type== -"GET" -&&parts&&(parts[1]&&parts[1] !=location.protocol||parts[2] !=location.host)){var head=document.getElementsByTagName( -"head" -)[0];var script=document.createElement( -"script" -);script.src=s.url;if (s.scriptCharset) -script.charset=s.scriptCharset; -if (!jsonp){var done=false; -script.onload=script.onreadystatechange=function(){if (!done&&(!this.readyState||this.readyState== -"loaded" -||this.readyState== -"complete" -)){done=true;success();complete(); -script.onload=script.onreadystatechange=null;head.removeChild(script);}};} -head.appendChild(script); -return undefined;} -var requestDone=false; -var xhr=s.xhr(); -if(s.username) -xhr.open(type,s.url,s.async,s.username,s.password);else -xhr.open(type,s.url,s.async); -try { -if (s.data) -xhr.setRequestHeader( -"Content-Type" -,s.contentType); -if (s.ifModified) -xhr.setRequestHeader( -"If-Modified-Since" -,jQuery.lastModified[s.url]|| -"Thu, 01 Jan 1970 00:00:00 GMT" -); -xhr.setRequestHeader( -"X-Requested-With" -, -"XMLHttpRequest" -); -xhr.setRequestHeader( -"Accept" -,s.dataType&&s.accepts[ s.dataType ]?s.accepts[ s.dataType ]+ -", */*" -:s.accepts._default);} catch(e){} -if (s.beforeSend&&s.beforeSend(xhr,s)===false){ -if (s.global&&!--jQuery.active) -jQuery.event.trigger( -"ajaxStop" -); -xhr.abort();return false;} -if (s.global) -jQuery.event.trigger( -"ajaxSend" -,[xhr,s]); -var onreadystatechange=function(isTimeout){ -if (xhr.readyState==0){if (ival){ -clearInterval(ival);ival=null; -if (s.global&&!--jQuery.active) -jQuery.event.trigger( -"ajaxStop" -);} -} else if (!requestDone&&xhr&&(xhr.readyState==4||isTimeout== -"timeout" -)){requestDone=true; -if (ival){clearInterval(ival);ival=null;} -status=isTimeout== -"timeout" -? -"timeout" -:!jQuery.httpSuccess(xhr)? -"error" -:s.ifModified&&jQuery.httpNotModified(xhr,s.url)? -"notmodified" -: -"success" -;if (status== -"success" -){ -try { -data=jQuery.httpData(xhr,s.dataType,s);} catch(e){status= -"parsererror" -;}} -if (status== -"success" -){ -var modRes;try {modRes=xhr.getResponseHeader( -"Last-Modified" -);} catch(e){} -if (s.ifModified&&modRes) -jQuery.lastModified[s.url]=modRes; -if (!jsonp) -success();} else -jQuery.handleError(s,xhr,status); -complete();if (isTimeout) -xhr.abort(); -if (s.async) -xhr=null;}};if (s.async){ -var ival=setInterval(onreadystatechange,13); -if (s.timeout>0) -setTimeout(function(){ -if (xhr&&!requestDone) -onreadystatechange( -"timeout" -);},s.timeout);} -try {xhr.send(s.data);} catch(e){jQuery.handleError(s,xhr,null,e);} -if (!s.async) -onreadystatechange();function success(){ -if (s.success) -s.success(data,status); -if (s.global) -jQuery.event.trigger( -"ajaxSuccess" -,[xhr,s]);} -function complete(){ -if (s.complete) -s.complete(xhr,status); -if (s.global) -jQuery.event.trigger( -"ajaxComplete" -,[xhr,s]); -if (s.global&&!--jQuery.active) -jQuery.event.trigger( -"ajaxStop" -);} -return xhr;},handleError:function(s,xhr,status,e){ -if (s.error) s.error(xhr,status,e); -if (s.global) -jQuery.event.trigger( -"ajaxError" -,[xhr,s,e]);}, -active:0, -httpSuccess:function(xhr){try { -return !xhr.status&&location.protocol== -"file:" -||(xhr.status>=200&&xhr.status<300)||xhr.status==304||xhr.status==1223;} catch(e){} -return false;}, -httpNotModified:function(xhr,url){try {var xhrRes=xhr.getResponseHeader( -"Last-Modified" -); -return xhr.status==304||xhrRes==jQuery.lastModified[url];} catch(e){} -return false;},httpData:function(xhr,type,s){var ct=xhr.getResponseHeader( -"content-type" -),xml=type== -"xml" -||!type&&ct&&ct.indexOf( -"xml" -)>=0,data=xml?xhr.responseXML:xhr.responseText;if (xml&&data.documentElement.tagName== -"parsererror" -) -throw -"parsererror" -; -if(s&&s.dataFilter) -data=s.dataFilter(data,type); -if(typeof data=== -"string" -){ -if (type== -"script" -) -jQuery.globalEval(data); -if (type== -"json" -) -data=window[ -"eval" -]( -"(" -+data+ -")" -);} -return data;}, -param:function(a){var s=[ ];function add(key,value){s[ s.length ]=encodeURIComponent(key)+ -'=' -+encodeURIComponent(value);}; -if (jQuery.isArray(a)||a.jquery) -jQuery.each(a,function(){add(this.name,this.value);}); -else -for (var j in a) -if (jQuery.isArray(a[j])) -jQuery.each(a[j],function(){add(j,this);});else -add(j,jQuery.isFunction(a[j])?a[j]():a[j]); -return s.join( -"&" -).replace( -/%20/g, -"+" -);}});var elemdisplay={},timerId,fxAttrs=[ -[ -"height" -, -"marginTop" -, -"marginBottom" -, -"paddingTop" -, -"paddingBottom" -], -[ -"width" -, -"marginLeft" -, -"marginRight" -, -"paddingLeft" -, -"paddingRight" -], -[ -"opacity" -] -];function genFx(type,num){var obj={};jQuery.each(fxAttrs.concat.apply([],fxAttrs.slice(0,num)),function(){obj[ this ]=type;});return obj;} -jQuery.fn.extend({show:function(speed,callback){if (speed){return this.animate(genFx( -"show" -,3),speed,callback);} else {for (var i=0,l=this.length;i<l;i++){var old=jQuery.data(this[i], -"olddisplay" -);this[i].style.display=old|| -"" -;if (jQuery.css(this[i], -"display" -)=== -"none" -){var tagName=this[i].tagName,display;if (elemdisplay[ tagName ]){display=elemdisplay[ tagName ];} else {var elem=jQuery( -"<" -+tagName+ -" />" -).appendTo( -"body" -);display=elem.css( -"display" -);if (display=== -"none" -) -display= -"block" -;elem.remove();elemdisplay[ tagName ]=display;} -jQuery.data(this[i], -"olddisplay" -,display);}} -for (var i=0,l=this.length;i<l;i++){this[i].style.display=jQuery.data(this[i], -"olddisplay" -)|| -"" -;} -return this;}},hide:function(speed,callback){if (speed){return this.animate(genFx( -"hide" -,3),speed,callback);} else {for (var i=0,l=this.length;i<l;i++){var old=jQuery.data(this[i], -"olddisplay" -);if (!old&&old !== -"none" -) -jQuery.data(this[i], -"olddisplay" -,jQuery.css(this[i], -"display" -));} -for (var i=0,l=this.length;i<l;i++){this[i].style.display= -"none" -;} -return this;}}, -_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){var bool=typeof fn=== -"boolean" -;return jQuery.isFunction(fn)&&jQuery.isFunction(fn2)?this._toggle.apply(this,arguments):fn==null||bool?this.each(function(){var state=bool?fn:jQuery(this).is( -":hidden" -);jQuery(this)[ state? -"show" -: -"hide" -]();}):this.animate(genFx( -"toggle" -,3),fn,fn2);},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback);},animate:function(prop,speed,easing,callback){var optall=jQuery.speed(speed,easing,callback);return this[ optall.queue===false? -"each" -: -"queue" -](function(){var opt=jQuery.extend({},optall),p,hidden=this.nodeType==1&&jQuery(this).is( -":hidden" -),self=this;for (p in prop){if (prop[p]== -"hide" -&&hidden||prop[p]== -"show" -&&!hidden) -return opt.complete.call(this);if ((p== -"height" -||p== -"width" -)&&this.style){ -opt.display=jQuery.css(this, -"display" -); -opt.overflow=this.style.overflow;}} -if (opt.overflow !=null) -this.style.overflow= -"hidden" -;opt.curAnim=jQuery.extend({},prop);jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);if ( -/toggle|show|hide/.test(val)) -e[ val== -"toggle" -?hidden? -"show" -: -"hide" -:val ](prop);else {var parts=val.toString().match( -/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;if (parts){var end=parseFloat(parts[2]),unit=parts[3]|| -"px" -; -if (unit != -"px" -){self.style[ name ]=(end||1)+unit;start=((end||1) / e.cur(true)) * start;self.style[ name ]=start+unit;} -if (parts[1]) -end=((parts[1]== -"-=" -?-1:1) * end)+start;e.custom(start,end,unit);} else -e.custom(start,val, -"" -);}}); -return true;});},stop:function(clearQueue,gotoEnd){var timers=jQuery.timers;if (clearQueue) -this.queue([]);this.each(function(){ -for (var i=timers.length-1;i>=0;i--) -if (timers[i].elem==this){if (gotoEnd) -timers[i](true);timers.splice(i,1);}}); -if (!gotoEnd) -this.dequeue();return this;}}); -jQuery.each({slideDown:genFx( -"show" -,1),slideUp:genFx( -"hide" -,1),slideToggle:genFx( -"toggle" -,1),fadeIn:{opacity: -"show" -},fadeOut:{opacity: -"hide" -}},function(name,props){jQuery.fn[ name ]=function(speed,callback){return this.animate(props,speed,callback);};});jQuery.extend({speed:function(speed,easing,fn){var opt=typeof speed=== -"object" -?speed:{complete:fn||!fn&&easing||jQuery.isFunction(speed)&&speed,duration:speed,easing:fn&&easing||easing&&!jQuery.isFunction(easing)&&easing};opt.duration=jQuery.fx.off?0:typeof opt.duration=== -"number" -?opt.duration:jQuery.fx.speeds[opt.duration]||jQuery.fx.speeds._default; -opt.old=opt.complete;opt.complete=function(){if (opt.queue !==false) -jQuery(this).dequeue();if (jQuery.isFunction(opt.old)) -opt.old.call(this);};return opt;},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff * p;},swing:function(p,n,firstNum,diff){return ((-Math.cos(p*Math.PI)/2)+0.5) * diff+firstNum;}},timers:[],fx:function(elem,options,prop){this.options=options;this.elem=elem;this.prop=prop;if (!options.orig) -options.orig={};}});jQuery.fx.prototype={ -update:function(){if (this.options.step) -this.options.step.call(this.elem,this.now,this);(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this); -if ((this.prop== -"height" -||this.prop== -"width" -)&&this.elem.style) -this.elem.style.display= -"block" -;}, -cur:function(force){if (this.elem[this.prop] !=null&&(!this.elem.style||this.elem.style[this.prop]==null)) -return this.elem[ this.prop ];var r=parseFloat(jQuery.css(this.elem,this.prop,force));return r&&r>-10000?r:parseFloat(jQuery.curCSS(this.elem,this.prop))||0;}, -custom:function(from,to,unit){this.startTime=now();this.start=from;this.end=to;this.unit=unit||this.unit|| -"px" -;this.now=this.start;this.pos=this.state=0;var self=this;function t(gotoEnd){return self.step(gotoEnd);} -t.elem=this.elem;if (t()&&jQuery.timers.push(t)&&!timerId){timerId=setInterval(function(){var timers=jQuery.timers;for (var i=0;i<timers.length;i++) -if (!timers[i]()) -timers.splice(i--,1);if (!timers.length){clearInterval(timerId);timerId=undefined;}},13);}}, -show:function(){ -this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.show=true; -this.custom(this.prop== -"width" -||this.prop== -"height" -?1:0,this.cur()); -jQuery(this.elem).show();}, -hide:function(){ -this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.hide=true; -this.custom(this.cur(),0);}, -step:function(gotoEnd){var t=now();if (gotoEnd||t>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[ this.prop ]=true;var done=true;for (var i in this.options.curAnim) -if (this.options.curAnim[i] !==true) -done=false;if (done){if (this.options.display !=null){ -this.elem.style.overflow=this.options.overflow; -this.elem.style.display=this.options.display;if (jQuery.css(this.elem, -"display" -)== -"none" -) -this.elem.style.display= -"block" -;} -if (this.options.hide) -jQuery(this.elem).hide(); -if (this.options.hide||this.options.show) -for (var p in this.options.curAnim) -jQuery.attr(this.elem.style,p,this.options.orig[p]); -this.options.complete.call(this.elem);} -return false;} else {var n=t-this.startTime;this.state=n / this.options.duration; -this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing? -"swing" -: -"linear" -)](this.state,n,0,1,this.options.duration);this.now=this.start+((this.end-this.start) * this.pos); -this.update();} -return true;}};jQuery.extend(jQuery.fx,{speeds:{slow:600,fast:200, -_default:400},step:{opacity:function(fx){jQuery.attr(fx.elem.style, -"opacity" -,fx.now);},_default:function(fx){if (fx.elem.style&&fx.elem.style[ fx.prop ] !=null) -fx.elem.style[ fx.prop ]=fx.now+fx.unit;else -fx.elem[ fx.prop ]=fx.now;}}});if (document.documentElement[ -"getBoundingClientRect" -]) -jQuery.fn.offset=function(){if (!this[0]) return {top:0,left:0};if (this[0]===this[0].ownerDocument.body) return jQuery.offset.bodyOffset(this[0]);var box=this[0].getBoundingClientRect(),doc=this[0].ownerDocument,body=doc.body,docElem=doc.documentElement,clientTop=docElem.clientTop||body.clientTop||0,clientLeft=docElem.clientLeft||body.clientLeft||0,top=box.top+(self.pageYOffset||jQuery.boxModel&&docElem.scrollTop||body.scrollTop)-clientTop,left=box.left+(self.pageXOffset||jQuery.boxModel&&docElem.scrollLeft||body.scrollLeft)-clientLeft;return {top:top,left:left};};else - jQuery.fn.offset=function(){if (!this[0]) return {top:0,left:0};if (this[0]===this[0].ownerDocument.body) return jQuery.offset.bodyOffset(this[0]);jQuery.offset.initialized||jQuery.offset.initialize();var elem=this[0],offsetParent=elem.offsetParent,prevOffsetParent=elem,doc=elem.ownerDocument,computedStyle,docElem=doc.documentElement,body=doc.body,defaultView=doc.defaultView,prevComputedStyle=defaultView.getComputedStyle(elem,null),top=elem.offsetTop,left=elem.offsetLeft;while ((elem=elem.parentNode)&&elem !==body&&elem !==docElem){computedStyle=defaultView.getComputedStyle(elem,null);top-=elem.scrollTop,left-=elem.scrollLeft;if (elem===offsetParent){top+=elem.offsetTop,left+=elem.offsetLeft;if (jQuery.offset.doesNotAddBorder&&!(jQuery.offset.doesAddBorderForTableAndCells&& -/^t(able|d|h)$/i.test(elem.tagName))) -top+=parseInt(computedStyle.borderTopWidth,10)||0,left+=parseInt(computedStyle.borderLeftWidth,10)||0;prevOffsetParent=offsetParent,offsetParent=elem.offsetParent;} -if (jQuery.offset.subtractsBorderForOverflowNotVisible&&computedStyle.overflow !== -"visible" -) -top+=parseInt(computedStyle.borderTopWidth,10)||0,left+=parseInt(computedStyle.borderLeftWidth,10)||0;prevComputedStyle=computedStyle;} -if (prevComputedStyle.position=== -"relative" -||prevComputedStyle.position=== -"static" -) -top+=body.offsetTop,left+=body.offsetLeft;if (prevComputedStyle.position=== -"fixed" -) -top+=Math.max(docElem.scrollTop,body.scrollTop),left+=Math.max(docElem.scrollLeft,body.scrollLeft);return {top:top,left:left};};jQuery.offset={initialize:function(){if (this.initialized) return;var body=document.body,container=document.createElement( -'div' -),innerDiv,checkDiv,table,td,rules,prop,bodyMarginTop=body.style.marginTop,html= -'<div style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;"><div></div></div><table style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;" cellpadding="0" cellspacing="0"><tr><td></td></tr></table>' -;rules={position: -'absolute' -,top:0,left:0,margin:0,border:0,width: -'1px' -,height: -'1px' -,visibility: -'hidden' -};for (prop in rules) container.style[prop]=rules[prop];container.innerHTML=html;body.insertBefore(container,body.firstChild);innerDiv=container.firstChild,checkDiv=innerDiv.firstChild,td=innerDiv.nextSibling.firstChild.firstChild;this.doesNotAddBorder=(checkDiv.offsetTop !==5);this.doesAddBorderForTableAndCells=(td.offsetTop===5);innerDiv.style.overflow= -'hidden' -,innerDiv.style.position= -'relative' -;this.subtractsBorderForOverflowNotVisible=(checkDiv.offsetTop===-5);body.style.marginTop= -'1px' -;this.doesNotIncludeMarginInBodyOffset=(body.offsetTop===0);body.style.marginTop=bodyMarginTop;body.removeChild(container);this.initialized=true;},bodyOffset:function(body){jQuery.offset.initialized||jQuery.offset.initialize();var top=body.offsetTop,left=body.offsetLeft;if (jQuery.offset.doesNotIncludeMarginInBodyOffset) -top+=parseInt(jQuery.curCSS(body, -'marginTop' -,true),10)||0,left+=parseInt(jQuery.curCSS(body, -'marginLeft' -,true),10)||0;return {top:top,left:left};}};jQuery.fn.extend({position:function(){var left=0,top=0,results;if (this[0]){ -var offsetParent=this.offsetParent(), -offset=this.offset(),parentOffset= -/^body|html$/i.test(offsetParent[0].tagName)?{top:0,left:0}:offsetParent.offset(); -offset.top-=num(this, -'marginTop' -);offset.left-=num(this, -'marginLeft' -); -parentOffset.top+=num(offsetParent, -'borderTopWidth' -);parentOffset.left+=num(offsetParent, -'borderLeftWidth' -); -results={top:offset.top-parentOffset.top,left:offset.left-parentOffset.left};} -return results;},offsetParent:function(){var offsetParent=this[0].offsetParent||document.body;while (offsetParent&&(! -/^body|html$/i.test(offsetParent.tagName)&&jQuery.css(offsetParent, -'position' -)== -'static' -)) -offsetParent=offsetParent.offsetParent;return jQuery(offsetParent);}}); -jQuery.each([ -'Left' -, -'Top' -],function(i,name){var method= -'scroll' -+name;jQuery.fn[ method ]=function(val){if (!this[0]) return null;return val !==undefined? -this.each(function(){this==window||this==document?window.scrollTo(!i?val:jQuery(window).scrollLeft(),i?val:jQuery(window).scrollTop()):this[ method ]=val;}): -this[0]==window||this[0]==document?self[ i? -'pageYOffset' -: -'pageXOffset' -]||jQuery.boxModel&&document.documentElement[ method ]||document.body[ method ]:this[0][ method ];};}); -jQuery.each([ -"Height" -, -"Width" -],function(i,name){var tl=i? -"Left" -: -"Top" -, -br=i? -"Right" -: -"Bottom" -, -lower=name.toLowerCase(); -jQuery.fn[ -"inner" -+name]=function(){return this[0]?jQuery.css(this[0],lower,false, -"padding" -):null;}; -jQuery.fn[ -"outer" -+name]=function(margin){return this[0]?jQuery.css(this[0],lower,false,margin? -"margin" -: -"border" -):null;};var type=name.toLowerCase();jQuery.fn[ type ]=function(size){ -return this[0]==window? -document.compatMode== -"CSS1Compat" -&&document.documentElement[ -"client" -+name ]||document.body[ -"client" -+name ]: -this[0]==document? -Math.max(document.documentElement[ -"client" -+name],document.body[ -"scroll" -+name],document.documentElement[ -"scroll" -+name],document.body[ -"offset" -+name],document.documentElement[ -"offset" -+name]): -size===undefined? -(this.length?jQuery.css(this[0],type):null): -this.css(type,typeof size=== -"string" -?size:size+ -"px" -);};});})();----------function format_date(d){return $.timeago(Date.parse(d));} -function get_json_data(uri,options){$.getJSON(uri,function(data){var list=$( -"<ul></ul>" -);for (var i=0;i<options.max;i++){switch(options.element){case -"#backtype" -:var item=backtype_entry(data.comments[i]) -break;case -"#delicious" -:var item=delicious_entry(data[i]) -break;case -"#twitter" -:var item=twitter_entry(data[i]) -break;case -"#github" -:var item=github_entry(data.commits[i],options.repo) -break;} - item.appendTo(list);} +return((r[1].length===0)?r[0]:null);};};$D.parseExact=function(s,fx){return $D.getParseFunction(fx)(s);};}());function format_date(d){return $.timeago(Date.parse(d));} +function get_json_data(uri,options){$.getJSON(uri,function(data){var list=$("<ul></ul>");for(var i=0;i<options.max;i++){var item=github_entry(data.commits[i],options.repo) +item.appendTo(list);} list.appendTo(options.element).fadeIn(1000);});} -function backtype_entry(comment){var c=$( -"<li></li>" -).addClass( -'feed-item' -);var dt=$( -"<span></span>" -).addClass( -'feed-item-date' -).html(format_date(comment.comment.date+ -" GMT" -)+ -":" -);var tx=$( -"<span>» </span>" -).addClass( -'feed-item-text' -).append($( -'<a></a>' -).attr( -'href' -,comment.comment.url).html(comment.post.title));c.append(dt);c.append(tx);return c} -function twitter_entry(tweet){var it=$( -"<li></li>" -).addClass( -'feed-item' -);var content=tweet.text -.replace( -/^h3rald:/, -'' -) -.replace( -/((http|ftp|https):\/\/[\w\-_]+(\.[\w\-_]+)+([\w\-\.,@?^=%&:/~\+#]*[\w\-\@?^=%& -/~\+#])?)/g, -'<a href="$1">$1</a>' -) -.replace( -/@([a-zA-Z1-9_]*)/g, -'<a href="http://www.twitter.com/$1">@$1</a>' -) -.replace( -/#([a-zA-Z1-9_]*)/g, -'<a href="http://www.twitter.com/search?q=%23$1">#$1</a>' -) -var dt=$( -"<span></span>" -).addClass( -'feed-item-date' -).html(format_date(tweet.created_at)+ -":" -);var tx=$( -"<span>» </span>" -).addClass( -'feed-item-text' -).html(content);it.append(dt);it.append(tx);return it} -function delicious_entry(bookmark){var it=$( -"<li></li>" -).addClass( -'feed-item' -);var content= -"<a href='" -+bookmark.u+ -"'>" -+bookmark.d+ -"</a>" -;content+= -"<br />tags: " -;var categories=Array();for (i=0;i<bookmark.t.length;i++){categories[i]= -"<a href='http://delicious.com/h3rald/" -+bookmark.t[i]+ -"'>" -+bookmark.t[i]+ -"</a>" -;} -content+=categories.join( -', ' -).replace( -/ $/, -'' -);var dt=$( -"<span></span>" -).addClass( -'feed-item-date' -).html(format_date(bookmark.dt)+ -":" -);var tx=$( -"<span>» </span>" -).addClass( -'feed-item-text' -).html(content);it.append(dt);it.append(tx);return it} -function github_entry(commit,repo){var it=$( -"<li></li>" -).addClass( -'commit-data' -);var dt=$( -"<span></span>" -).addClass( -'commit-date' -).html(format_date(commit.committed_date)+ -" · " -);var link=$( -"<span></span><br />" -).addClass( -'commit-link' -).append($( -'<a></a>' -).attr( -'href' -,commit.url).html( -"View" -));var tx=$( -"<span></span>" -).addClass( -'commit-text' -).html(commit.message -.replace( -/(closes) #(\d+)/ig, -"$1 <a href='http://github.com/h3rald/" -+repo+ -"/issues/#issue/$2'>#$2</a>" -)+ -"<br />" -);it.append(tx);it.append(dt);it.append(link);return it} -function display_opinions(max){get_json_data( -"/data/opinions.json" -,{max:max,element: -'#backtype' -})} -function display_tweets(max){get_json_data( -"/data/tweets.json" -,{max:max,element: -'#twitter' -})} -function display_bookmarks(max){get_json_data( -"/data/bookmarks.json" -,{max:max,element: -'#delicious' -})} -function display_commits(max,repo){get_json_data( -"/data/" -+repo+ -".json" -,{max:max,element: -'#github' -,repo:repo})}---------- -eval(function(p,a,c,k,e,d){e=function(c){return(c<a? -'' -:e(parseInt(c -/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^ -/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}(';(7($){$.b.2Q=7(){u B.2t(7(){9 1J=$(B).n(\'2Z\');5(1J.1c(/^3w\\([ -"\']?(.*\\.2p)[" -\ -']?\\)$/i)){1J=3t.$1;$(B).n({\'2Z\':\'45\',\'2o\':"3W:3R.4m.4d(3h=F, 3T="+($(B).n(\'41\')==\'2J-3Z\'?\'4c\':\'3N\')+", Q=\'"+1J+"\')"}).2t(7(){9 1b=$(B).n(\'1b\');5(1b!=\'2e\'&&1b!=\'2n\')$(B).n(\'1b\',\'2n\')})}})};9 A,4,16=D,s=1t 1o,1w,1v=1,1y=/\\.(3A|3Y|2p|3c|3d)(.*)?$/i;9 P=($.2q.3K&&2f($.2q.3z.2k(0,1))<8);$.b.c=7(Y){Y=$.3x({},$.b.c.2R,Y);9 2s=B;7 2h(){A=B;4=Y;2r();u D};7 2r(){5(16)u;5($.1O(4.2c)){4.2c()}4.j=[];4.h=0;5(Y.j.N>0){4.j=Y.j}t{9 O={};5(!A.1H||A.1H==\'\'){9 O={d:A.d,X:A.X};5($(A).1G("1m:1D").N){O.1a=$(A).1G("1m:1D")}4.j.2j(O)}t{9 Z=$(2s).2o("a[1H="+A.1H+"]");9 O={};3C(9 i=0;i<Z.N;i++){O={d:Z[i].d,X:Z[i].X};5($(Z[i]).1G("1m:1D").N){O.1a=$(Z[i]).1G("1m:1D")}4.j.2j(O)}3F(4.j[4.h].d!=A.d){4.h++}}}5(4.23){5(P){$(\'1U, 1Q, 1P\').n(\'1S\',\'3s\')}$("#1i").n(\'25\',4.2U).J()}1d()};7 1d(){$("#1f, #1e, #V, #G").S();9 d=4.j[4.h].d;5(d.1c(/#/)){9 U=11.3r.d.3f(\'#\')[0];U=d.3g(U,\'\');U=U.2k(U.2l(\'#\'));1k(\'<6 l="3e">\'+$(U).o()+\'</6>\',4.1I,4.1x)}t 5(d.1c(1y)){s=1t 1o;s.Q=d;5(s.3a){1K()}t{$.b.c.34();$(s).x().14(\'3b\',7(){$(".I").S();1K()})}}t 5(d.1c("17")||A.3j.2l("17")>=0){1k(\'<17 l="35" 3q="$.b.c.38()" 3o="3n\'+C.T(C.3l()*3m)+\'" 2K="0" 3E="0" Q="\'+d+\'"></17>\',4.1I,4.1x)}t{$.4p(d,7(2m){1k(\'<6 l="3L">\'+2m+\'</6>\',4.1I,4.1x)})}};7 1K(){5(4.30){9 w=$.b.c.1n();9 r=C.1M(C.1M(w[0]-36,s.g)/s.g,C.1M(w[1]-4b,s.f)/s.f);9 g=C.T(r*s.g);9 f=C.T(r*s.f)}t{9 g=s.g;9 f=s.f}1k(\'<1m 48="" l="49" Q="\'+s.Q+\'" />\',g,f)};7 2F(){5((4.j.N-1)>4.h){9 d=4.j[4.h+1].d;5(d.1c(1y)){1A=1t 1o();1A.Q=d}}5(4.h>0){9 d=4.j[4.h-1].d;5(d.1c(1y)){1A=1t 1o();1A.Q=d}}};7 1k(1j,g,f){16=F;9 L=4.2Y;5(P){$("#q")[0].1E.2u("f");$("#q")[0].1E.2u("g")}5(L>0){g+=L*2;f+=L*2;$("#q").n({\'v\':L+\'z\',\'2E\':L+\'z\',\'2i\':L+\'z\',\'y\':L+\'z\',\'g\':\'2B\',\'f\':\'2B\'});5(P){$("#q")[0].1E.2C(\'f\',\'(B.2D.4j - 20)\');$("#q")[0].1E.2C(\'g\',\'(B.2D.3S - 20)\')}}t{$("#q").n({\'v\':0,\'2E\':0,\'2i\':0,\'y\':0,\'g\':\'2z%\',\'f\':\'2z%\'})}5($("#k").1u(":19")&&g==$("#k").g()&&f==$("#k").f()){$("#q").1Z("2N",7(){$("#q").1C().1F($(1j)).21("1s",7(){1g()})});u}9 w=$.b.c.1n();9 2v=(g+36)>w[0]?w[2]:(w[2]+C.T((w[0]-g-36)/2));9 2w=(f+1z)>w[1]?w[3]:(w[3]+C.T((w[1]-f-1z)/2));9 K={\'y\':2v,\'v\':2w,\'g\':g+\'z\',\'f\':f+\'z\'};5($("#k").1u(":19")){$("#q").1Z("1s",7(){$("#q").1C();$("#k").24(K,4.2X,4.2T,7(){$("#q").1F($(1j)).21("1s",7(){1g()})})})}t{5(4.1W>0&&4.j[4.h].1a!==1L){$("#q").1C().1F($(1j));9 M=4.j[4.h].1a;9 15=$.b.c.1R(M);$("#k").n({\'y\':(15.y-18)+\'z\',\'v\':(15.v-18)+\'z\',\'g\':$(M).g(),\'f\':$(M).f()});5(4.1X){K.25=\'J\'}$("#k").24(K,4.1W,4.2W,7(){1g()})}t{$("#q").S().1C().1F($(1j)).J();$("#k").n(K).21("1s",7(){1g()})}}};7 2y(){5(4.h!=0){$("#1e, #2O").x().14("R",7(e){e.2x();4.h--;1d();u D});$("#1e").J()}5(4.h!=(4.j.N-1)){$("#1f, #2M").x().14("R",7(e){e.2x();4.h++;1d();u D});$("#1f").J()}};7 1g(){2y();2F();$(W).1B(7(e){5(e.29==27){$.b.c.1l();$(W).x("1B")}t 5(e.29==37&&4.h!=0){4.h--;1d();$(W).x("1B")}t 5(e.29==39&&4.h!=(4.j.N-1)){4.h++;1d();$(W).x("1B")}});5(4.1r){$(11).14("1N 1T",$.b.c.2g)}t{$("6#k").n("1b","2e")}5(4.2b){$("#22").R($.b.c.1l)}$("#1i, #V").14("R",$.b.c.1l);$("#V").J();5(4.j[4.h].X!==1L&&4.j[4.h].X.N>0){$(\'#G 6\').o(4.j[4.h].X);$(\'#G\').J()}5(4.23&&P){$(\'1U, 1Q, 1P\',$(\'#q\')).n(\'1S\',\'19\')}5($.1O(4.2a)){4.2a()}16=D};u B.x(\'R\').R(2h)};$.b.c.2g=7(){9 m=$.b.c.1n();$("#k").n(\'y\',(($("#k").g()+36)>m[0]?m[2]:m[2]+C.T((m[0]-$("#k").g()-36)/2)));$("#k").n(\'v\',(($("#k").f()+1z)>m[1]?m[3]:m[3]+C.T((m[1]-$("#k").f()-1z)/2)))};$.b.c.1h=7(H,2A){u 2f($.3I(H.3u?H[0]:H,2A,F))||0};$.b.c.1R=7(H){9 m=H.4g();m.v+=$.b.c.1h(H,\'3k\');m.v+=$.b.c.1h(H,\'3J\');m.y+=$.b.c.1h(H,\'3H\');m.y+=$.b.c.1h(H,\'3D\');u m};$.b.c.38=7(){$(".I").S();$("#35").J()};$.b.c.1n=7(){u[$(11).g(),$(11).f(),$(W).3i(),$(W).3p()]};$.b.c.2G=7(){5(!$("#I").1u(\':19\')){33(1w);u}$("#I > 6").n(\'v\',(1v*-40)+\'z\');1v=(1v+1)%12};$.b.c.34=7(){33(1w);9 m=$.b.c.1n();$("#I").n({\'y\':((m[0]-40)/2+m[2]),\'v\':((m[1]-40)/2+m[3])}).J();$("#I").14(\'R\',$.b.c.1l);1w=3Q($.b.c.2G,3X)};$.b.c.1l=7(){16=F;$(s).x();$("#1i, #V").x();5(4.2b){$("#22").x()}$("#V, .I, #1e, #1f, #G").S();5(4.1r){$(11).x("1N 1T")}1q=7(){$("#1i, #k").S();5(4.1r){$(11).x("1N 1T")}5(P){$(\'1U, 1Q, 1P\').n(\'1S\',\'19\')}5($.1O(4.1V)){4.1V()}16=D};5($("#k").1u(":19")!==D){5(4.26>0&&4.j[4.h].1a!==1L){9 M=4.j[4.h].1a;9 15=$.b.c.1R(M);9 K={\'y\':(15.y-18)+\'z\',\'v\':(15.v-18)+\'z\',\'g\':$(M).g(),\'f\':$(M).f()};5(4.1X){K.25=\'S\'}$("#k").31(D,F).24(K,4.26,4.2S,1q)}t{$("#k").31(D,F).1Z("2N",1q)}}t{1q()}u D};$.b.c.2V=7(){9 o=\'\';o+=\'<6 l="1i"></6>\';o+=\'<6 l="22">\';o+=\'<6 p="I" l="I"><6></6></6>\';o+=\'<6 l="k">\';o+=\'<6 l="2I">\';o+=\'<6 l="V"></6>\';o+=\'<6 l="E"><6 p="E 44"></6><6 p="E 43"></6><6 p="E 42"></6><6 p="E 3V"></6><6 p="E 3U"></6><6 p="E 3O"></6><6 p="E 3M"></6><6 p="E 3P"></6></6>\';o+=\'<a d="2P:;" l="1e"><1p p="1Y" l="2O"></1p></a><a d="2P:;" l="1f"><1p p="1Y" l="2M"></1p></a>\';o+=\'<6 l="q"></6>\';o+=\'<6 l="G"></6>\';o+=\'</6>\';o+=\'</6>\';o+=\'</6>\';$(o).2H("46");$(\'<32 4i="0" 4h="0" 4k="0"><2L><13 p="G" l="4l"></13><13 p="G" l="4o"><6></6></13><13 p="G" l="4n"></13></2L></32>\').2H(\'#G\');5(P){$("#2I").47(\'<17 p="4a" 4e="2J" 2K="0"></17>\');$("#V, .E, .G, .1Y").2Q()}};$.b.c.2R={2Y:10,30:F,1X:D,1W:0,26:0,2X:3G,2W:\'28\',2S:\'28\',2T:\'28\',1I:3B,1x:3v,23:F,2U:0.3,2b:F,1r:F,j:[],2c:2d,2a:2d,1V:2d};$(W).3y(7(){$.b.c.2V()})})(4f);' -,62,274, -'||||opts|if|div|function||var||fn|fancybox|href||height|width|itemCurrent||itemArray|fancy_outer|id|pos|css|html|class|fancy_content||imagePreloader|else|return|top||unbind|left|px|elem|this|Math|false|fancy_bg|true|fancy_title|el|fancy_loading|show|itemOpts|pad|orig_item|length|item|isIE|src|click|hide|round|target|fancy_close|document|title|settings|subGroup||window||td|bind|orig_pos|busy|iframe||visible|orig|position|match|_change_item|fancy_left|fancy_right|_finish|getNumeric|fancy_overlay|value|_set_content|close|img|getViewport|Image|span|__cleanup|centerOnScroll|normal|new|is|loadingFrame|loadingTimer|frameHeight|imageRegExp|50|objNext|keydown|empty|first|style|append|children|rel|frameWidth|image|_proceed_image|undefined|min|resize|isFunction|select|object|getPosition|visibility|scroll|embed|callbackOnClose|zoomSpeedIn|zoomOpacity|fancy_ico|fadeOut||fadeIn|fancy_wrap|overlayShow|animate|opacity|zoomSpeedOut||swing|keyCode|callbackOnShow|hideOnContentClick|callbackOnStart|null|absolute|parseInt|scrollBox|_initialize|bottom|push|substr|indexOf|data|relative|filter|png|browser|_start|matchedGroup|each|removeExpression|itemLeft|itemTop|stopPropagation|_set_navigation|100|prop|auto|setExpression|parentNode|right|_preload_neighbor_images|animateLoading|appendTo|fancy_inner|no|frameborder|tr|fancy_right_ico|fast|fancy_left_ico|javascript|fixPNG|defaults|easingOut|easingChange|overlayOpacity|build|easingIn|zoomSpeedChange|padding|backgroundImage|imageScale|stop|table|clearInterval|showLoading|fancy_frame|||showIframe||complete|load|bmp|jpeg|fancy_div|split|replace|enabled|scrollLeft|className|paddingTop|random|1000|fancy_iframe|name|scrollTop|onload|location|hidden|RegExp|jquery|355|url|extend|ready|version|jpg|425|for|borderLeftWidth|hspace|while|300|paddingLeft|curCSS|borderTopWidth|msie|fancy_ajax|fancy_bg_w|scale|fancy_bg_sw|fancy_bg_nw|setInterval|DXImageTransform|clientWidth|sizingMethod|fancy_bg_s|fancy_bg_se|progid|66|gif|repeat||backgroundRepeat|fancy_bg_e|fancy_bg_ne|fancy_bg_n|none|body|prepend|alt|fancy_img|fancy_bigIframe|60|crop|AlphaImageLoader|scrolling|jQuery|offset|cellpadding|cellspacing|clientHeight|border|fancy_title_left|Microsoft|fancy_title_right|fancy_title_main|get' -.split( -'|' -),0,{})) +function github_entry(commit,repo){var it=$("<li></li>").addClass('commit-data');var dt=$("<span></span>").addClass('commit-date').html(format_date(commit.committed_date)+" · ");var link=$("<span></span><br />").addClass('commit-link').append($('<a></a>').attr('href',commit.url).html("» VIEW"));var tx=$("<span></span>").addClass('commit-text').html(commit.message.replace(/(closes) #(\d+)/ig,"$1 <a href='http://github.com/h3rald/"+repo+"/issues/#issue/$2'>#$2</a>")+"<br />");it.append(tx);it.append(dt);it.append(link);return it} +function display_commits(max,repo) +{get_json_data("/data/"+repo+".json",{max:max,element:'#github',repo:repo})} +google.load('search','1',{nocss:1});function OnLoad(){var searchControl=new google.search.SearchControl();var draw_options=new google.search.DrawOptions();draw_options.setSearchFormRoot(document.getElementById("search_form"));var webSearch=new google.search.WebSearch();webSearch.setSiteRestriction('h3rald.com');var search_options=new google.search.SearcherOptions();search_options.setExpandMode(google.search.SearchControl.EXPAND_MODE_OPEN);searchControl.addSearcher(webSearch,search_options);searchControl.setResultSetSize(google.search.Search.LARGE_RESULTSET);searchControl.draw(document.getElementById("search_results"),draw_options);} +google.setOnLoadCallback(OnLoad);var Hyphenator=(function(window){var +supportedLang={'be':'be.js','cs':'cs.js','da':'da.js','bn':'bn.js','de':'de.js','el':'el-monoton.js','el-monoton':'el-monoton.js','el-polyton':'el-polyton.js','en':'en-us.js','en-gb':'en-gb.js','en-us':'en-us.js','es':'es.js','fi':'fi.js','fr':'fr.js','grc':'grc.js','gu':'gu.js','hi':'hi.js','hu':'hu.js','hy':'hy.js','it':'it.js','kn':'kn.js','la':'la.js','lt':'lt.js','ml':'ml.js','nl':'nl.js','or':'or.js','pa':'pa.js','pl':'pl.js','pt':'pt.js','ru':'ru.js','sl':'sl.js','sv':'sv.js','ta':'ta.js','te':'te.js','tr':'tr.js','uk':'uk.js'},languageHint=(function(){var k,r='';for(k in supportedLang){if(supportedLang.hasOwnProperty(k)){r+=k+', ';}}r=r.substring(0,r.length-2);return r;}()),prompterStrings={'be':'???? ?????? ????? ?? ???? ???? ????????? ???????????. ???? ????? ???????? ????:','cs':'Jazyk t?to internetov? str?nky nebyl automaticky rozpozn?n. Urcete pros?m jej? jazyk:','da':'Denne websides sprog kunne ikke bestemmes. Angiv venligst sprog:','de':'Die Sprache dieser Webseite konnte nicht automatisch bestimmt werden. Bitte Sprache angeben:','en':'The language of this website could not be determined automatically. Please indicate the main language:','es':'El idioma del sitio no pudo determinarse autom%E1ticamente. Por favor, indique el idioma principal:','fi':'Sivun kielt%E4 ei tunnistettu automaattisesti. M%E4%E4rit%E4 sivun p%E4%E4kieli:','fr':'La langue de ce site n%u2019a pas pu %EAtre d%E9termin%E9e automatiquement. Veuillez indiquer une langue, s.v.p.%A0:','hu':'A weboldal nyelv?t nem siker?lt automatikusan meg?llap?tani. K?rem adja meg a nyelvet:','hy':'????????? ??????????? ??? ????? ??????: ??????? ??? ???? ???????? ???????','it':'Lingua del sito sconosciuta. Indicare una lingua, per favore:','kn':'??? ???? ????????? ?????????? ????????????????. ???????? ????? ????????? ??????:','lt':'Nepavyko automati?kai nustatyti ?ios svetaines kalbos. Pra?ome ivesti kalba:','ml':'? ??%u0D2C%u0D4D%u200C?????????? ??? ???????????????%u0D28%u0D4D%u200D ??????????. ??? ????????? ??????????????:','nl':'De taal van deze website kan niet automatisch worden bepaald. Geef de hoofdtaal op:','pt':'A l?ngua deste site n?o p?de ser determinada automaticamente. Por favor indique a l?ngua principal:','ru':'???? ????? ????? ?? ????? ???? ????????? ?????????????. ?????????? ??????? ????:','sl':'Jezika te spletne strani ni bilo mogoce samodejno dolociti. Prosim navedite jezik:','sv':'Spr%E5ket p%E5 den h%E4r webbplatsen kunde inte avg%F6ras automatiskt. V%E4nligen ange:','tr':'Bu web sitesinin dili otomatik olarak tespit edilememistir. L?tfen d?k?manin dilini se?iniz%A0:','uk':'???? ????? ???-????? ?? ???? ???? ????????? ???????????. ???? ?????, ??????? ??????? ????:'},basePath=(function(){var s=document.getElementsByTagName('script'),i=0,p,src,t;while(!!(t=s[i++])){if(!t.src){continue;}src=t.src;p=src.indexOf('Hyphenator.js');if(p!==-1){return src.substring(0,p);}}return'http://hyphenator.googlecode.com/svn/trunk/';}()),isLocal=(function(){var re=false;if(window.location.href.indexOf(basePath)!==-1){re=true;}return re;}()),documentLoaded=false,documentCount=0,contextWindow=window,doFrames=false,dontHyphenate={'script':true,'code':true,'pre':true,'img':true,'br':true,'samp':true,'kbd':true,'var':true,'abbr':true,'acronym':true,'sub':true,'sup':true,'button':true,'option':true,'label':true,'textarea':true,'input':true},enableCache=true,storageType='local',storage,enableReducedPatternSet=false,enableRemoteLoading=true,displayToggleBox=false,hyphenateClass='hyphenate',dontHyphenateClass='donthyphenate',min=6,orphanControl=1,isBookmarklet=(function(){var loc=null,re=false,jsArray=document.getElementsByTagName('script'),i,l;for(i=0,l=jsArray.length;i<l;i++){if(!!jsArray[i].getAttribute('src')){loc=jsArray[i].getAttribute('src');}if(!loc){continue;}else if(loc.indexOf('Hyphenator.js?bm=true')!==-1){re=true;}}return re;}()),mainLanguage=null,elements=[],exceptions={},docLanguages={},state=0,url='(\\w*:\/\/)?((\\w*:)?(\\w*)@)?((([\\d]{1,3}\\.){3}([\\d]{1,3}))|((www\\.|[a-zA-Z]\\.)?[a-zA-Z0-9\\-\\.]+\\.([a-z]{2,4})))(:\\d*)?(\/[\\w#!:\\.?\\+=&%@!\\-]*)*',mail='[\\w-\\.]+@[\\w\\.]+',urlOrMailRE=new RegExp('('+url+')|('+mail+')','i'),zeroWidthSpace=(function(){var zws,ua=navigator.userAgent.toLowerCase();zws=String.fromCharCode(8203);if(ua.indexOf('msie 6')!==-1){zws='';}if(ua.indexOf('opera')!==-1&&ua.indexOf('version/10.00')!==-1){zws='';}return zws;}()),createElem=function(tagname,context){context=context||contextWindow;if(document.createElementNS){return context.document.createElementNS('http://www.w3.org/1999/xhtml',tagname);}else if(document.createElement){return context.document.createElement(tagname);}},onHyphenationDone=function(){},onError=function(e){window.alert("Hyphenator.js says:\n\nAn Error ocurred:\n"+e.message);},selectorFunction=function(){var tmp,el=[],i,l;if(document.getElementsByClassName){el=contextWindow.document.getElementsByClassName(hyphenateClass);}else{tmp=contextWindow.document.getElementsByTagName('*');l=tmp.length;for(i=0;i<l;i++){if(tmp[i].className.indexOf(hyphenateClass)!==-1&&tmp[i].className.indexOf(dontHyphenateClass)===-1){el.push(tmp[i]);}}}return el;},intermediateState='hidden',hyphen=String.fromCharCode(173),urlhyphen=zeroWidthSpace,safeCopy=true,Expando=(function(){var container={},name="HyphenatorExpando_"+Math.random(),uuid=0;return{getDataForElem:function(elem){return container[elem[name].id];},setDataForElem:function(elem,data){var id;if(elem[name]&&elem[name].id!==''){id=elem[name].id;}else{id=uuid++;elem[name]={'id':id};}container[id]=data;},appendDataForElem:function(elem,data){var k;for(k in data){if(data.hasOwnProperty(k)){container[elem[name].id][k]=data[k];}}},delDataOfElem:function(elem){delete container[elem[name]];}};}()),runOnContentLoaded=function(w,f){var DOMContentLoaded=function(){},toplevel,hyphRunForThis={};if(documentLoaded&&!hyphRunForThis[w.location.href]){f();hyphRunForThis[w.location.href]=true;return;}function init(context){contextWindow=context||window;if(!hyphRunForThis[contextWindow.location.href]&&(!documentLoaded||contextWindow!=window.parent)){documentLoaded=true;f();hyphRunForThis[contextWindow.location.href]=true;}}function doScrollCheck(){try{document.documentElement.doScroll("left");}catch(error){setTimeout(doScrollCheck,1);return;}init(window);}function doOnLoad(){var i,haveAccess,fl=window.frames.length;if(doFrames&&fl>0){for(i=0;i<fl;i++){haveAccess=undefined;try{haveAccess=window.frames[i].document.toString();}catch(e){haveAccess=undefined;}if(!!haveAccess){init(window.frames[i]);}}contextWindow=window;f();hyphRunForThis[window.location.href]=true;}else{init(window);}}if(document.addEventListener){DOMContentLoaded=function(){document.removeEventListener("DOMContentLoaded",DOMContentLoaded,false);if(doFrames&&window.frames.length>0){return;}else{init(window);}};}else if(document.attachEvent){DOMContentLoaded=function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",DOMContentLoaded);if(doFrames&&window.frames.length>0){return;}else{init(window);}}};}if(document.addEventListener){document.addEventListener("DOMContentLoaded",DOMContentLoaded,false);window.addEventListener("load",doOnLoad,false);}else if(document.attachEvent){document.attachEvent("onreadystatechange",DOMContentLoaded);window.attachEvent("onload",doOnLoad);toplevel=false;try{toplevel=window.frameElement===null;}catch(e){}if(document.documentElement.doScroll&&toplevel){doScrollCheck();}}},getLang=function(el,fallback){if(!!el.getAttribute('lang')){return el.getAttribute('lang').toLowerCase();}try{if(!!el.getAttribute('xml:lang')){return el.getAttribute('xml:lang').toLowerCase();}}catch(ex){}if(el.tagName!=='HTML'){return getLang(el.parentNode,true);}if(fallback){return mainLanguage;}return null;},autoSetMainLanguage=function(w){w=w||contextWindow;var el=w.document.getElementsByTagName('html')[0],m=w.document.getElementsByTagName('meta'),i,text,e,ul;mainLanguage=getLang(el,false);if(!mainLanguage){for(i=0;i<m.length;i++){if(!!m[i].getAttribute('http-equiv')&&(m[i].getAttribute('http-equiv').toLowerCase()==='content-language')){mainLanguage=m[i].getAttribute('content').toLowerCase();}if(!!m[i].getAttribute('name')&&(m[i].getAttribute('name').toLowerCase()==='dc.language')){mainLanguage=m[i].getAttribute('content').toLowerCase();}if(!!m[i].getAttribute('name')&&(m[i].getAttribute('name').toLowerCase()==='language')){mainLanguage=m[i].getAttribute('content').toLowerCase();}}}if(!mainLanguage&&doFrames&&contextWindow!=window.parent){autoSetMainLanguage(window.parent);}if(!mainLanguage){text='';ul=navigator.language?navigator.language:navigator.userLanguage;ul=ul.substring(0,2);if(prompterStrings.hasOwnProperty(ul)){text=prompterStrings[ul];}else{text=prompterStrings.en;}text+=' (ISO 639-1)\n\n'+languageHint;mainLanguage=window.prompt(unescape(text),ul).toLowerCase();}if(!supportedLang.hasOwnProperty(mainLanguage)){if(supportedLang.hasOwnProperty(mainLanguage.split('-')[0])){mainLanguage=mainLanguage.split('-')[0];}else{e=new Error('The language "'+mainLanguage+'" is not yet supported.');throw e;}}},gatherDocumentInfos=function(){var elToProcess,tmp,i=0,process=function(el,hide,lang){var n,i=0,hyphenatorSettings={};if(hide&&intermediateState==='hidden'){if(!!el.getAttribute('style')){hyphenatorSettings.hasOwnStyle=true;}else{hyphenatorSettings.hasOwnStyle=false;}hyphenatorSettings.isHidden=true;el.style.visibility='hidden';}if(el.lang&&typeof(el.lang)==='string'){hyphenatorSettings.language=el.lang.toLowerCase();}else if(lang){hyphenatorSettings.language=lang.toLowerCase();}else{hyphenatorSettings.language=getLang(el,true);}lang=hyphenatorSettings.language;if(supportedLang[lang]){docLanguages[lang]=true;}else{if(supportedLang.hasOwnProperty(lang.split('-')[0])){lang=lang.split('-')[0];hyphenatorSettings.language=lang;}else if(!isBookmarklet){onError(new Error('Language '+lang+' is not yet supported.'));}}Expando.setDataForElem(el,hyphenatorSettings);elements.push(el);while(!!(n=el.childNodes[i++])){if(n.nodeType===1&&!dontHyphenate[n.nodeName.toLowerCase()]&&n.className.indexOf(dontHyphenateClass)===-1&&!(n in elToProcess)){process(n,false,lang);}}};if(isBookmarklet){elToProcess=contextWindow.document.getElementsByTagName('body')[0];process(elToProcess,false,mainLanguage);}else{elToProcess=selectorFunction();while(!!(tmp=elToProcess[i++])){process(tmp,true,'');}}if(!Hyphenator.languages.hasOwnProperty(mainLanguage)){docLanguages[mainLanguage]=true;}else if(!Hyphenator.languages[mainLanguage].prepared){docLanguages[mainLanguage]=true;}if(elements.length>0){Expando.appendDataForElem(elements[elements.length-1],{isLast:true});}},convertPatterns=function(lang){var plen,anfang,ende,pats,pat,key,tmp={};pats=Hyphenator.languages[lang].patterns;for(plen in pats){if(pats.hasOwnProperty(plen)){plen=parseInt(plen,10);anfang=0;ende=plen;while(!!(pat=pats[plen].substring(anfang,ende))){key=pat.replace(/\d/g,'');tmp[key]=pat;anfang=ende;ende+=plen;}}}Hyphenator.languages[lang].patterns=tmp;Hyphenator.languages[lang].patternsConverted=true;},convertExceptionsToObject=function(exc){var w=exc.split(', '),r={},i,l,key;for(i=0,l=w.length;i<l;i++){key=w[i].replace(/-/g,'');if(!r.hasOwnProperty(key)){r[key]=w[i];}}return r;},loadPatterns=function(lang){var url,xhr,head,script;if(supportedLang[lang]&&!Hyphenator.languages[lang]){url=basePath+'patterns/'+supportedLang[lang];}else{return;}if(isLocal&&!isBookmarklet){xhr=null;if(typeof XMLHttpRequest!=='undefined'){xhr=new XMLHttpRequest();}if(!xhr){try{xhr=new ActiveXObject("Msxml2.XMLHTTP");}catch(e){xhr=null;}}if(xhr){xhr.open('HEAD',url,false);xhr.setRequestHeader('Cache-Control','no-cache');xhr.send(null);if(xhr.status===404){onError(new Error('Could not load\n'+url));delete docLanguages[lang];return;}}}if(createElem){head=window.document.getElementsByTagName('head').item(0);script=createElem('script',window);script.src=url;script.type='text/javascript';head.appendChild(script);}},prepareLanguagesObj=function(lang){var lo=Hyphenator.languages[lang],wrd;if(!lo.prepared){if(enableCache){lo.cache={};lo['cache']=lo.cache;}if(enableReducedPatternSet){lo.redPatSet={};}if(lo.hasOwnProperty('exceptions')){Hyphenator.addExceptions(lang,lo.exceptions);delete lo.exceptions;}if(exceptions.hasOwnProperty('global')){if(exceptions.hasOwnProperty(lang)){exceptions[lang]+=', '+exceptions.global;}else{exceptions[lang]=exceptions.global;}}if(exceptions.hasOwnProperty(lang)){lo.exceptions=convertExceptionsToObject(exceptions[lang]);delete exceptions[lang];}else{lo.exceptions={};}convertPatterns(lang);wrd='[\\w'+lo.specialChars+'@'+String.fromCharCode(173)+'-]{'+min+',}';lo.genRegExp=new RegExp('('+url+')|('+mail+')|('+wrd+')','gi');lo.prepared=true;}if(storage){try{storage.setItem('Hyphenator_'+lang,window.JSON.stringify(lo));}catch(e){}}},prepare=function(callback){var lang,languagesToLoad=0,interval,tmp1,tmp2;if(!enableRemoteLoading){for(lang in Hyphenator.languages){if(Hyphenator.languages.hasOwnProperty(lang)){prepareLanguagesObj(lang);}}state=2;callback();return;}state=1;for(lang in docLanguages){if(docLanguages.hasOwnProperty(lang)){++languagesToLoad;if(storage){if(storage.getItem('Hyphenator_'+lang)){Hyphenator.languages[lang]=window.JSON.parse(storage.getItem('Hyphenator_'+lang));if(exceptions.hasOwnProperty('global')){tmp1=convertExceptionsToObject(exceptions.global);for(tmp2 in tmp1){if(tmp1.hasOwnProperty(tmp2)){Hyphenator.languages[lang].exceptions[tmp2]=tmp1[tmp2];}}}if(exceptions.hasOwnProperty(lang)){tmp1=convertExceptionsToObject(exceptions[lang]);for(tmp2 in tmp1){if(tmp1.hasOwnProperty(tmp2)){Hyphenator.languages[lang].exceptions[tmp2]=tmp1[tmp2];}}delete exceptions[lang];}tmp1='[\\w'+Hyphenator.languages[lang].specialChars+'@'+String.fromCharCode(173)+'-]{'+min+',}';Hyphenator.languages[lang].genRegExp=new RegExp('('+url+')|('+mail+')|('+tmp1+')','gi');delete docLanguages[lang];--languagesToLoad;continue;}}loadPatterns(lang);}}if(languagesToLoad===0){state=2;callback();return;}interval=window.setInterval(function(){var finishedLoading=false,lang;for(lang in docLanguages){if(docLanguages.hasOwnProperty(lang)){if(!Hyphenator.languages[lang]){finishedLoading=false;break;}else{finishedLoading=true;delete docLanguages[lang];prepareLanguagesObj(lang);}}}if(finishedLoading){window.clearInterval(interval);state=2;callback();}},100);},toggleBox=function(s){var myBox,bdy,myIdAttribute,myTextNode,myClassAttribute;if(!!(myBox=contextWindow.document.getElementById('HyphenatorToggleBox'))){if(s){myBox.firstChild.data='Hy-phe-na-ti-on';}else{myBox.firstChild.data='Hyphenation';}}else{bdy=contextWindow.document.getElementsByTagName('body')[0];myBox=createElem('div',contextWindow);myIdAttribute=contextWindow.document.createAttribute('id');myIdAttribute.nodeValue='HyphenatorToggleBox';myClassAttribute=contextWindow.document.createAttribute('class');myClassAttribute.nodeValue=dontHyphenateClass;myTextNode=contextWindow.document.createTextNode('Hy-phe-na-ti-on');myBox.appendChild(myTextNode);myBox.setAttributeNode(myIdAttribute);myBox.setAttributeNode(myClassAttribute);myBox.onclick=Hyphenator.toggleHyphenation;myBox.style.position='absolute';myBox.style.top='0px';myBox.style.right='0px';myBox.style.margin='0';myBox.style.backgroundColor='#AAAAAA';myBox.style.color='#FFFFFF';myBox.style.font='6pt Arial';myBox.style.letterSpacing='0.2em';myBox.style.padding='3px';myBox.style.cursor='pointer';myBox.style.WebkitBorderBottomLeftRadius='4px';myBox.style.MozBorderRadiusBottomleft='4px';bdy.appendChild(myBox);}},hyphenateWord=function(lang,word){var lo=Hyphenator.languages[lang],parts,i,l,w,wl,s,hypos,p,maxwins,win,pat=false,patk,c,t,n,numb3rs,inserted,hyphenatedword,val;if(word===''){return'';}if(word.indexOf(hyphen)!==-1){return word;}if(enableCache&&lo.cache.hasOwnProperty(word)){return lo.cache[word];}if(lo.exceptions.hasOwnProperty(word)){return lo.exceptions[word].replace(/-/g,hyphen);}if(word.indexOf('-')!==-1){parts=word.split('-');for(i=0,l=parts.length;i<l;i++){parts[i]=hyphenateWord(lang,parts[i]);}return parts.join('-');}w='_'+word+'_';wl=w.length;s=w.split('');if(word.indexOf("'")!==-1){w=w.toLowerCase().replace("'","?");}else{w=w.toLowerCase();}hypos=[];numb3rs={'0':0,'1':1,'2':2,'3':3,'4':4,'5':5,'6':6,'7':7,'8':8,'9':9};n=wl-lo.shortestPattern;for(p=0;p<=n;p++){maxwins=Math.min((wl-p),lo.longestPattern);for(win=lo.shortestPattern;win<=maxwins;win++){if(lo.patterns.hasOwnProperty(patk=w.substring(p,p+win))){pat=lo.patterns[patk];if(enableReducedPatternSet){lo.redPatSet[patk]=pat;}if(typeof pat==='string'){t=0;val=[];for(i=0;i<pat.length;i++){if(!!(c=numb3rs[pat.charAt(i)])){val.push(i-t,c);t++;}}pat=lo.patterns[patk]=val;}}else{continue;}for(i=0;i<pat.length;i++){c=p-1+pat[i];if(!hypos[c]||hypos[c]<pat[i+1]){hypos[c]=pat[i+1];}i++;}}}inserted=0;for(i=lo.leftmin;i<=(word.length-lo.rightmin);i++){if(!!(hypos[i]&1)){s.splice(i+inserted+1,0,hyphen);inserted++;}}hyphenatedword=s.slice(1,-1).join('');if(enableCache){lo.cache[word]=hyphenatedword;}return hyphenatedword;},hyphenateURL=function(url){return url.replace(/([:\/\.\?#&_,;!@]+)/gi,'$&'+urlhyphen);},hyphenateElement=function(el){var hyphenatorSettings=Expando.getDataForElem(el),lang=hyphenatorSettings.language,hyphenate,n,i,controlOrphans=function(part){var h,r;switch(hyphen){case'|':h='\\|';break;case'+':h='\\+';break;case'*':h='\\*';break;default:h=hyphen;}if(orphanControl>=2){r=part.split(' ');r[1]=r[1].replace(new RegExp(h,'g'),'');r[1]=r[1].replace(new RegExp(zeroWidthSpace,'g'),'');r=r.join(' ');}if(orphanControl===3){r=r.replace(/[ ]+/g,String.fromCharCode(160));}return r;};if(Hyphenator.languages.hasOwnProperty(lang)){hyphenate=function(word){if(urlOrMailRE.test(word)){return hyphenateURL(word);}else{return hyphenateWord(lang,word);}};i=0;while(!!(n=el.childNodes[i++])){if(n.nodeType===3&&n.data.length>=min){n.data=n.data.replace(Hyphenator.languages[lang].genRegExp,hyphenate);if(orphanControl!==1){n.data=n.data.replace(/[\S]+ [\S]+$/,controlOrphans);}}}}if(hyphenatorSettings.isHidden&&intermediateState==='hidden'){el.style.visibility='visible';if(!hyphenatorSettings.hasOwnStyle){el.setAttribute('style','');el.removeAttribute('style');}else{if(el.style.removeProperty){el.style.removeProperty('visibility');}else if(el.style.removeAttribute){el.style.removeAttribute('visibility');}}}if(hyphenatorSettings.isLast){state=3;documentCount--;if(documentCount>(-1000)&&documentCount<=0){documentCount=(-2000);onHyphenationDone();}}},removeHyphenationFromElement=function(el){var h,i=0,n;switch(hyphen){case'|':h='\\|';break;case'+':h='\\+';break;case'*':h='\\*';break;default:h=hyphen;}while(!!(n=el.childNodes[i++])){if(n.nodeType===3){n.data=n.data.replace(new RegExp(h,'g'),'');n.data=n.data.replace(new RegExp(zeroWidthSpace,'g'),'');}else if(n.nodeType===1){removeHyphenationFromElement(n);}}},hyphenateDocument=function(){function bind(fun,arg){return function(){return fun(arg);};}var i=0,el;while(!!(el=elements[i++])){if(el.ownerDocument.location.href===contextWindow.location.href){window.setTimeout(bind(hyphenateElement,el),0);}}},removeHyphenationFromDocument=function(){var i=0,el;while(!!(el=elements[i++])){removeHyphenationFromElement(el);}state=4;},registerOnCopy=function(){var body=contextWindow.document.getElementsByTagName('body')[0],shadow,selection,range,rangeShadow,restore,oncopyHandler=function(e){e=e||window.event;var target=e.target||e.srcElement,currDoc=target.ownerDocument,body=currDoc.getElementsByTagName('body')[0],targetWindow='defaultView'in currDoc?currDoc.defaultView:currDoc.parentWindow;if(target.tagName&&dontHyphenate[target.tagName.toLowerCase()]){return;}shadow=currDoc.createElement('div');shadow.style.overflow='hidden';shadow.style.position='absolute';shadow.style.top='-5000px';shadow.style.height='1px';body.appendChild(shadow);if(window.getSelection){selection=targetWindow.getSelection();range=selection.getRangeAt(0);shadow.appendChild(range.cloneContents());removeHyphenationFromElement(shadow);selection.selectAllChildren(shadow);restore=function(){shadow.parentNode.removeChild(shadow);selection.addRange(range);};}else{selection=targetWindow.document.selection;range=selection.createRange();shadow.innerHTML=range.htmlText;removeHyphenationFromElement(shadow);rangeShadow=body.createTextRange();rangeShadow.moveToElementText(shadow);rangeShadow.select();restore=function(){shadow.parentNode.removeChild(shadow);if(range.text!==""){range.select();}};}window.setTimeout(restore,0);};if(!body){return;}if(window.addEventListener){body.addEventListener("copy",oncopyHandler,false);}else{body.attachEvent("oncopy",oncopyHandler);}};return{version:'X.Y.Z',languages:{},config:function(obj){var assert=function(name,type){if(typeof obj[name]===type){return true;}else{onError(new Error('Config onError: '+name+' must be of type '+type));return false;}},key;for(key in obj){if(obj.hasOwnProperty(key)){switch(key){case'classname':if(assert('classname','string')){hyphenateClass=obj[key];}break;case'donthyphenateclassname':if(assert('donthyphenateclassname','string')){dontHyphenateClass=obj[key];}break;case'minwordlength':if(assert('minwordlength','number')){min=obj[key];}break;case'hyphenchar':if(assert('hyphenchar','string')){if(obj.hyphenchar===''){obj.hyphenchar=String.fromCharCode(173);}hyphen=obj[key];}break;case'urlhyphenchar':if(obj.hasOwnProperty('urlhyphenchar')){if(assert('urlhyphenchar','string')){urlhyphen=obj[key];}}break;case'togglebox':if(assert('togglebox','function')){toggleBox=obj[key];}break;case'displaytogglebox':if(assert('displaytogglebox','boolean')){displayToggleBox=obj[key];}break;case'remoteloading':if(assert('remoteloading','boolean')){enableRemoteLoading=obj[key];}break;case'enablecache':if(assert('enablecache','boolean')){enableCache=obj[key];}break;case'enablereducedpatternset':if(assert('enablereducedpatternset','boolean')){enableReducedPatternSet=obj[key];}break;case'onhyphenationdonecallback':if(assert('onhyphenationdonecallback','function')){onHyphenationDone=obj[key];}break;case'onerrorhandler':if(assert('onerrorhandler','function')){onError=obj[key];}break;case'intermediatestate':if(assert('intermediatestate','string')){intermediateState=obj[key];}break;case'selectorfunction':if(assert('selectorfunction','function')){selectorFunction=obj[key];}break;case'safecopy':if(assert('safecopy','boolean')){safeCopy=obj[key];}break;case'doframes':if(assert('doframes','boolean')){doFrames=obj[key];}break;case'storagetype':if(assert('storagetype','string')){storageType=obj[key];}break;case'orphancontrol':if(assert('orphancontrol','number')){orphanControl=obj[key];}break;default:onError(new Error('Hyphenator.config: property '+key+' not known.'));}}}},run:function(){documentCount=0;var process=function(){try{if(contextWindow.document.getElementsByTagName('frameset').length>0){return;}documentCount++;autoSetMainLanguage(undefined);gatherDocumentInfos();prepare(hyphenateDocument);if(displayToggleBox){toggleBox(true);}if(safeCopy){registerOnCopy();}}catch(e){onError(e);}},i,haveAccess,fl=window.frames.length;try{if(storageType!=='none'&&typeof(window.localStorage)!=='undefined'&&typeof(window.sessionStorage)!=='undefined'&&typeof(window.JSON.stringify)!=='undefined'&&typeof(window.JSON.parse)!=='undefined'){switch(storageType){case'session':storage=window.sessionStorage;break;case'local':storage=window.localStorage;break;default:storage=undefined;break;}}}catch(f){}if(!documentLoaded&&!isBookmarklet){runOnContentLoaded(window,process);}if(isBookmarklet||documentLoaded){if(doFrames&&fl>0){for(i=0;i<fl;i++){haveAccess=undefined;try{haveAccess=window.frames[i].document.toString();}catch(e){haveAccess=undefined;}if(!!haveAccess){contextWindow=window.frames[i];process();}}}contextWindow=window;process();}},addExceptions:function(lang,words){if(lang===''){lang='global';}if(exceptions.hasOwnProperty(lang)){exceptions[lang]+=", "+words;}else{exceptions[lang]=words;}},hyphenate:function(target,lang){var hyphenate,n,i;if(Hyphenator.languages.hasOwnProperty(lang)){if(!Hyphenator.languages[lang].prepared){prepareLanguagesObj(lang);}hyphenate=function(word){if(urlOrMailRE.test(word)){return hyphenateURL(word);}else{return hyphenateWord(lang,word);}};if(typeof target==='string'||target.constructor===String){return target.replace(Hyphenator.languages[lang].genRegExp,hyphenate);}else if(typeof target==='object'){i=0;while(!!(n=target.childNodes[i++])){if(n.nodeType===3&&n.data.length>=min){n.data=n.data.replace(Hyphenator.languages[lang].genRegExp,hyphenate);}else if(n.nodeType===1){if(n.lang!==''){Hyphenator.hyphenate(n,n.lang);}else{Hyphenator.hyphenate(n,lang);}}}}}else{onError(new Error('Language "'+lang+'" is not loaded.'));}},getRedPatternSet:function(lang){return Hyphenator.languages[lang].redPatSet;},isBookmarklet:function(){return isBookmarklet;},getConfigFromURI:function(){var loc=null,re={},jsArray=document.getElementsByTagName('script'),i,j,l,s,gp,option;for(i=0,l=jsArray.length;i<l;i++){if(!!jsArray[i].getAttribute('src')){loc=jsArray[i].getAttribute('src');}if(!loc){continue;}else{s=loc.indexOf('Hyphenator.js?');if(s===-1){continue;}gp=loc.substring(s+14).split('&');for(j=0;j<gp.length;j++){option=gp[j].split('=');if(option[0]==='bm'){continue;}if(option[1]==='true'){re[option[0]]=true;continue;}if(option[1]==='false'){re[option[0]]=false;continue;}if(isFinite(option[1])){re[option[0]]=parseInt(option[1],10);continue;}if(option[0]==='onhyphenationdonecallback'){re[option[0]]=new Function('',option[1]);continue;}re[option[0]]=option[1];}break;}}return re;},toggleHyphenation:function(){switch(state){case 3:removeHyphenationFromDocument();toggleBox(false);break;case 4:hyphenateDocument();toggleBox(true);break;}}};}(window));Hyphenator['languages']=Hyphenator.languages;Hyphenator['config']=Hyphenator.config;Hyphenator['run']=Hyphenator.run;Hyphenator['addExceptions']=Hyphenator.addExceptions;Hyphenator['hyphenate']=Hyphenator.hyphenate;Hyphenator['getRedPatternSet']=Hyphenator.getRedPatternSet;Hyphenator['isBookmarklet']=Hyphenator.isBookmarklet;Hyphenator['getConfigFromURI']=Hyphenator.getConfigFromURI;Hyphenator['toggleHyphenation']=Hyphenator.toggleHyphenation;window['Hyphenator']=Hyphenator;if(Hyphenator.isBookmarklet()){Hyphenator.config({displaytogglebox:true,intermediatestate:'visible',doframes:true});Hyphenator.config(Hyphenator.getConfigFromURI());Hyphenator.run();}Hyphenator.languages['en-us']=Hyphenator.languages['en']={leftmin:2,rightmin:2,shortestPattern:2,longestPattern:9,specialChars:"",patterns:{3:"x1qei2e1je1f1to2tlou2w3c1tue1q4tvtw41tyo1q4tz4tcd2yd1wd1v1du1ta4eu1pas4y1droo2d1psw24sv1dod1m1fad1j1su4fdo2n4fh1fi4fm4fn1fopd42ft3fu1fy1ga2sss1ru5jd5cd1bg3bgd44uk2ok1cyo5jgl2g1m4pf4pg1gog3p1gr1soc1qgs2oi2g3w1gysk21coc5nh1bck1h1fh1h4hk1zo1ci4zms2hh1w2ch5zl2idc3c2us2igi3hi3j4ik1cab1vsa22btr1w4bp2io2ipu3u4irbk4b1j1va2ze2bf4oar1p4nz4zbi1u2iv4iy5ja1jeza1y1wk1bk3fkh4k1ikk4k1lk1mk5tk1w2ldr1mn1t2lfr1lr3j4ljl1l2lm2lp4ltn1rrh4v4yn1q1ly1maw1brg2r1fwi24ao2mhw4kr1cw5p4mkm1m1mo4wtwy4x1ar1ba2nn5mx1ex1h4mtx3i1muqu2p3wx3o4mwa1jx3p1naai2x1ua2fxx4y1ba2dn1jy1cn3fpr2y1dy1i",4:"4dryn2itni4on1inn1im_up3nik4ni4dy5giye4tyes4_ye44ab_nhe4nha4abe2n2gyn1guy1ery5eep2pe4abry3lay3lone4wne4v1nesy3chn1erne2q3neo1nenp2seps4hy2cey5lu2nedne2cyme44nk2y5at2adine2b2ne_y5ac2p1tp2ten1den1cun1cryn5dp2th4adup4twpub3ae4rxu3ayn5gaff4pue4n2au4p1ppuf4n2atag1ipu4mag1na2gon4asx3tix1t2pu2na4gya3haa3heah4la3ho_ti2a5ian2an5puspu2tnak4_th2n1kl_te4_ta4mu4u4mupmun23mum2alex4ob_sy25ynxal1i_st4y1o4xi5cxi5a4alm_si2_sh2m5sixhu4m4sh4m3r4amam2py2rabm2pixhi2yo5dr2ai4m1pmo2vmos2x2edmo2r4n1la2mor2asx3c2xas5yom4x4apxam3nme44mokrbi2nne44andy4osp4ot3noemn4omn4a4m1n4nog4m1l2angws4l1posw3shwri4wra4yp3iwom11wo2m2izrb4ow4nopo4pr2cem2isrd2iano4mig4y3pomi3awiz55mi_no4n4m1fme4v2re_wir42mes1menme2mme2gre1o2med4me_4nop4m5c4m1bwil21noureu2whi4w3ev4maprev2w1era2plpo4crfu4r4fyy5pu2maha3pu2mab2a2rn1p4npi44lyb4lya2p3nwam42l1w1lut4luplu3or1glluf4lu5a2wacltu2y3rol1tr4vv4r3guyr4rl1te4rh_nru4ar1il2sel4sc4l1rl5prl4plys4c4lovri3ar4ib4lof3lo_ar2par3q_os3ll4oll2i4as_ri1o3vokl2levoi44p1mlka35vo_ns4cas4ll1izr4iqr2is3vivl1it3lika2tan2sen2slrle42l3hlgo3l5gal5frns3mvi4p3ley_od2r2meles24athr4myle2al3drv1inldi4l2de2vilnt2il3civik4lce42l1b4lavv3ifrno4r3nua1trr2ocnt4sy4sok4syks4la2tuk4sck3ouko5ryss4a2tyau4b4klyys1tnu1akis4au3rki4pro4ek4ima2va5ki_nu4dn4umn3uokes4k1erav1irok2ke4g1keek2ed_me2aw3ikal4aws4k5agk3ab3ka_aye4ays4veg3jo4p5ba_4vedjew3n1v24ve_ja4pzar23vatizi4n1w41batba4z2b1bb2beix4o4i5w4b1d4be_rox5nym4nyp4n3za4ittr3por1r4i1ti1bel2ith2itei2su4rs2r1sars4cr2seis1p3betvag4i2sor1shbe3wr1sioad34b3hbi2bbi4d3bie3isf4ise2is_1bilr1sp5va_r5sw_le2uz4eir1ibi2tuxu3r1tiu1v2i1raze4nze4pb2l2uu4mo1biip3iz1eripe4b4louts44b1m4b3no3br3bodi4osbo4eru3aio4mi1ol4io_3booo1ce4inyin1u2insru2n2inn4inl4inkrv4e2inioch42iner3vo4indpi2np4idbt4lb4tob3trry4cry3t2in_o4elbu4ni2muim1i5saiil3v4ilnil1iil5fs1apo3er4b5w5by_bys4_in1sau4i1lazet4u2suo3ev2z1ii2go4igius1p5saw4s5bo2fi4ifti3fl4if_i3etsch2usc22ie4i2dui4dri2diid5dpi3au3ruz4ils1cuz4is4s5d4se_se4a2ce_2ici4ich3ceii1bri5bo1ceni1blse2g5seiibe43cepi2aniam4ur2li2al2i1acet4hy2scew41phy4ch_5phuhu4thu4gche2h4tyh4shur1durc44hr44h5p5sev5sexu1ra4s3fup3p2s3gph3t2sh_ho4g2h1n_he23ciau3pl4h1mci5ch2lozo4m4ciihi2vhi4p2cim2cin4phsu1peu1ouo1geu5osheu4sho4he4th1es4shwun5zun5ysi1bunu45cizo4glck3ihep5he2nh4ed1sioph2l5hazsi2rcly4zte4_ge21siscoe22cog5siu1siv5siz_ga24skes1l2s2leha4m2s1ms3ma1ogyo1h2u1ni3gus3gun2guegu4acov1gth3_eu3g4ros1n4_es3u2nez4zyum2pu1mi3som_ev2oig4cri2gov15goos4opgon2ul5v5goeu3lugob53go_2c1t4ph_g1nog1nic2te4sov4ulsgn4ag4myc4twcud5c4ufc4uipe2t3glo1gleul2igla4_eg23giz3cun5givgi4u3gir5gio1cusul4e2spagil4g1ic5gi__eb4cze41d2a5da_u1laggo44daf2dagg2gege4v1geo1gen2ged3dato1la2ge_ol2dol2i5daypek4p4eed1d42de_4gazol2tuiv3ol2vo2lys1sa2gamgaf4o2meui4n2ui2pe2cd4em4fugi4jku3fl3ufaf2tyf4to1denu4du4pe_2f3sfri2de1ps1si4f5pfos5d3eqs4sls4snfo2rss2tdes25fon4p1b_ci23payss5w2st_de1tf4l2de1v2fin4dey4d1fd4gast2idg1id2gyd1h25di_ud5dfi3au4cy_ch4pav43didu3cud1iff2fyu3crd1inst4r4f1ffev4fer11dio2fedfe4bdir2s2ty4fe_dis1on1au3ca4f5bon1c2ondd5k25far4fagpa1peys45eyc1exps4ul2dlyp4ale3whon3s3do_e1wa5doee5vud4oge1visu2msu2nub4euav4su2rp4ai6rk_d4or3dosu1atdo4v3doxp4adoo4k4swoo2padre4eus4e3upe5un2ophet5z4syc3syl4y3hoy1ads4pd4swd4syd2tho4wo3ta_du2c4etn2tabta2luac4es4wdu4g2ess4uabdu4n4duptav4st5bow1io1pr5dyn2tawe1sp2t1bop1uead1tz4et4chopy5ea4l4t1d4te_2tyle1si4esh1tee4tyat1cr4twoteg4es2c4eru1teoer1s2eroea2tte4po1rat1wh3tusea2v3teu3texer1i2e1ber1h4tey2t1f4t1ge3br2th_th2e4thle1ce3tumec2i2ths2erb1tia4tueer1aou5vtud2tif22tige1potu1aou4lttu41timt5toos4le1cre2pat4swe5owe1cue4ottsh4eos4e1ort4sce3ol4edieo2ge5of1tio4eno4enn5tiq4edoti4u1tive3my1tiz4othee2ct5laee2ft5lo4t1mee2mtme4e1meem5bcoi4to3be5exo1ry2tof1effel2iel2ftos24t1pe1la1traos2ceig2ei5de5ico2soe1h45egyeg5n",5:"_ach4e4go_e4goseg1ule5gurtre5feg4iceher4eg5ibeger44egaltre4mei5gle3imbe3infe1ingtra3beir4deit3eei3the5ity5triae4jud3efiteki4nek4la2trime4la_e4lactri4v4toute4law5toure3leaefil45elece4ledto2rae5len4tonye1lestro3ve4fic4tonoto3mytom4bto2mato5ice5limto2gre3lioe2listru5i4todo4ellaee4tyello4e5locel5ogeest4el2shel4tae5ludel5uge4mace4mage5man2t1n2ee2s4ee4p1e2mele4metee4naemi4eee4lyeel3i3tled3tle_e4mistlan4eed3iem3iztrus4emo4gti3zaem3pie4mule4dulemu3ne4dritiv4aedon2e4dolti3tle5neae5neeen3emtis4pti5sotis4m3tisee3newti3sae5niee5nile3nioedi5zen3ite5niu5enized1ited3imeno4ge4nosen3oven4swti5oc4t1s2en3uaen5ufe3ny_4en3zed3ibe3diae4oi4ede4s3tini4ed3deo3ret2ina2e2dae4culeo4toe5outec4te4t3t2t4tes2t1ine5pel4timpe2corephe4e4plie2col5tigutu3arti5fytu4bie3pro3tienep4sh5tidie4putt4icoeci4t4tick2ti2bec3imera4bti4aber3ar4tuf45tu3ier4bler3che4cib2ere_4thooecca54thil3thet4thea3turethan4e4cade4bitere4qe4ben5turieret4tur5oeav5oeav5itu5ry4tess4tes_ter5ve1rio4eriter4iueri4v1terier3m4ter3cte5pe4t1waer3noeast3er5obe5rocero4rer1oue3assea5sp1tent4ertler3twtwis4eru4t3tende1s4a3tenc5telsear2te2scateli4e3scres5cue1s2ee2sec3tel_te5giear5kear4cte5diear3ae3sha2t1ede5ande2sice2sid5tecttece44teattype3ty5phesi4uea4gees4mie2sole3acte2sone1a4bdys5pdy4sedu4petaun4d3uleta5sytas4e4tare4tarctar4ata5pl2estrta5mo4talke2surtal3idu5eleta4bta5lae3teoua5naet1ic4taf4etin4ta5doe5tir4taciuan4id1ucad1u1ae3trae3tre2d1s2syn5ouar2d4drowet3uaet5ymdro4pdril4dri4b5dreneu3rouar3ieute44draieu5truar3te2vasdop4pe5veadoo3ddoni4u4belsum3iev1erdoli4do4laev3idevi4le4vinevi4ve5voc2d5ofdo5dee4wage5wee4d1n4ewil54d5lue3wit2d3lou3ber5eye_u1b4i3dledfa3blfab3rfa4ce3dle_fain4suit3su5issu2g34d5lasu4b3fa3tasu1al4fato1di1vd2iti5disiuci4bfeas4di1redi4pl4feca5fectdio5gfe3life4mofen2d4st3wuc4it5ferr5diniucle3f4fesf4fie4stry1dinaf4flydi3ge3dictd4icedia5bs4tops1tle5stirs3tifs4ties1ticfic4is5tias4ti_4ficsfi3cuud3ers3thefil5iste2w4filyudev45finas4tedfi2nes2talfin4ns2tagde2tode4suflin4u1dicf2ly5ud5isu5ditde1scd2es_der5sfon4tu4don5dermss4lid4erhfor4is4siede2pudepi4fra4tf5reade3pade3nufril4frol5ud4side3nou4eneuens4ug5infu5el5dem_s5setfu5nefu3rifusi4fus4s4futade5lode5if4dee_5gal_3galiga3lo2d1eds3selg5amos2s5cssas3u1ing4ganouir4mgass4gath3uita4deaf5dav5e5dav44dato4darygeez44spotspor4s4pon4gelydark5s4ply4spio4geno4genydard5ge3omg4ery5gesigeth54getoge4tydan3g4g1g2da2m2g3gergglu5dach4gh3inspil4gh4to4cutr1gi4agia5rula5bspho5g4icogien5s2pheulch42sperspa4n5spai3c4utu1lenul4gigir4lg3islcu5pycu3picu4mic3umecu2maso5vi5glasu5liagli4bg3lig5culiglo3r4ul3mctu4ru1l4og4na_c3terul1tig2ning4nio4ultug4noncta4b4c3s2cru4dul5ulsor5dgo3isum5absor5ccris4go3nic4rinson4gsona45gos_cri5fcre4vum4bi5credg4raigran25solvsoft3so4ceunat44graygre4nco5zi4gritcoz5egruf4cow5ag5stecove4cos4es5menun4ersmel44corbco4pl4gu4tco3pacon5tsman3gy5racon3ghach4hae4mhae4th5aguha3lac4onecon4aun4ims3latu2ninhan4gs3ket5colocol5ihan4kuni3vhap3lhap5ttras4co4grhar2dco5agsir5aclim45sionhas5shaun44clichaz3acle4m1head3hearun3s4s3ingun4sws2ina2s1in4silysil4eh5elohem4p4clarhena45sidiheo5r1c4l4h4eras5icc2c1itu4orsh3ernshor4h3eryci3phshon34cipecion45cinoc1ingc4inahi5anhi4cohigh5h4il2shiv5h4ina3ship3cilihir4lhi3rohir4phir4rsh3iohis4ssh1inci4lau5pia4h1l4hlan44cier5shevcia5rhmet4ch4tish1erh5ods3cho2hoge4chi2z3chitho4mahome3hon4aho5ny3hoodhoon45chiouptu44ura_ho5ruhos4esew4ihos1p1housu4ragses5tu4rasur4behree5se5shs1e4s4h1s24chedh4tarht1enht5esur4fru3rifser4os4erlhun4tsen5gur1inu3riosen4dhy3pehy3phu1ritces5tur3iz4cesa4sencur4no4iancian3i4semeia5peiass45selv5selfi4atu3centse1le4ceniib5iaib3inseg3ruros43cencib3li3cell5cel_s5edli5bun4icam5icap4icar4s4ed3secticas5i4cayiccu44iceour4pe4ced_i5cidsea5wi2cipseas4i4clyur4pi4i1cr5icrai4cryic4teictu2ccon4urti4ic4umic5uoi3curcci4ai4daiccha5ca4thscof4ide4s4casys4cliscle5i5dieid3ios4choid1itid5iui3dlei4domid3owu5sadu5sanid5uous4apied4ecany4ield3s4cesien4ei5enn4sceii1er_i3esci1estus3ciuse5as4cedscav5if4frsca4pi3fieu5siau3siccan4eiga5bcan5d4calous5sli3gibig3ilig3inig3iti4g4lus1trig3orig5oti5greigu5iig1ur2c5ah4i5i44cag4cach4ca1blusur4sat3usa5tab5utoi3legil1erilev4uta4b4butail3iail2ibil3io3sanc2ilitil2izsal4t5bustil3oqil4tyil5uru3tati4magsa5losal4m4ute_4imetbu3res3act5sack2s1ab4imitim4nii3mon4utelbumi4bu3libu4ga4inav4utenbsor42b5s2u4tis4briti3neervi4vr3vic4inga4inger3vey4ingir3ven4ingo4inguu4t1li5ni_i4niain3ioin1isbo4tor5uscrunk5both5b5ota5bos42i1no5boriino4si4not5borein3seru3in2int_ru4glbor5di5nusut5of5bor_uto5gioge4io2grbon4au5tonru3enu4touion3iio5phior3ibod3iio5thi5otiio4toi4ourbne5gb3lisrt4shblen4ip4icr3triip3uli3quar4tivr3tigrti4db4le_b5itzira4bi4racird5ert5ibi4refbi3tri4resir5gibi5ourte5oir4isr3tebr4tagbin4diro4gvac3uir5ul2b3ifis5agis3arisas52is1cis3chbi4eris3erbi5enrson3be5yor5shais3ibisi4di5sisbe3tw4is4krs3es4ismsbe5trr3secva4geis2piis4py4is1sbe3sp4bes4be5nuval5ois1teis1tirrys4rros44be5mis5us4ita_rron4i4tagrri4vi3tani3tatbe3lorri4or4reoit4esbe1libe5gu4itiarre4frre4cbe3giit3igbe3dii2tim2itio4itisrp4h4r3pet4itonr4peait5rybe3debe3dai5tudit3ul4itz_4be2dbeat3beak4ro4varo4tyros4sro5roiv5ioiv1itror3i5root1roomval1ub3berva5mo4izarva5piron4eban3ijac4qban4ebal1ajer5srom4prom4iba4geazz5i5judgay5alax4idax4ickais4aw4ly3awaya1vorav5ocav3igke5liv3el_ve4lov4elyro1feke4tyv4erdv4e2sa5vanav3ag5k2ick4illkilo5au1thk4in_4ves_ro3crkin4gve4teaun5dk5ishau4l2au3gu4kleyaugh3ve4tyk5nes1k2noat3ulkosh4at5uekro5n4k1s2at5uaat4that5te5vianat4sk5vidil4abolaci4l4adela3dylag4nlam3o3landrob3la4tosr4noular4glar3ilas4ea4topr3nivr3nita2tomr5nica4toglbin44l1c2vi5gnat3ifat1ica5tiar3neyr5net4ati_ld5isat4hol4driv2incle4bileft55leg_5leggr4nerr3nel4len_3lencr4nar1lentle3phle4prvin5dler4e3lergr3mitl4eroat5evr4mio5lesq3lessr3menl3eva4vingrma5cvio3lvi1ou4leyevi5rovi3so4l1g4vi3sulgar3l4gesate5cat5apli4agli2amr3lo4li4asr4lisli5bir4ligr2led4lics4vitil4icul3icyl3idaat5ac3lidirk4lel4iffli4flr3ket3lighvit3r4vityriv3iri2tulim3ili4moris4pl4inar3ishris4clin3ir4is_li5og4l4iqlis4pas1trl2it_as4shas5phri2pla4socask3ia3sicl3kallka4ta3sibl4lawashi4l5leal3lecl3legl3lel5riphas4abar2shrin4grin4ear4sarin4dr2inal5lowarre4l5met3rimol4modlmon42l1n2a3roorim5ilo4civo4la5rigil5ogo3loguri5et5longlon4iri1erlood5r4icolop3il3opmlora44ricir4icerib3a5los_v5oleri4agria4blos4tlo4taar2mi2loutar2izar3iolpa5bl3phal5phi4rhall3pit5voltar4im3volv2l1s2vom5ivori4l4siear4fllt5agar4fivo4rylten4vo4talth3ia3reeltis4ar4drw5ablrgo4naraw4lu3brluch4lu3cilu3enwag5olu5idlu4ma5lumia5raur5gitwait5luo3rw5al_luss4r5gisar4atl5venrgi4nara3pwar4tar3alwas4tly5mely3no2lys4l5ysewa1teaque5ma2car3gicma4clr3get5magnwed4nmaid54maldrg3erweet3wee5vwel4lapoc5re4whwest3ap3in4aphires2tr4es_mar3vre5rumas4emas1t5matemath3rero4r4eriap5atr1er4m5bilre1pumbi4vapar4a5nuran3ul4med_an3uare5lure1lian4twre5itmel4tan2trre4fy4antomen4are3fire2fe4menemen4imens4re1de3ment2r2edme5onre4awwin4g5reavme4tare3anme1tere1alm4etr3wiserdin4rdi4aan4stwith3an2span4snan2samid4amid4gan5otwl4esr4dalm4illmin4a3mindrcum3rc4itr3charcen4min4tm4inumiot4wl3ina3niumis5lan3ita3nip4mithan3ioan1gla3neuws4per2bina3nena5neem4ninw5s4tan1dl4mocrrbi4fmo2d1mo4gomois2xac5ex4agor4bagmo3mer4baba3narrau4ta5monrare4rar5cra5nor4aniam1inr2amiam5ifra4lomo3spmoth3m5ouf3mousam3icxer4ixe5roraf4tr5aclm3petra3bixhil5mpi4aam3ag3quetm5pirmp5is3quer2que_qua5vmpov5mp4tram5ab3alyz4m1s25alyt4alysa4ly_ali4exi5di5multx4ime4aldia4laral3adal5abak1enain5opu3trn4abu4nac_na4can5act5putexpe3dna4lia4i4n4naltai5lya3ic_pur4rag5ulnank4nar3c4narenar3inar4ln5arm3agognas4c4ag4l4ageupul3cage4oaga4na4gab3nautnav4e4n1b4ncar5ad5umn3chaa3ducptu4rpti3mnc1innc4itad4suad3owad4len4dain5dana5diua3ditndi4ba3dion1ditn3dizn5ducndu4rnd2we3yar4n3eara3dianeb3uac4um5neckac3ulp4siba3cio5negene4laac1inne5mine4moa3cie4nene4a2cine4poyc5erac1er2p1s2pro1tn2erepro3lner4rych4e2nes_4nesp2nest4neswpri4sycom4n5evea4carab3uln4gabn3gelpre3vpre3rycot4ng5han3gibng1inn5gitn4glangov4ng5shabi5an4gumy4erf4n1h4a5bannhab3a5bal3n4iani3anni4apni3bani4bl_us5ani5dini4erni2fip3petn5igr_ure3_un3up3per_un5op3pennin4g_un5k5nis_p5pel_un1en4ithp4ped_un1ani3tr_to4pympa3_til4n3ketnk3inyn5ic_se2ny4o5gy4onsnmet44n1n2_ru4d5pounnni4vnob4lpo4tan5ocly4ped_ro4qyper5noge4pos1s_ri4gpo4ry1p4or_res2no4mono3my_ree2po4ninon5ipoin2y4poc5po4gpo5em5pod_4noscnos4enos5tno5tayp2ta3noun_ra4cnowl3_pi2tyra5m_pi4eyr5ia_out3_oth32n1s2ns5ab_or3t_or1d_or3cplu4mnsid1nsig4y3s2eys3ion4socns4pen5spiploi4_odd5nta4bpli4n_ni4cn5tib4plignti2fpli3a3plannti4p1p2l23ysis2p3k2ys3ta_mis1nu5enpi2tun3uinp3ithysur4nu1men5umi3nu4nyt3icnu3trz5a2b_li4t_li3o_li2n_li4g_lev1_lep5_len4pion4oard3oas4e3pi1ooat5ip4inoo5barobe4l_la4mo2binpind4_ju3rob3ul_is4i_ir5rp4in_ocif3o4cil_in3so4codpi3lopi3enocre33piec5pidipi3dep5ida_in2kod3icodi3oo2do4odor3pi4cypian4_ine2o5engze3rooe4ta_im3m_id4l_hov5_hi3b_het3_hes3_go4r_gi4bpho4ro5geoo4gero3gie3phobog3it_gi5azo5ol3phizo4groogu5i4z1z22ogyn_fes3ohab5_eye55phieph1icoiff4_en3sph4ero3ing_en3go5ism_to2qans3v_el5d_eer4bbi4to3kenok5iebio5mo4lanper1v4chs_old1eol3erpe5ruo3letol4fi_du4co3liaper3op4ernp4erio5lilpe5ono5liop4encpe4la_do4tpee4do5livcin2q3pediolo4rol5pld3tabol3ub3pedeol3uno5lusedg1le1loaom5ahoma5l2p2edom2beom4bl_de3o3fich3pe4ao4met_co4ro3mia_co3ek3shao5midom1inll1fll3teapa2teo4monom3pi3pare_ca4tlue1pon4aco3nanm2an_pa4pum2en_on5doo3nenng1hoon4guon1ico3nioon1iso5niupa3nypan4ao3nou_bri2pain4ra1oronsu4rk1hopac4tpa4ceon5umonva5_ber4ood5eood5i6rks_oop3io3ordoost5rz1scope5dop1erpa4ca_ba4g_awn4_av4i_au1down5io3pito5pon1sync_as1s_as1p_as3ctch1c_ar5so5ra_ow3elo3visov4enore5auea1mor3eioun2d_ant4orew4or4guou5etou3blo5rilor1ino1rio_ang4o3riuor2miorn2eo5rofoto5sor5pe3orrhor4seo3tisorst4o3tif_an5cor4tyo5rum_al3tos3al_af1tos4ceo4teso4tano5scros2taos4poos4paz2z3wosi4ue3pai",6:"os3ityos3itoz3ian_os4i4ey1stroos5tilos5titxquis3_am5atot3er_ot5erso3scopor3thyweek1noth3i4ot3ic_ot5icao3ticeor3thiors5enor3ougor3ityor3icaouch5i4o5ria_ani5mv1ativore5sho5realus2er__an3teover3sov4erttot3icoviti4o5v4olow3dero4r3agow5esto4posiop3ingo5phero5phanthy3sc3operaontif5on3t4ionten45paganp3agattele2gonspi4on3omyon4odipan3elpan4tyon3keyon5est3oncil_ar4tyswimm6par5diompro5par5elp4a4ripar4isomo4gepa5terst5scrpa5thy_atom5sta1tio5miniom3icaom3ic_ss3hatsky1scpear4lom3ena_ba5naol3umer1veilpedia4ped4icolli4er1treuo5liteol3ishpeli4epe4nano5lis_pen4thol3ingp4era_r1thoup4erago3li4f_bas4er1krauperme5ol5id_o3liceper3tio3lescolass4oi3terpe5tenpe5tiz_be5raoi5son_be3smphar5iphe3nooi5letph4es_oi3deroic3esph5ingr3ial_3ognizo5g2ly1o1gis3phone5phonio5geneo4gatora3mour2amenofit4tof5itera3chupi4ciepoly1eod5dedo5cureoc3ula1pole_5ocritpee2v1param4oc3raco4clamo3chetob5ingob3a3boast5eoke1st3nu3itpi5thanuf4fentu3meoerst2o3chasplas5tn3tinepli5ernti4ernter3sntre1pn4s3esplum4bnsati4npre4cns4moonon1eqnor5abpo3et5n5lessn5oniz5pointpoly5tnon4agnk3rup3nomicng1sprno5l4inois5i4n3o2dno3blenni3aln5keroppa5ran3itor3nitionis4ta5nine_ni3miznd3thrmu2dron3geripray4e5precipre5copre3emm3ma1bpre4lan5gerep3rese3press_can5cmedi2c5pri4e_ce4la3neticpris3op3rocal3chain4er5ipros3en4erarnera5bnel5iz_cit5rne4gatn5d2ifpt5a4bjanu3aign4itn3chisn5chiln5cheon4ces_nau3seid4iosna3talnas5tinan4itnanci4na5mitna5liahnau3zput3er2n1a2bhex2a3hatch1multi3hair1sm4pousg1utanmpo3rim4p1inmp5iesmphas4rach4empar5iraf5figriev1mpara5mo5seyram3et4mora_rane5oran4gemo3ny_monol4rap3er3raphymo3nizgno5morar5ef4raril1g2nacg1leadmoni3ara5vairav3elra5ziemon5gemon5etght1wemoi5sege3o1dmma5ryr5bine3fluoren1dixmis4ti_de3ra_de3rie3chasrch4err4ci4bm4inglm5ineedu2al_3miliame3tryrdi4er_des4crd3ingdi2rerme5thimet3alre5arr3mestim5ersadi2rende2ticdes3icre4cremen4temensu5re3disred5itre4facmen4dede2mosmen5acmem1o3reg3ismel5onm5e5dyme3died2d5ibren4te5mediare5pindd5a5bdata1bmba4t5cle4arma3tisma5scemar4lyre4spichs3huma5riz_dumb5re3strre4terbrus4qre3tribio1rhre5utiman3izre4valrev3elbi1orbbe2vie_eas3ire5vilba1thyman5is5maniamal4tymal4lima5linma3ligmag5inav3ioul5vet4rg3inglus3teanti1dl5umn_ltur3a_el3emltera4ltane5lp5ingloun5dans5gra2cabllos5etlor5ouric5aslo5rie_enam35ricidri4cie5lope_rid5erri3encri3ent_semi5lom3errig5an3logicril3iz5rimanlob5allm3ingrim4pell5out5rina__er4ril5linal2lin4l3le4tl3le4nriph5eliv3er_ge5og_han5k_hi3er_hon3olin3ea1l4inel4im4p_idol3_in3ci_la4cy_lath5rit3iclim4blrit5urriv5elriv3et4l4i4lli4gra_leg5elif3errk4linlid5er4lict_li4cor5licioli4atorl5ish_lig5a_mal5o_man5a_mer3c5less_rm5ersrm3ingy3thinle5sco3l4erilera5b5lene__mon3ele4matld4erild4erela4v4ar1nis44lativ_mo3rola5tanlan4telan5etlan4dllab3ic_mu5takin4dek3est_ro5filk3en4dro5ker5role__of5te4jestyys3icaron4al5izont_os4tlron4tai4v3ot_pe5tero3pelrop3ici5voreiv5il__pio5n_pre3mro4the_ran4tiv3en_rov5eliv3ellit3uati4tramr5pentrp5er__rit5ui4tismrp3ingit5ill_ros5tit3ica4i2tici5terirre4stit3era4ita5mita4bi_row5dist4lyis4ta_is4sesrsa5tiissen4is4sal_sci3erse4crrs5er_islan4rse5v2yo5netish5opis3honr4si4bis5han5iron_ir4minrtach4_self5iri3turten4diri5dei4rel4ire4de_sell5r4tieriq3uidrtil3irtil4lr4tilyr4tistiq5uefip4re4_sing4_ting4yn3chrru3e4lion3at2in4th_tin5krum3pli4no4cin3ityrun4ty_ton4aruti5nymbol5rvel4i_top5irv5er_r5vestin5geni5ness_tou5s_un3cein3cerincel45ryngei4n3auim3ulai5miniimi5lesac3riim5ida_ve5rasalar4ima5ryim3ageill5abil4istsan4deila5rai2l5am_wil5ii4ladeil3a4bsa5voright3iig3eraab5erd4ific_iff5enif5eroi3entiien5a45ie5gaidi5ou3s4cieab5latidi4arid5ianide3al4scopyab5rogid5ancic3ulaac5ardi2c5ocic3ipaic5inase2c3oi4carai4car_se4d4ei2b5riib5iteib5it_ib5ertib3eraac5aroi4ativ4ian4tse4molsen5ata5ceouh4warts5enedhus3t4s5enin4sentd4sentlsep3a34s1er_hun5kehu4min4servohro3poa5chethov5el5se5umhouse3sev3enho5senhort3eho5rishor5at3hol4ehol5arh5odizhlo3riac5robhis3elhion4ehimer4het4edsh5oldhe2s5ph5eroushort5here5aher4bahera3p3side_5sideshen5atsi5diz4signahel4lyact5ifhe3l4ihe5do55sine_h5ecathe4canad4dinsion5aad5er_har4lehard3e3sitioha5rasha3ranhan4tead3icahang5oadi4ersk5inesk5ing5hand_han4cyhan4cislith5hala3mh3ab4lsmall32g5y3n5gui5t3guard5smithad5ranaeri4eag5ellag3onia5guerso4labsol3d2so3licain5in4grada3s4on_gor5ougo5rizgondo5xpan4dait5ens5ophyal3end3g4o4ggnet4tglad5i5g4insgin5ge3g4in_spen4d2s5peog3imen5gies_3spher5giciagh5outsp5ingge5nizge4natge5lizge5lisgel4inxi5miz4gativgar5n4a5le5oga3nizgan5isga5mets5sengs4ses_fu4minfres5cfort5assi4erss5ilyfore5tfor5ayfo5ratal4ia_fon4dessur5aflo3ref5lessfis4tif1in3gstam4i5stands4ta4p5stat_fin2d5al5levs5tero4allicstew5afight5fi5del5ficie5ficiafi3cer5stickf3icena5log_st3ingf3icanama5ra5stockstom3a5stone2f3ic_3storef2f5iss4tradam5ascs4trays4tridf5fin_fend5efeath3fault5fa3thefar5thfam5is4fa4mafall5eew3inge5verbeven4ie5vengevel3oev3ellev5asteva2p5euti5let5roset3roget5rifsy5rinet3ricet5onaam5eraam5ilyami4noamor5ieti4noe5tidetai5loethod3eten4dtal5enes5urramp5enan3ageta5loge5strotan4detanta3ta5pere3ston4es2toes5times3tigta3rizestan43analy4taticta4tures4prean3arces3pertax4ises5onaes3olue5skintch5etanar4ies4i4ntead4ie2s5ima3natiande4sesh5enan3disan4dowang5iete5geres5ences5ecres5cana4n1icte2ma2tem3at3tenanwrita45erwau4tenesert3era3nieser3set5erniz4erniter4nis5ter3de4rivaan3i3fter3isan4imewo5vener3ineeri4ere3rient3ess_teth5e5ericke1ria4er3ester5esser3ent4erenea5nimier5enaer3emoth3easthe5atthe3iser5el_th5ic_th5icaere3in5thinkere5coth5odea5ninee3realan3ishan4klier4che5anniz4erandti4atoanoth5equi3lep5utat4ic1uan4scoe4probep3rehe4predans3poe4precan4surantal4e3penttim5ulep5anceo5rol3tine_eop3aran4tiewin4deap5eroen3ishen5icsen3etren5esten5esien5eroa3pheren3dicap3itae4nanten5amoem5ulaa3pituti3zen5emnize5missem5ishap5olaem5ine3tles_t5let_em1in2apor5iem3icaem5anael3op_el4labapos3te3liv3el5ishaps5esweath3e3lierel3icaar3actwa5verto3nate3libee4l1erel3egato3rietor5iza5radeelaxa4aran4gto3warelan4dej5udie5insttra5chtraci4ar5av4wa5gere5git5arbal4ar5easeg5ing4voteetrem5iar3enta5ressar5ial4tricsvor5abe3finetro5mitron5i4tronyar3iantro3sp5eficia3rieted5uloed3icae4d1erec3ulaec4tane4cremeco5roec3orae4concar5o5de4comme4cluse4clame5citeec5ifya5ronias3anta5sia_tu4nis2t3up_ecan5ce4belstur3ise4bel_eav3ene4a3tue5atifeath3ieat5eneart3eear4ilear4icear5eseam3ereal3oueal5erea5geread5iedum4be4ducts4duct_duc5eras3tenasur5adrea5rat3abl4d5outdo3natdom5izdo5lor4dlessu4bero3dles_at3alou3ble_d4is3tdirt5idi5niz3dine_at5ech5di3endi4cam1d4i3ad3ge4tud5estdev3ilde3strud3iedud3iesdes3tide2s5oat3egovis3itde4nardemor5at3en_uen4teuer4ilde5milat3eraugh3en3demicater5nuil5izdeli4ede5comde4cildecan4de4bonv3io4rdeb5it4dativ2d3a4bat3estu5laticu4tie5ulcheul3dercuss4icu5riaath5em3cultua5thenul3ingul5ishul4lar4vi4naul4liscu5ityctim3ic4ticuuls5esc5tantultra3ct5angcros4ecrop5ocro4pl5critiath5omum4blycre3at5vilitumor5oat5i5b5crat_cras5tcoro3ncop3iccom5ercol3orun5ishco3inc5clareat3ituunt3abat5ropun4tescit3iz4cisti4cista4cipicc5ing_cin3em3cinatuper5s5videsup3ingci2a5b5chini5videdupt5ib5vide_at4tag4ch1inch3ersch3er_ch5ene3chemiche5loure5atur4fercheap3vi5aliat3uravet3er4ch3abc5e4taau5sib3cessives4tece5ram2cen4e4cedenccou3turs5erur5tesur3theaut5enur4tiecav5al4cativave4nover3thcar5omca5percan4tycan3izcan5iscan4icus4lin3versecal4laver3ieca3latca5dencab3in3butiobuss4ebus5iebunt4iv4eresuten4i4u1t2iv3erenu3tineut3ingv4erelbroth35u5tizbound34b1orabon5at5vere_bom4bibol3icblun4t5blespblath5av3erav5enuebi3ogrbi5netven3om2v1a4bvac5ilbi3lizbet5izbe5strva5liebe5nigbbi4nabas4siva5nizbari4aav5ernbarbi5av5eryvel3liazi4eravi4er",7:"_dri5v4ban5dagvar5iedbina5r43bi3tio3bit5ua_ad4derution5auti5lizver5encbuf4ferus5terevermi4ncall5incast5ercas5tigccompa5z3o1phros5itiv5chanicuri4fico5stati5chine_y5che3dupport54v3iden5cific_un4ter_at5omiz4oscopiotele4g5craticu4m3ingv3i3liz4c3retaul4li4bcul4tiscur5a4b4c5utiva5ternauiv4er_del5i5qdem5ic_de4monsdenti5fdern5izdi4latou4b5ingdrag5on5drupliuar5ant5a5si4tec5essawo4k1enec5ifiee4compear5inate4f3eretro5phewide5sp5triciatri5cesefor5ese4fuse_oth5esiar5dinear4chantra5ventrac4tetrac4itar5ativa5ratioel5ativor5est_ar5adisel5ebraton4alie4l5ic_wea5rieel5igibe4l3ingto5cratem5igraem3i3niemoni5oench4erwave1g4a4pillavoice1ption5eewill5inent5age4enthesvaude3vtill5inep5recaep5ti5bva6guer4erati_tho5rizthor5it5thodicer5ence5ternitteri5zater5iesten4tage4sage_e4sagese4sert_an5est_e4sertse4servaes5idenes5ignaesis4tees5piraes4si4btal4lisestruc5e5titioounc5erxe4cutota5bleset5itiva4m5atoa4matis5stratu4f3ical5a5lyst4ficatefill5instern5isspend4gani5zasqual4la4lenti4g3o3nas5ophiz5sophicxpecto55graph_or5angeuri4al_4graphy4gress_smol5d4hang5erh5a5nizharp5enhar5terhel4lishith5erhro5niziam5eteia4tricic4t3uascour5au2r1al_5scin4dover4nescan4t55sa3tiou5do3ny_ven4de_under5ty2p5al_anti5sylla5bliner4arturn3ari5nite_5initioinsur5aion4eryiphras4_tim5o5_ten5an_sta5blrtroph4_se5rieiq3ui3t5i5r2izis5itiviso5mer4istral5i5ticki2t5o5mtsch3ie_re5mittro3fiti4v3er_i4vers_ros5per_pe5titiv3o3ro_ped5alro5n4is_or5ato4jestierom5ete_muta5bk5iness4latelitr4ial__mist5i_me5terr4ming_lev4er__mar5tilev4eralev4ers_mag5a5liar5iz5ligaterit5ers_lat5errit5er_r5ited__im5pinri3ta3blink5er_hon5ey5litica_hero5ior5aliz_hand5irip5lic_gen3t4tolo2gylloqui5_con5grt1li2erbad5ger4operag_eu4lertho3donter2ic__ar4tie_ge4ome_ge5ot1_he3mo1_he3p6a_he3roe_in5u2tpara5bl5tar2rht1a1mintalk1a5ta3gon_par5age_aster5_ne6o3f_noe1thstyl1is_poly1s5pathic_pre1ampa4tricl3o3niz_sem4ic_semid6_semip4_semir45ommend_semiv4lea4s1a_spin1oom5etryspher1o_to6poglo4ratospe3cio3s2paceso2lute_we2b1l_re1e4ca5bolicom5erseaf6fishside5swanal6ysano5a2cside5stl5ties_5lumniasid2ed_anti1reshoe1stscy4th1s4chitzsales5wsales3cat6tes_augh4tlau5li5fom5atizol5ogizo5litiorev5olure5vertre5versbi5d2ifbil2lab_earth5pera5blro1tronro3meshblan2d1blin2d1blon2d2bor1no5ro1bot1re4ti4zr5le5quperi5stper4malbut2ed_but4tedcad5e1moist5enre5stalress5ibchie5vocig3a3roint5er4matizariv1o1lcous2ticri3tie5phisti_be5stoog5ativo2g5a5rr3a3digm4b3ingre4posir4en4tade4als_od5uctsquasis6quasir6re5fer_p5trol3rec5olldic1aiddif5fra3pseu2dr5ebrat5metric2d1lead2d1li2epro2g1epre1neuod5uct_octor5apoin3came5triem5i5liepli5narpara3memin5glim5inglypi4grappal6matmis4er_m5istryeo3graporth1riop1ism__but4tio3normaonom1icfeb1ruafermi1o_de4moio5a5lesodit1icodel3lirb5ing_gen2cy_n4t3ingmo5lestration4get2ic_4g1lishobli2g1mon4ismnsta5blmon4istg2n1or_nov3el3ns5ceivno1vembmpa5rabno4rarymula5r4nom1a6lput4tinput4tedn5o5miz_cam4penag5er_nge5nesh2t1eoun1dieck2ne1skiifac1etncour5ane3backmono1s6mono3chmol1e5cpref5ac3militapre5tenith5i2lnge4n4end5est__capa5bje1re1mma1la1ply5styr1kovian_car5olprin4t3lo2ges_l2l3ishprof5it1s2tamp",8:"lead6er_url5ing_ces5si5bch5a5nis1le1noidlith1o5g_chill5ilar5ce1nym5e5trych5inessation5arload4ed_load6er_la4c3i5elth5i2lyneg5ativ1lunk3erwrit6er_wrap3arotrav5es51ke6linga5rameteman3u1scmar1gin1ap5illar5tisticamedio6c1me3gran3i1tesima3mi3da5bves1titemil2l1agv1er1eigmi6n3is_1verely_e4q3ui3s5tabolizg5rapher5graphicmo5e2lasinfra1s2mon4ey1lim3ped3amo4no1enab5o5liz_cor5nermoth4et2m1ou3sinm5shack2ppo5sitemul2ti5uab5it5abimenta5rignit1ernato5mizhypo1thani5ficatuad1ratu4n5i4an_ho6r1ic_ua3drati5nologishite3sidin5dling_trib5utin5glingnom5e1non1o1mistmpos5itenon1i4so_re5stattro1p2istrof4ic_g2norespgnet1ism5glo5binlem5aticflow2er_fla1g6elntrol5lifit5ted_treach1etra1versl5i5ticso3mecha6_for5mer_de5rivati2n3o1me3spac6i2t3i4an_thy4l1antho1k2er_eq5ui5to4s3phertha4l1amt3ess2es3ter1geiou3ba3dotele1r6ooxi6d1iceli2t1isonspir5apar4a1leed1ulingea4n3iesoc5ratiztch3i1er_kil2n3ipi2c1a3dpli2c1abt6ap6athdrom3e5d_le6icesdrif2t1a_me4ga1l1prema3cdren1a5lpres2plipro2cess_met4ala3do5word1syth3i2_non1e2m_post1ampto3mat4rec5ompepu5bes5cstrib5utqu6a3si31stor1ab_sem6is4star3tliqui3v4arr1abolic_sph6in1de5clar12d3aloneradi1o6gs3qui3tosports3wsports3cra5n2hascro5e2cor3bin1gespokes5wspi2c1il_te3legrcroc1o1d_un3at5t_dictio5cat1a1s2buss4ingbus6i2esbus6i2erbo2t1u1lro5e2las1s2pacinb1i3tivema5rine_r3pau5li_un5err5r5ev5er__vi2c3arback2er_ma5chinesi5resid5losophyan3ti1n2sca6p1ersca2t1olar2rangesep3temb1sci2uttse3mes1tar3che5tsem1a1ph",9:"re4t1ribuuto5maticl3chil6d1a4pe5able1lec3ta6bas5ymptotyes5ter1yl5mo3nell5losophizlo1bot1o1c5laratioba6r1onierse1rad1iro5epide1co6ph1o3nscrap4er_rec5t6angre2c3i1prlai6n3ess1lum5bia_3lyg1a1miec5ificatef5i5nites2s3i4an_1ki5neticjapan1e2smed3i3cinirre6v3ocde2c5linao3les3termil5li5listrat1a1gquain2t1eep5etitiostu1pi4d1v1oir5du1su2per1e6_mi1s4ers3di1methy_mim5i2c1i5nitely_5maph1ro15moc1ra1tmoro6n5isdu1op1o1l_ko6r1te1n3ar4chs_phi2l3ant_ga4s1om1teach4er_parag6ra4o6v3i4an_oth3e1o1sn3ch2es1to5tes3toro5test1eror5tively5nop5o5liha2p3ar5rttrib1ut1_eth1y6l1e2r3i4an_5nop1oly_graph5er_5eu2clid1o1lo3n4omtrai3tor1_ratio5na5mocratiz_rav5en1o",10:"se1mi6t5ic3tro1le1um5sa3par5iloli3gop1o1am1en3ta5bath3er1o1s3slova1kia3s2og1a1myo3no2t1o3nc2tro3me6c1cu2r1ance5noc3er1osth1o5gen1ih3i5pel1a4nfi6n3ites_ever5si5bs2s1a3chu1d1ri3pleg5_ta5pes1trproc3i3ty_s5sign5a3b3rab1o1loiitin5er5arwaste3w6a2mi1n2ut1erde3fin3itiquin5tes5svi1vip3a3r",11:"pseu3d6o3f2s2t1ant5shimi1n2ut1estpseu3d6o3d25tab1o1lismpo3lyph1onophi5lat1e3ltravers3a3bschro1ding12g1o4n3i1zat1ro1pol3it3trop1o5lis3trop1o5lesle3g6en2dreeth1y6l1eneor4tho3ni4t",12:"3ra4m5e1triz1e6p3i3neph1"}};Hyphenator.config({remoteloading:false});Hyphenator.run();
@@ -1,5 +1,3 @@
------ ------ /** * @version: 1.0 Alpha-1 * @author: Coolite Inc. http://www.coolite.com/
@@ -1,5 +1,3 @@
------ ------ function format_date(d){ return $.timeago(Date.parse(d)); }@@ -9,70 +7,17 @@ $.getJSON(uri,
function(data){ var list = $("<ul></ul>"); for (var i=0; i<options.max; i++){ - switch(options.element){ - case "#backtype": - var item = backtype_entry(data.comments[i]) - break; - case "#delicious": - var item = delicious_entry(data[i]) - break; - case "#twitter": - var item = twitter_entry(data[i]) - break; - case "#github": - var item = github_entry(data.commits[i], options.repo) - break; - } + var item = github_entry(data.commits[i], options.repo) item.appendTo(list); } list.appendTo(options.element).fadeIn(1000); }); } -function backtype_entry(comment){ - var c = $("<li></li>").addClass('feed-item'); - var dt = $("<span></span>").addClass('feed-item-date').html(format_date(comment.comment.date+" GMT")+":"); - var tx = $("<span>» </span>").addClass('feed-item-text').append($('<a></a>').attr('href', comment.comment.url).html(comment.post.title)); - c.append(dt); - c.append(tx); - return c -} - -function twitter_entry(tweet){ - var it = $("<li></li>").addClass('feed-item'); - var content = tweet.text - .replace(/^h3rald:/, '') - .replace(/((http|ftp|https):\/\/[\w\-_]+(\.[\w\-_]+)+([\w\-\.,@?^=%&:/~\+#]*[\w\-\@?^=%&/~\+#])?)/g, '<a href="$1">$1</a>') - .replace(/@([a-zA-Z0-9_-]*)/g, '<a href="http://www.twitter.com/$1">@$1</a>') - .replace(/#([a-zA-Z0-9_-]*)/g, '<a href="http://www.twitter.com/search?q=%23$1">#$1</a>') - var dt = $("<span></span>").addClass('feed-item-date').html(format_date(tweet.created_at)+":"); - var tx = $("<span>» </span>").addClass('feed-item-text').html(content); - it.append(dt); - it.append(tx); - return it -} - -function delicious_entry(bookmark){ - var it = $("<li></li>").addClass('feed-item'); - var content = "<a href='"+bookmark.u+"'>"+bookmark.d+"</a>"; - content += "<br />tags: "; - var categories = Array(); - for (i=0; i<bookmark.t.length; i++) - { - categories[i] = "<a href='http://delicious.com/h3rald/"+bookmark.t[i]+"'>"+bookmark.t[i]+"</a>"; - } - content += categories.join(', ').replace(/ $/, ''); - var dt = $("<span></span>").addClass('feed-item-date').html(format_date(bookmark.dt)+":"); - var tx = $("<span>» </span>").addClass('feed-item-text').html(content); - it.append(dt); - it.append(tx); - return it -} - function github_entry(commit, repo){ var it = $("<li></li>").addClass('commit-data'); var dt = $("<span></span>").addClass('commit-date').html(format_date(commit.committed_date)+" · "); - var link = $("<span></span><br />").addClass('commit-link').append($('<a></a>').attr('href', commit.url).html("View")); + var link = $("<span></span><br />").addClass('commit-link').append($('<a></a>').attr('href', commit.url).html("» VIEW")); var tx = $("<span></span>").addClass('commit-text').html(commit.message .replace(/(closes) #(\d+)/ig, "$1 <a href='http://github.com/h3rald/"+repo+"/issues/#issue/$2'>#$2</a>")+"<br />"); it.append(tx);@@ -81,21 +26,6 @@ it.append(link);
return it } - -// http://api.backtype.com/user/h3rald/comments.json?key=47bf0031e3a18a598b85&html=1 -function display_opinions(max){ - get_json_data("/data/opinions.json", {max: max, element: '#backtype'}) -} - -// http://twitter.com/status/user_timeline/h3rald.json -function display_tweets(max){ - get_json_data("/data/tweets.json", {max: max, element: '#twitter'}) -} - -// http://feeds.delicious.com/v2/json/h3rald -function display_bookmarks(max){ - get_json_data("/data/bookmarks.json", {max: max, element: '#delicious'}) -} /* http://github.com/api/v2/json/commits/list/h3rald/concatenative/master
@@ -0,0 +1,2 @@
+// For discussion and comments, see: http://remysharp.com/2009/01/07/html5-enabling-script/ +(function(){if(!/*@cc_on!@*/0)return;var e = "abbr,article,aside,audio,bb,canvas,datagrid,datalist,details,dialog,eventsource,figure,footer,header,hgroup,mark,menu,meter,nav,output,progress,section,time,video".split(',');for(var i=0;i<e.length;i++){document.createElement(e[i])}})()
@@ -0,0 +1,22 @@
+/* + * Hyphenator X.Y.Z - client side hyphenation for webbrowsers + * Copyright (C) 2010 Mathias Nater, Zürich (mathias at mnn dot ch) + * Project and Source hosted on http://code.google.com/p/hyphenator/ + * + * This JavaScript code is free software: you can redistribute + * it and/or modify it under the terms of the GNU Lesser + * General Public License (GNU LGPL) as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) + * any later version. The code is distributed WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU GPL for more details. + * + * As additional permission under GNU GPL version 3 section 7, you + * may distribute non-source (e.g., minimized or compacted) forms of + * that code without the copy of the GNU GPL normally required by + * section 4, provided you include this license notice and a URL + * through which recipients can access the Corresponding Source. + */ + +var Hyphenator=(function(window){var +supportedLang={'be':'be.js','cs':'cs.js','da':'da.js','bn':'bn.js','de':'de.js','el':'el-monoton.js','el-monoton':'el-monoton.js','el-polyton':'el-polyton.js','en':'en-us.js','en-gb':'en-gb.js','en-us':'en-us.js','es':'es.js','fi':'fi.js','fr':'fr.js','grc':'grc.js','gu':'gu.js','hi':'hi.js','hu':'hu.js','hy':'hy.js','it':'it.js','kn':'kn.js','la':'la.js','lt':'lt.js','ml':'ml.js','nl':'nl.js','or':'or.js','pa':'pa.js','pl':'pl.js','pt':'pt.js','ru':'ru.js','sl':'sl.js','sv':'sv.js','ta':'ta.js','te':'te.js','tr':'tr.js','uk':'uk.js'},languageHint=(function(){var k,r='';for(k in supportedLang){if(supportedLang.hasOwnProperty(k)){r+=k+', ';}}r=r.substring(0,r.length-2);return r;}()),prompterStrings={'be':'???? ?????? ????? ?? ???? ???? ????????? ???????????. ???? ????? ???????? ????:','cs':'Jazyk této internetové stránky nebyl automaticky rozpoznán. Urcete prosím její jazyk:','da':'Denne websides sprog kunne ikke bestemmes. Angiv venligst sprog:','de':'Die Sprache dieser Webseite konnte nicht automatisch bestimmt werden. Bitte Sprache angeben:','en':'The language of this website could not be determined automatically. Please indicate the main language:','es':'El idioma del sitio no pudo determinarse autom%E1ticamente. Por favor, indique el idioma principal:','fi':'Sivun kielt%E4 ei tunnistettu automaattisesti. M%E4%E4rit%E4 sivun p%E4%E4kieli:','fr':'La langue de ce site n%u2019a pas pu %EAtre d%E9termin%E9e automatiquement. Veuillez indiquer une langue, s.v.p.%A0:','hu':'A weboldal nyelvét nem sikerült automatikusan megállapítani. Kérem adja meg a nyelvet:','hy':'????????? ??????????? ??? ????? ??????: ??????? ??? ???? ???????? ???????','it':'Lingua del sito sconosciuta. Indicare una lingua, per favore:','kn':'??? ???? ????????? ?????????? ????????????????. ???????? ????? ????????? ??????:','lt':'Nepavyko automatiškai nustatyti šios svetaines kalbos. Prašome ivesti kalba:','ml':'? ??%u0D2C%u0D4D%u200C?????????? ??? ???????????????%u0D28%u0D4D%u200D ??????????. ??? ????????? ??????????????:','nl':'De taal van deze website kan niet automatisch worden bepaald. Geef de hoofdtaal op:','pt':'A língua deste site não pôde ser determinada automaticamente. Por favor indique a língua principal:','ru':'???? ????? ????? ?? ????? ???? ????????? ?????????????. ?????????? ??????? ????:','sl':'Jezika te spletne strani ni bilo mogoce samodejno dolociti. Prosim navedite jezik:','sv':'Spr%E5ket p%E5 den h%E4r webbplatsen kunde inte avg%F6ras automatiskt. V%E4nligen ange:','tr':'Bu web sitesinin dili otomatik olarak tespit edilememistir. Lütfen dökümanin dilini seçiniz%A0:','uk':'???? ????? ???-????? ?? ???? ???? ????????? ???????????. ???? ?????, ??????? ??????? ????:'},basePath=(function(){var s=document.getElementsByTagName('script'),i=0,p,src,t;while(!!(t=s[i++])){if(!t.src){continue;}src=t.src;p=src.indexOf('Hyphenator.js');if(p!==-1){return src.substring(0,p);}}return'http://hyphenator.googlecode.com/svn/trunk/';}()),isLocal=(function(){var re=false;if(window.location.href.indexOf(basePath)!==-1){re=true;}return re;}()),documentLoaded=false,documentCount=0,contextWindow=window,doFrames=false,dontHyphenate={'script':true,'code':true,'pre':true,'img':true,'br':true,'samp':true,'kbd':true,'var':true,'abbr':true,'acronym':true,'sub':true,'sup':true,'button':true,'option':true,'label':true,'textarea':true,'input':true},enableCache=true,storageType='local',storage,enableReducedPatternSet=false,enableRemoteLoading=true,displayToggleBox=false,hyphenateClass='hyphenate',dontHyphenateClass='donthyphenate',min=6,orphanControl=1,isBookmarklet=(function(){var loc=null,re=false,jsArray=document.getElementsByTagName('script'),i,l;for(i=0,l=jsArray.length;i<l;i++){if(!!jsArray[i].getAttribute('src')){loc=jsArray[i].getAttribute('src');}if(!loc){continue;}else if(loc.indexOf('Hyphenator.js?bm=true')!==-1){re=true;}}return re;}()),mainLanguage=null,elements=[],exceptions={},docLanguages={},state=0,url='(\\w*:\/\/)?((\\w*:)?(\\w*)@)?((([\\d]{1,3}\\.){3}([\\d]{1,3}))|((www\\.|[a-zA-Z]\\.)?[a-zA-Z0-9\\-\\.]+\\.([a-z]{2,4})))(:\\d*)?(\/[\\w#!:\\.?\\+=&%@!\\-]*)*',mail='[\\w-\\.]+@[\\w\\.]+',urlOrMailRE=new RegExp('('+url+')|('+mail+')','i'),zeroWidthSpace=(function(){var zws,ua=navigator.userAgent.toLowerCase();zws=String.fromCharCode(8203);if(ua.indexOf('msie 6')!==-1){zws='';}if(ua.indexOf('opera')!==-1&&ua.indexOf('version/10.00')!==-1){zws='';}return zws;}()),createElem=function(tagname,context){context=context||contextWindow;if(document.createElementNS){return context.document.createElementNS('http://www.w3.org/1999/xhtml',tagname);}else if(document.createElement){return context.document.createElement(tagname);}},onHyphenationDone=function(){},onError=function(e){window.alert("Hyphenator.js says:\n\nAn Error ocurred:\n"+e.message);},selectorFunction=function(){var tmp,el=[],i,l;if(document.getElementsByClassName){el=contextWindow.document.getElementsByClassName(hyphenateClass);}else{tmp=contextWindow.document.getElementsByTagName('*');l=tmp.length;for(i=0;i<l;i++){if(tmp[i].className.indexOf(hyphenateClass)!==-1&&tmp[i].className.indexOf(dontHyphenateClass)===-1){el.push(tmp[i]);}}}return el;},intermediateState='hidden',hyphen=String.fromCharCode(173),urlhyphen=zeroWidthSpace,safeCopy=true,Expando=(function(){var container={},name="HyphenatorExpando_"+Math.random(),uuid=0;return{getDataForElem:function(elem){return container[elem[name].id];},setDataForElem:function(elem,data){var id;if(elem[name]&&elem[name].id!==''){id=elem[name].id;}else{id=uuid++;elem[name]={'id':id};}container[id]=data;},appendDataForElem:function(elem,data){var k;for(k in data){if(data.hasOwnProperty(k)){container[elem[name].id][k]=data[k];}}},delDataOfElem:function(elem){delete container[elem[name]];}};}()),runOnContentLoaded=function(w,f){var DOMContentLoaded=function(){},toplevel,hyphRunForThis={};if(documentLoaded&&!hyphRunForThis[w.location.href]){f();hyphRunForThis[w.location.href]=true;return;}function init(context){contextWindow=context||window;if(!hyphRunForThis[contextWindow.location.href]&&(!documentLoaded||contextWindow!=window.parent)){documentLoaded=true;f();hyphRunForThis[contextWindow.location.href]=true;}}function doScrollCheck(){try{document.documentElement.doScroll("left");}catch(error){setTimeout(doScrollCheck,1);return;}init(window);}function doOnLoad(){var i,haveAccess,fl=window.frames.length;if(doFrames&&fl>0){for(i=0;i<fl;i++){haveAccess=undefined;try{haveAccess=window.frames[i].document.toString();}catch(e){haveAccess=undefined;}if(!!haveAccess){init(window.frames[i]);}}contextWindow=window;f();hyphRunForThis[window.location.href]=true;}else{init(window);}}if(document.addEventListener){DOMContentLoaded=function(){document.removeEventListener("DOMContentLoaded",DOMContentLoaded,false);if(doFrames&&window.frames.length>0){return;}else{init(window);}};}else if(document.attachEvent){DOMContentLoaded=function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",DOMContentLoaded);if(doFrames&&window.frames.length>0){return;}else{init(window);}}};}if(document.addEventListener){document.addEventListener("DOMContentLoaded",DOMContentLoaded,false);window.addEventListener("load",doOnLoad,false);}else if(document.attachEvent){document.attachEvent("onreadystatechange",DOMContentLoaded);window.attachEvent("onload",doOnLoad);toplevel=false;try{toplevel=window.frameElement===null;}catch(e){}if(document.documentElement.doScroll&&toplevel){doScrollCheck();}}},getLang=function(el,fallback){if(!!el.getAttribute('lang')){return el.getAttribute('lang').toLowerCase();}try{if(!!el.getAttribute('xml:lang')){return el.getAttribute('xml:lang').toLowerCase();}}catch(ex){}if(el.tagName!=='HTML'){return getLang(el.parentNode,true);}if(fallback){return mainLanguage;}return null;},autoSetMainLanguage=function(w){w=w||contextWindow;var el=w.document.getElementsByTagName('html')[0],m=w.document.getElementsByTagName('meta'),i,text,e,ul;mainLanguage=getLang(el,false);if(!mainLanguage){for(i=0;i<m.length;i++){if(!!m[i].getAttribute('http-equiv')&&(m[i].getAttribute('http-equiv').toLowerCase()==='content-language')){mainLanguage=m[i].getAttribute('content').toLowerCase();}if(!!m[i].getAttribute('name')&&(m[i].getAttribute('name').toLowerCase()==='dc.language')){mainLanguage=m[i].getAttribute('content').toLowerCase();}if(!!m[i].getAttribute('name')&&(m[i].getAttribute('name').toLowerCase()==='language')){mainLanguage=m[i].getAttribute('content').toLowerCase();}}}if(!mainLanguage&&doFrames&&contextWindow!=window.parent){autoSetMainLanguage(window.parent);}if(!mainLanguage){text='';ul=navigator.language?navigator.language:navigator.userLanguage;ul=ul.substring(0,2);if(prompterStrings.hasOwnProperty(ul)){text=prompterStrings[ul];}else{text=prompterStrings.en;}text+=' (ISO 639-1)\n\n'+languageHint;mainLanguage=window.prompt(unescape(text),ul).toLowerCase();}if(!supportedLang.hasOwnProperty(mainLanguage)){if(supportedLang.hasOwnProperty(mainLanguage.split('-')[0])){mainLanguage=mainLanguage.split('-')[0];}else{e=new Error('The language "'+mainLanguage+'" is not yet supported.');throw e;}}},gatherDocumentInfos=function(){var elToProcess,tmp,i=0,process=function(el,hide,lang){var n,i=0,hyphenatorSettings={};if(hide&&intermediateState==='hidden'){if(!!el.getAttribute('style')){hyphenatorSettings.hasOwnStyle=true;}else{hyphenatorSettings.hasOwnStyle=false;}hyphenatorSettings.isHidden=true;el.style.visibility='hidden';}if(el.lang&&typeof(el.lang)==='string'){hyphenatorSettings.language=el.lang.toLowerCase();}else if(lang){hyphenatorSettings.language=lang.toLowerCase();}else{hyphenatorSettings.language=getLang(el,true);}lang=hyphenatorSettings.language;if(supportedLang[lang]){docLanguages[lang]=true;}else{if(supportedLang.hasOwnProperty(lang.split('-')[0])){lang=lang.split('-')[0];hyphenatorSettings.language=lang;}else if(!isBookmarklet){onError(new Error('Language '+lang+' is not yet supported.'));}}Expando.setDataForElem(el,hyphenatorSettings);elements.push(el);while(!!(n=el.childNodes[i++])){if(n.nodeType===1&&!dontHyphenate[n.nodeName.toLowerCase()]&&n.className.indexOf(dontHyphenateClass)===-1&&!(n in elToProcess)){process(n,false,lang);}}};if(isBookmarklet){elToProcess=contextWindow.document.getElementsByTagName('body')[0];process(elToProcess,false,mainLanguage);}else{elToProcess=selectorFunction();while(!!(tmp=elToProcess[i++])){process(tmp,true,'');}}if(!Hyphenator.languages.hasOwnProperty(mainLanguage)){docLanguages[mainLanguage]=true;}else if(!Hyphenator.languages[mainLanguage].prepared){docLanguages[mainLanguage]=true;}if(elements.length>0){Expando.appendDataForElem(elements[elements.length-1],{isLast:true});}},convertPatterns=function(lang){var plen,anfang,ende,pats,pat,key,tmp={};pats=Hyphenator.languages[lang].patterns;for(plen in pats){if(pats.hasOwnProperty(plen)){plen=parseInt(plen,10);anfang=0;ende=plen;while(!!(pat=pats[plen].substring(anfang,ende))){key=pat.replace(/\d/g,'');tmp[key]=pat;anfang=ende;ende+=plen;}}}Hyphenator.languages[lang].patterns=tmp;Hyphenator.languages[lang].patternsConverted=true;},convertExceptionsToObject=function(exc){var w=exc.split(', '),r={},i,l,key;for(i=0,l=w.length;i<l;i++){key=w[i].replace(/-/g,'');if(!r.hasOwnProperty(key)){r[key]=w[i];}}return r;},loadPatterns=function(lang){var url,xhr,head,script;if(supportedLang[lang]&&!Hyphenator.languages[lang]){url=basePath+'patterns/'+supportedLang[lang];}else{return;}if(isLocal&&!isBookmarklet){xhr=null;if(typeof XMLHttpRequest!=='undefined'){xhr=new XMLHttpRequest();}if(!xhr){try{xhr=new ActiveXObject("Msxml2.XMLHTTP");}catch(e){xhr=null;}}if(xhr){xhr.open('HEAD',url,false);xhr.setRequestHeader('Cache-Control','no-cache');xhr.send(null);if(xhr.status===404){onError(new Error('Could not load\n'+url));delete docLanguages[lang];return;}}}if(createElem){head=window.document.getElementsByTagName('head').item(0);script=createElem('script',window);script.src=url;script.type='text/javascript';head.appendChild(script);}},prepareLanguagesObj=function(lang){var lo=Hyphenator.languages[lang],wrd;if(!lo.prepared){if(enableCache){lo.cache={};lo['cache']=lo.cache;}if(enableReducedPatternSet){lo.redPatSet={};}if(lo.hasOwnProperty('exceptions')){Hyphenator.addExceptions(lang,lo.exceptions);delete lo.exceptions;}if(exceptions.hasOwnProperty('global')){if(exceptions.hasOwnProperty(lang)){exceptions[lang]+=', '+exceptions.global;}else{exceptions[lang]=exceptions.global;}}if(exceptions.hasOwnProperty(lang)){lo.exceptions=convertExceptionsToObject(exceptions[lang]);delete exceptions[lang];}else{lo.exceptions={};}convertPatterns(lang);wrd='[\\w'+lo.specialChars+'@'+String.fromCharCode(173)+'-]{'+min+',}';lo.genRegExp=new RegExp('('+url+')|('+mail+')|('+wrd+')','gi');lo.prepared=true;}if(storage){try{storage.setItem('Hyphenator_'+lang,window.JSON.stringify(lo));}catch(e){}}},prepare=function(callback){var lang,languagesToLoad=0,interval,tmp1,tmp2;if(!enableRemoteLoading){for(lang in Hyphenator.languages){if(Hyphenator.languages.hasOwnProperty(lang)){prepareLanguagesObj(lang);}}state=2;callback();return;}state=1;for(lang in docLanguages){if(docLanguages.hasOwnProperty(lang)){++languagesToLoad;if(storage){if(storage.getItem('Hyphenator_'+lang)){Hyphenator.languages[lang]=window.JSON.parse(storage.getItem('Hyphenator_'+lang));if(exceptions.hasOwnProperty('global')){tmp1=convertExceptionsToObject(exceptions.global);for(tmp2 in tmp1){if(tmp1.hasOwnProperty(tmp2)){Hyphenator.languages[lang].exceptions[tmp2]=tmp1[tmp2];}}}if(exceptions.hasOwnProperty(lang)){tmp1=convertExceptionsToObject(exceptions[lang]);for(tmp2 in tmp1){if(tmp1.hasOwnProperty(tmp2)){Hyphenator.languages[lang].exceptions[tmp2]=tmp1[tmp2];}}delete exceptions[lang];}tmp1='[\\w'+Hyphenator.languages[lang].specialChars+'@'+String.fromCharCode(173)+'-]{'+min+',}';Hyphenator.languages[lang].genRegExp=new RegExp('('+url+')|('+mail+')|('+tmp1+')','gi');delete docLanguages[lang];--languagesToLoad;continue;}}loadPatterns(lang);}}if(languagesToLoad===0){state=2;callback();return;}interval=window.setInterval(function(){var finishedLoading=false,lang;for(lang in docLanguages){if(docLanguages.hasOwnProperty(lang)){if(!Hyphenator.languages[lang]){finishedLoading=false;break;}else{finishedLoading=true;delete docLanguages[lang];prepareLanguagesObj(lang);}}}if(finishedLoading){window.clearInterval(interval);state=2;callback();}},100);},toggleBox=function(s){var myBox,bdy,myIdAttribute,myTextNode,myClassAttribute;if(!!(myBox=contextWindow.document.getElementById('HyphenatorToggleBox'))){if(s){myBox.firstChild.data='Hy-phe-na-ti-on';}else{myBox.firstChild.data='Hyphenation';}}else{bdy=contextWindow.document.getElementsByTagName('body')[0];myBox=createElem('div',contextWindow);myIdAttribute=contextWindow.document.createAttribute('id');myIdAttribute.nodeValue='HyphenatorToggleBox';myClassAttribute=contextWindow.document.createAttribute('class');myClassAttribute.nodeValue=dontHyphenateClass;myTextNode=contextWindow.document.createTextNode('Hy-phe-na-ti-on');myBox.appendChild(myTextNode);myBox.setAttributeNode(myIdAttribute);myBox.setAttributeNode(myClassAttribute);myBox.onclick=Hyphenator.toggleHyphenation;myBox.style.position='absolute';myBox.style.top='0px';myBox.style.right='0px';myBox.style.margin='0';myBox.style.backgroundColor='#AAAAAA';myBox.style.color='#FFFFFF';myBox.style.font='6pt Arial';myBox.style.letterSpacing='0.2em';myBox.style.padding='3px';myBox.style.cursor='pointer';myBox.style.WebkitBorderBottomLeftRadius='4px';myBox.style.MozBorderRadiusBottomleft='4px';bdy.appendChild(myBox);}},hyphenateWord=function(lang,word){var lo=Hyphenator.languages[lang],parts,i,l,w,wl,s,hypos,p,maxwins,win,pat=false,patk,c,t,n,numb3rs,inserted,hyphenatedword,val;if(word===''){return'';}if(word.indexOf(hyphen)!==-1){return word;}if(enableCache&&lo.cache.hasOwnProperty(word)){return lo.cache[word];}if(lo.exceptions.hasOwnProperty(word)){return lo.exceptions[word].replace(/-/g,hyphen);}if(word.indexOf('-')!==-1){parts=word.split('-');for(i=0,l=parts.length;i<l;i++){parts[i]=hyphenateWord(lang,parts[i]);}return parts.join('-');}w='_'+word+'_';wl=w.length;s=w.split('');if(word.indexOf("'")!==-1){w=w.toLowerCase().replace("'","’");}else{w=w.toLowerCase();}hypos=[];numb3rs={'0':0,'1':1,'2':2,'3':3,'4':4,'5':5,'6':6,'7':7,'8':8,'9':9};n=wl-lo.shortestPattern;for(p=0;p<=n;p++){maxwins=Math.min((wl-p),lo.longestPattern);for(win=lo.shortestPattern;win<=maxwins;win++){if(lo.patterns.hasOwnProperty(patk=w.substring(p,p+win))){pat=lo.patterns[patk];if(enableReducedPatternSet){lo.redPatSet[patk]=pat;}if(typeof pat==='string'){t=0;val=[];for(i=0;i<pat.length;i++){if(!!(c=numb3rs[pat.charAt(i)])){val.push(i-t,c);t++;}}pat=lo.patterns[patk]=val;}}else{continue;}for(i=0;i<pat.length;i++){c=p-1+pat[i];if(!hypos[c]||hypos[c]<pat[i+1]){hypos[c]=pat[i+1];}i++;}}}inserted=0;for(i=lo.leftmin;i<=(word.length-lo.rightmin);i++){if(!!(hypos[i]&1)){s.splice(i+inserted+1,0,hyphen);inserted++;}}hyphenatedword=s.slice(1,-1).join('');if(enableCache){lo.cache[word]=hyphenatedword;}return hyphenatedword;},hyphenateURL=function(url){return url.replace(/([:\/\.\?#&_,;!@]+)/gi,'$&'+urlhyphen);},hyphenateElement=function(el){var hyphenatorSettings=Expando.getDataForElem(el),lang=hyphenatorSettings.language,hyphenate,n,i,controlOrphans=function(part){var h,r;switch(hyphen){case'|':h='\\|';break;case'+':h='\\+';break;case'*':h='\\*';break;default:h=hyphen;}if(orphanControl>=2){r=part.split(' ');r[1]=r[1].replace(new RegExp(h,'g'),'');r[1]=r[1].replace(new RegExp(zeroWidthSpace,'g'),'');r=r.join(' ');}if(orphanControl===3){r=r.replace(/[ ]+/g,String.fromCharCode(160));}return r;};if(Hyphenator.languages.hasOwnProperty(lang)){hyphenate=function(word){if(urlOrMailRE.test(word)){return hyphenateURL(word);}else{return hyphenateWord(lang,word);}};i=0;while(!!(n=el.childNodes[i++])){if(n.nodeType===3&&n.data.length>=min){n.data=n.data.replace(Hyphenator.languages[lang].genRegExp,hyphenate);if(orphanControl!==1){n.data=n.data.replace(/[\S]+ [\S]+$/,controlOrphans);}}}}if(hyphenatorSettings.isHidden&&intermediateState==='hidden'){el.style.visibility='visible';if(!hyphenatorSettings.hasOwnStyle){el.setAttribute('style','');el.removeAttribute('style');}else{if(el.style.removeProperty){el.style.removeProperty('visibility');}else if(el.style.removeAttribute){el.style.removeAttribute('visibility');}}}if(hyphenatorSettings.isLast){state=3;documentCount--;if(documentCount>(-1000)&&documentCount<=0){documentCount=(-2000);onHyphenationDone();}}},removeHyphenationFromElement=function(el){var h,i=0,n;switch(hyphen){case'|':h='\\|';break;case'+':h='\\+';break;case'*':h='\\*';break;default:h=hyphen;}while(!!(n=el.childNodes[i++])){if(n.nodeType===3){n.data=n.data.replace(new RegExp(h,'g'),'');n.data=n.data.replace(new RegExp(zeroWidthSpace,'g'),'');}else if(n.nodeType===1){removeHyphenationFromElement(n);}}},hyphenateDocument=function(){function bind(fun,arg){return function(){return fun(arg);};}var i=0,el;while(!!(el=elements[i++])){if(el.ownerDocument.location.href===contextWindow.location.href){window.setTimeout(bind(hyphenateElement,el),0);}}},removeHyphenationFromDocument=function(){var i=0,el;while(!!(el=elements[i++])){removeHyphenationFromElement(el);}state=4;},registerOnCopy=function(){var body=contextWindow.document.getElementsByTagName('body')[0],shadow,selection,range,rangeShadow,restore,oncopyHandler=function(e){e=e||window.event;var target=e.target||e.srcElement,currDoc=target.ownerDocument,body=currDoc.getElementsByTagName('body')[0],targetWindow='defaultView'in currDoc?currDoc.defaultView:currDoc.parentWindow;if(target.tagName&&dontHyphenate[target.tagName.toLowerCase()]){return;}shadow=currDoc.createElement('div');shadow.style.overflow='hidden';shadow.style.position='absolute';shadow.style.top='-5000px';shadow.style.height='1px';body.appendChild(shadow);if(window.getSelection){selection=targetWindow.getSelection();range=selection.getRangeAt(0);shadow.appendChild(range.cloneContents());removeHyphenationFromElement(shadow);selection.selectAllChildren(shadow);restore=function(){shadow.parentNode.removeChild(shadow);selection.addRange(range);};}else{selection=targetWindow.document.selection;range=selection.createRange();shadow.innerHTML=range.htmlText;removeHyphenationFromElement(shadow);rangeShadow=body.createTextRange();rangeShadow.moveToElementText(shadow);rangeShadow.select();restore=function(){shadow.parentNode.removeChild(shadow);if(range.text!==""){range.select();}};}window.setTimeout(restore,0);};if(!body){return;}if(window.addEventListener){body.addEventListener("copy",oncopyHandler,false);}else{body.attachEvent("oncopy",oncopyHandler);}};return{version:'X.Y.Z',languages:{},config:function(obj){var assert=function(name,type){if(typeof obj[name]===type){return true;}else{onError(new Error('Config onError: '+name+' must be of type '+type));return false;}},key;for(key in obj){if(obj.hasOwnProperty(key)){switch(key){case'classname':if(assert('classname','string')){hyphenateClass=obj[key];}break;case'donthyphenateclassname':if(assert('donthyphenateclassname','string')){dontHyphenateClass=obj[key];}break;case'minwordlength':if(assert('minwordlength','number')){min=obj[key];}break;case'hyphenchar':if(assert('hyphenchar','string')){if(obj.hyphenchar==='­'){obj.hyphenchar=String.fromCharCode(173);}hyphen=obj[key];}break;case'urlhyphenchar':if(obj.hasOwnProperty('urlhyphenchar')){if(assert('urlhyphenchar','string')){urlhyphen=obj[key];}}break;case'togglebox':if(assert('togglebox','function')){toggleBox=obj[key];}break;case'displaytogglebox':if(assert('displaytogglebox','boolean')){displayToggleBox=obj[key];}break;case'remoteloading':if(assert('remoteloading','boolean')){enableRemoteLoading=obj[key];}break;case'enablecache':if(assert('enablecache','boolean')){enableCache=obj[key];}break;case'enablereducedpatternset':if(assert('enablereducedpatternset','boolean')){enableReducedPatternSet=obj[key];}break;case'onhyphenationdonecallback':if(assert('onhyphenationdonecallback','function')){onHyphenationDone=obj[key];}break;case'onerrorhandler':if(assert('onerrorhandler','function')){onError=obj[key];}break;case'intermediatestate':if(assert('intermediatestate','string')){intermediateState=obj[key];}break;case'selectorfunction':if(assert('selectorfunction','function')){selectorFunction=obj[key];}break;case'safecopy':if(assert('safecopy','boolean')){safeCopy=obj[key];}break;case'doframes':if(assert('doframes','boolean')){doFrames=obj[key];}break;case'storagetype':if(assert('storagetype','string')){storageType=obj[key];}break;case'orphancontrol':if(assert('orphancontrol','number')){orphanControl=obj[key];}break;default:onError(new Error('Hyphenator.config: property '+key+' not known.'));}}}},run:function(){documentCount=0;var process=function(){try{if(contextWindow.document.getElementsByTagName('frameset').length>0){return;}documentCount++;autoSetMainLanguage(undefined);gatherDocumentInfos();prepare(hyphenateDocument);if(displayToggleBox){toggleBox(true);}if(safeCopy){registerOnCopy();}}catch(e){onError(e);}},i,haveAccess,fl=window.frames.length;try{if(storageType!=='none'&&typeof(window.localStorage)!=='undefined'&&typeof(window.sessionStorage)!=='undefined'&&typeof(window.JSON.stringify)!=='undefined'&&typeof(window.JSON.parse)!=='undefined'){switch(storageType){case'session':storage=window.sessionStorage;break;case'local':storage=window.localStorage;break;default:storage=undefined;break;}}}catch(f){}if(!documentLoaded&&!isBookmarklet){runOnContentLoaded(window,process);}if(isBookmarklet||documentLoaded){if(doFrames&&fl>0){for(i=0;i<fl;i++){haveAccess=undefined;try{haveAccess=window.frames[i].document.toString();}catch(e){haveAccess=undefined;}if(!!haveAccess){contextWindow=window.frames[i];process();}}}contextWindow=window;process();}},addExceptions:function(lang,words){if(lang===''){lang='global';}if(exceptions.hasOwnProperty(lang)){exceptions[lang]+=", "+words;}else{exceptions[lang]=words;}},hyphenate:function(target,lang){var hyphenate,n,i;if(Hyphenator.languages.hasOwnProperty(lang)){if(!Hyphenator.languages[lang].prepared){prepareLanguagesObj(lang);}hyphenate=function(word){if(urlOrMailRE.test(word)){return hyphenateURL(word);}else{return hyphenateWord(lang,word);}};if(typeof target==='string'||target.constructor===String){return target.replace(Hyphenator.languages[lang].genRegExp,hyphenate);}else if(typeof target==='object'){i=0;while(!!(n=target.childNodes[i++])){if(n.nodeType===3&&n.data.length>=min){n.data=n.data.replace(Hyphenator.languages[lang].genRegExp,hyphenate);}else if(n.nodeType===1){if(n.lang!==''){Hyphenator.hyphenate(n,n.lang);}else{Hyphenator.hyphenate(n,lang);}}}}}else{onError(new Error('Language "'+lang+'" is not loaded.'));}},getRedPatternSet:function(lang){return Hyphenator.languages[lang].redPatSet;},isBookmarklet:function(){return isBookmarklet;},getConfigFromURI:function(){var loc=null,re={},jsArray=document.getElementsByTagName('script'),i,j,l,s,gp,option;for(i=0,l=jsArray.length;i<l;i++){if(!!jsArray[i].getAttribute('src')){loc=jsArray[i].getAttribute('src');}if(!loc){continue;}else{s=loc.indexOf('Hyphenator.js?');if(s===-1){continue;}gp=loc.substring(s+14).split('&');for(j=0;j<gp.length;j++){option=gp[j].split('=');if(option[0]==='bm'){continue;}if(option[1]==='true'){re[option[0]]=true;continue;}if(option[1]==='false'){re[option[0]]=false;continue;}if(isFinite(option[1])){re[option[0]]=parseInt(option[1],10);continue;}if(option[0]==='onhyphenationdonecallback'){re[option[0]]=new Function('',option[1]);continue;}re[option[0]]=option[1];}break;}}return re;},toggleHyphenation:function(){switch(state){case 3:removeHyphenationFromDocument();toggleBox(false);break;case 4:hyphenateDocument();toggleBox(true);break;}}};}(window));Hyphenator['languages']=Hyphenator.languages;Hyphenator['config']=Hyphenator.config;Hyphenator['run']=Hyphenator.run;Hyphenator['addExceptions']=Hyphenator.addExceptions;Hyphenator['hyphenate']=Hyphenator.hyphenate;Hyphenator['getRedPatternSet']=Hyphenator.getRedPatternSet;Hyphenator['isBookmarklet']=Hyphenator.isBookmarklet;Hyphenator['getConfigFromURI']=Hyphenator.getConfigFromURI;Hyphenator['toggleHyphenation']=Hyphenator.toggleHyphenation;window['Hyphenator']=Hyphenator;if(Hyphenator.isBookmarklet()){Hyphenator.config({displaytogglebox:true,intermediatestate:'visible',doframes:true});Hyphenator.config(Hyphenator.getConfigFromURI());Hyphenator.run();}Hyphenator.languages['en-us']=Hyphenator.languages['en']={leftmin:2,rightmin:2,shortestPattern:2,longestPattern:9,specialChars:"",patterns:{3:"x1qei2e1je1f1to2tlou2w3c1tue1q4tvtw41tyo1q4tz4tcd2yd1wd1v1du1ta4eu1pas4y1droo2d1psw24sv1dod1m1fad1j1su4fdo2n4fh1fi4fm4fn1fopd42ft3fu1fy1ga2sss1ru5jd5cd1bg3bgd44uk2ok1cyo5jgl2g1m4pf4pg1gog3p1gr1soc1qgs2oi2g3w1gysk21coc5nh1bck1h1fh1h4hk1zo1ci4zms2hh1w2ch5zl2idc3c2us2igi3hi3j4ik1cab1vsa22btr1w4bp2io2ipu3u4irbk4b1j1va2ze2bf4oar1p4nz4zbi1u2iv4iy5ja1jeza1y1wk1bk3fkh4k1ikk4k1lk1mk5tk1w2ldr1mn1t2lfr1lr3j4ljl1l2lm2lp4ltn1rrh4v4yn1q1ly1maw1brg2r1fwi24ao2mhw4kr1cw5p4mkm1m1mo4wtwy4x1ar1ba2nn5mx1ex1h4mtx3i1muqu2p3wx3o4mwa1jx3p1naai2x1ua2fxx4y1ba2dn1jy1cn3fpr2y1dy1i",4:"4dryn2itni4on1inn1im_up3nik4ni4dy5giye4tyes4_ye44ab_nhe4nha4abe2n2gyn1guy1ery5eep2pe4abry3lay3lone4wne4v1nesy3chn1erne2q3neo1nenp2seps4hy2cey5lu2nedne2cyme44nk2y5at2adine2b2ne_y5ac2p1tp2ten1den1cun1cryn5dp2th4adup4twpub3ae4rxu3ayn5gaff4pue4n2au4p1ppuf4n2atag1ipu4mag1na2gon4asx3tix1t2pu2na4gya3haa3heah4la3ho_ti2a5ian2an5puspu2tnak4_th2n1kl_te4_ta4mu4u4mupmun23mum2alex4ob_sy25ynxal1i_st4y1o4xi5cxi5a4alm_si2_sh2m5sixhu4m4sh4m3r4amam2py2rabm2pixhi2yo5dr2ai4m1pmo2vmos2x2edmo2r4n1la2mor2asx3c2xas5yom4x4apxam3nme44mokrbi2nne44andy4osp4ot3noemn4omn4a4m1n4nog4m1l2angws4l1posw3shwri4wra4yp3iwom11wo2m2izrb4ow4nopo4pr2cem2isrd2iano4mig4y3pomi3awiz55mi_no4n4m1fme4v2re_wir42mes1menme2mme2gre1o2med4me_4nop4m5c4m1bwil21noureu2whi4w3ev4maprev2w1era2plpo4crfu4r4fyy5pu2maha3pu2mab2a2rn1p4npi44lyb4lya2p3nwam42l1w1lut4luplu3or1glluf4lu5a2wacltu2y3rol1tr4vv4r3guyr4rl1te4rh_nru4ar1il2sel4sc4l1rl5prl4plys4c4lovri3ar4ib4lof3lo_ar2par3q_os3ll4oll2i4as_ri1o3vokl2levoi44p1mlka35vo_ns4cas4ll1izr4iqr2is3vivl1it3lika2tan2sen2slrle42l3hlgo3l5gal5frns3mvi4p3ley_od2r2meles24athr4myle2al3drv1inldi4l2de2vilnt2il3civik4lce42l1b4lavv3ifrno4r3nua1trr2ocnt4sy4sok4syks4la2tuk4sck3ouko5ryss4a2tyau4b4klyys1tnu1akis4au3rki4pro4ek4ima2va5ki_nu4dn4umn3uokes4k1erav1irok2ke4g1keek2ed_me2aw3ikal4aws4k5agk3ab3ka_aye4ays4veg3jo4p5ba_4vedjew3n1v24ve_ja4pzar23vatizi4n1w41batba4z2b1bb2beix4o4i5w4b1d4be_rox5nym4nyp4n3za4ittr3por1r4i1ti1bel2ith2itei2su4rs2r1sars4cr2seis1p3betvag4i2sor1shbe3wr1sioad34b3hbi2bbi4d3bie3isf4ise2is_1bilr1sp5va_r5sw_le2uz4eir1ibi2tuxu3r1tiu1v2i1raze4nze4pb2l2uu4mo1biip3iz1eripe4b4louts44b1m4b3no3br3bodi4osbo4eru3aio4mi1ol4io_3booo1ce4inyin1u2insru2n2inn4inl4inkrv4e2inioch42iner3vo4indpi2np4idbt4lb4tob3trry4cry3t2in_o4elbu4ni2muim1i5saiil3v4ilnil1iil5fs1apo3er4b5w5by_bys4_in1sau4i1lazet4u2suo3ev2z1ii2go4igius1p5saw4s5bo2fi4ifti3fl4if_i3etsch2usc22ie4i2dui4dri2diid5dpi3au3ruz4ils1cuz4is4s5d4se_se4a2ce_2ici4ich3ceii1bri5bo1ceni1blse2g5seiibe43cepi2aniam4ur2li2al2i1acet4hy2scew41phy4ch_5phuhu4thu4gche2h4tyh4shur1durc44hr44h5p5sev5sexu1ra4s3fup3p2s3gph3t2sh_ho4g2h1n_he23ciau3pl4h1mci5ch2lozo4m4ciihi2vhi4p2cim2cin4phsu1peu1ouo1geu5osheu4sho4he4th1es4shwun5zun5ysi1bunu45cizo4glck3ihep5he2nh4ed1sioph2l5hazsi2rcly4zte4_ge21siscoe22cog5siu1siv5siz_ga24skes1l2s2leha4m2s1ms3ma1ogyo1h2u1ni3gus3gun2guegu4acov1gth3_eu3g4ros1n4_es3u2nez4zyum2pu1mi3som_ev2oig4cri2gov15goos4opgon2ul5v5goeu3lugob53go_2c1t4ph_g1nog1nic2te4sov4ulsgn4ag4myc4twcud5c4ufc4uipe2t3glo1gleul2igla4_eg23giz3cun5givgi4u3gir5gio1cusul4e2spagil4g1ic5gi__eb4cze41d2a5da_u1laggo44daf2dagg2gege4v1geo1gen2ged3dato1la2ge_ol2dol2i5daypek4p4eed1d42de_4gazol2tuiv3ol2vo2lys1sa2gamgaf4o2meui4n2ui2pe2cd4em4fugi4jku3fl3ufaf2tyf4to1denu4du4pe_2f3sfri2de1ps1si4f5pfos5d3eqs4sls4snfo2rss2tdes25fon4p1b_ci23payss5w2st_de1tf4l2de1v2fin4dey4d1fd4gast2idg1id2gyd1h25di_ud5dfi3au4cy_ch4pav43didu3cud1iff2fyu3crd1inst4r4f1ffev4fer11dio2fedfe4bdir2s2ty4fe_dis1on1au3ca4f5bon1c2ondd5k25far4fagpa1peys45eyc1exps4ul2dlyp4ale3whon3s3do_e1wa5doee5vud4oge1visu2msu2nub4euav4su2rp4ai6rk_d4or3dosu1atdo4v3doxp4adoo4k4swoo2padre4eus4e3upe5un2ophet5z4syc3syl4y3hoy1ads4pd4swd4syd2tho4wo3ta_du2c4etn2tabta2luac4es4wdu4g2ess4uabdu4n4duptav4st5bow1io1pr5dyn2tawe1sp2t1bop1uead1tz4et4chopy5ea4l4t1d4te_2tyle1si4esh1tee4tyat1cr4twoteg4es2c4eru1teoer1s2eroea2tte4po1rat1wh3tusea2v3teu3texer1i2e1ber1h4tey2t1f4t1ge3br2th_th2e4thle1ce3tumec2i2ths2erb1tia4tueer1aou5vtud2tif22tige1potu1aou4lttu41timt5toos4le1cre2pat4swe5owe1cue4ottsh4eos4e1ort4sce3ol4edieo2ge5of1tio4eno4enn5tiq4edoti4u1tive3my1tiz4othee2ct5laee2ft5lo4t1mee2mtme4e1meem5bcoi4to3be5exo1ry2tof1effel2iel2ftos24t1pe1la1traos2ceig2ei5de5ico2soe1h45egyeg5n",5:"_ach4e4go_e4goseg1ule5gurtre5feg4iceher4eg5ibeger44egaltre4mei5gle3imbe3infe1ingtra3beir4deit3eei3the5ity5triae4jud3efiteki4nek4la2trime4la_e4lactri4v4toute4law5toure3leaefil45elece4ledto2rae5len4tonye1lestro3ve4fic4tonoto3mytom4bto2mato5ice5limto2gre3lioe2listru5i4todo4ellaee4tyello4e5locel5ogeest4el2shel4tae5ludel5uge4mace4mage5man2t1n2ee2s4ee4p1e2mele4metee4naemi4eee4lyeel3i3tled3tle_e4mistlan4eed3iem3iztrus4emo4gti3zaem3pie4mule4dulemu3ne4dritiv4aedon2e4dolti3tle5neae5neeen3emtis4pti5sotis4m3tisee3newti3sae5niee5nile3nioedi5zen3ite5niu5enized1ited3imeno4ge4nosen3oven4swti5oc4t1s2en3uaen5ufe3ny_4en3zed3ibe3diae4oi4ede4s3tini4ed3deo3ret2ina2e2dae4culeo4toe5outec4te4t3t2t4tes2t1ine5pel4timpe2corephe4e4plie2col5tigutu3arti5fytu4bie3pro3tienep4sh5tidie4putt4icoeci4t4tick2ti2bec3imera4bti4aber3ar4tuf45tu3ier4bler3che4cib2ere_4thooecca54thil3thet4thea3turethan4e4cade4bitere4qe4ben5turieret4tur5oeav5oeav5itu5ry4tess4tes_ter5ve1rio4eriter4iueri4v1terier3m4ter3cte5pe4t1waer3noeast3er5obe5rocero4rer1oue3assea5sp1tent4ertler3twtwis4eru4t3tende1s4a3tenc5telsear2te2scateli4e3scres5cue1s2ee2sec3tel_te5giear5kear4cte5diear3ae3sha2t1ede5ande2sice2sid5tecttece44teattype3ty5phesi4uea4gees4mie2sole3acte2sone1a4bdys5pdy4sedu4petaun4d3uleta5sytas4e4tare4tarctar4ata5pl2estrta5mo4talke2surtal3idu5eleta4bta5lae3teoua5naet1ic4taf4etin4ta5doe5tir4taciuan4id1ucad1u1ae3trae3tre2d1s2syn5ouar2d4drowet3uaet5ymdro4pdril4dri4b5dreneu3rouar3ieute44draieu5truar3te2vasdop4pe5veadoo3ddoni4u4belsum3iev1erdoli4do4laev3idevi4le4vinevi4ve5voc2d5ofdo5dee4wage5wee4d1n4ewil54d5lue3wit2d3lou3ber5eye_u1b4i3dledfa3blfab3rfa4ce3dle_fain4suit3su5issu2g34d5lasu4b3fa3tasu1al4fato1di1vd2iti5disiuci4bfeas4di1redi4pl4feca5fectdio5gfe3life4mofen2d4st3wuc4it5ferr5diniucle3f4fesf4fie4stry1dinaf4flydi3ge3dictd4icedia5bs4tops1tle5stirs3tifs4ties1ticfic4is5tias4ti_4ficsfi3cuud3ers3thefil5iste2w4filyudev45finas4tedfi2nes2talfin4ns2tagde2tode4suflin4u1dicf2ly5ud5isu5ditde1scd2es_der5sfon4tu4don5dermss4lid4erhfor4is4siede2pudepi4fra4tf5reade3pade3nufril4frol5ud4side3nou4eneuens4ug5infu5el5dem_s5setfu5nefu3rifusi4fus4s4futade5lode5if4dee_5gal_3galiga3lo2d1eds3selg5amos2s5cssas3u1ing4ganouir4mgass4gath3uita4deaf5dav5e5dav44dato4darygeez44spotspor4s4pon4gelydark5s4ply4spio4geno4genydard5ge3omg4ery5gesigeth54getoge4tydan3g4g1g2da2m2g3gergglu5dach4gh3inspil4gh4to4cutr1gi4agia5rula5bspho5g4icogien5s2pheulch42sperspa4n5spai3c4utu1lenul4gigir4lg3islcu5pycu3picu4mic3umecu2maso5vi5glasu5liagli4bg3lig5culiglo3r4ul3mctu4ru1l4og4na_c3terul1tig2ning4nio4ultug4noncta4b4c3s2cru4dul5ulsor5dgo3isum5absor5ccris4go3nic4rinson4gsona45gos_cri5fcre4vum4bi5credg4raigran25solvsoft3so4ceunat44graygre4nco5zi4gritcoz5egruf4cow5ag5stecove4cos4es5menun4ersmel44corbco4pl4gu4tco3pacon5tsman3gy5racon3ghach4hae4mhae4th5aguha3lac4onecon4aun4ims3latu2ninhan4gs3ket5colocol5ihan4kuni3vhap3lhap5ttras4co4grhar2dco5agsir5aclim45sionhas5shaun44clichaz3acle4m1head3hearun3s4s3ingun4sws2ina2s1in4silysil4eh5elohem4p4clarhena45sidiheo5r1c4l4h4eras5icc2c1itu4orsh3ernshor4h3eryci3phshon34cipecion45cinoc1ingc4inahi5anhi4cohigh5h4il2shiv5h4ina3ship3cilihir4lhi3rohir4phir4rsh3iohis4ssh1inci4lau5pia4h1l4hlan44cier5shevcia5rhmet4ch4tish1erh5ods3cho2hoge4chi2z3chitho4mahome3hon4aho5ny3hoodhoon45chiouptu44ura_ho5ruhos4esew4ihos1p1housu4ragses5tu4rasur4behree5se5shs1e4s4h1s24chedh4tarht1enht5esur4fru3rifser4os4erlhun4tsen5gur1inu3riosen4dhy3pehy3phu1ritces5tur3iz4cesa4sencur4no4iancian3i4semeia5peiass45selv5selfi4atu3centse1le4ceniib5iaib3inseg3ruros43cencib3li3cell5cel_s5edli5bun4icam5icap4icar4s4ed3secticas5i4cayiccu44iceour4pe4ced_i5cidsea5wi2cipseas4i4clyur4pi4i1cr5icrai4cryic4teictu2ccon4urti4ic4umic5uoi3curcci4ai4daiccha5ca4thscof4ide4s4casys4cliscle5i5dieid3ios4choid1itid5iui3dlei4domid3owu5sadu5sanid5uous4apied4ecany4ield3s4cesien4ei5enn4sceii1er_i3esci1estus3ciuse5as4cedscav5if4frsca4pi3fieu5siau3siccan4eiga5bcan5d4calous5sli3gibig3ilig3inig3iti4g4lus1trig3orig5oti5greigu5iig1ur2c5ah4i5i44cag4cach4ca1blusur4sat3usa5tab5utoi3legil1erilev4uta4b4butail3iail2ibil3io3sanc2ilitil2izsal4t5bustil3oqil4tyil5uru3tati4magsa5losal4m4ute_4imetbu3res3act5sack2s1ab4imitim4nii3mon4utelbumi4bu3libu4ga4inav4utenbsor42b5s2u4tis4briti3neervi4vr3vic4inga4inger3vey4ingir3ven4ingo4inguu4t1li5ni_i4niain3ioin1isbo4tor5uscrunk5both5b5ota5bos42i1no5boriino4si4not5borein3seru3in2int_ru4glbor5di5nusut5of5bor_uto5gioge4io2grbon4au5tonru3enu4touion3iio5phior3ibod3iio5thi5otiio4toi4ourbne5gb3lisrt4shblen4ip4icr3triip3uli3quar4tivr3tigrti4db4le_b5itzira4bi4racird5ert5ibi4refbi3tri4resir5gibi5ourte5oir4isr3tebr4tagbin4diro4gvac3uir5ul2b3ifis5agis3arisas52is1cis3chbi4eris3erbi5enrson3be5yor5shais3ibisi4di5sisbe3tw4is4krs3es4ismsbe5trr3secva4geis2piis4py4is1sbe3sp4bes4be5nuval5ois1teis1tirrys4rros44be5mis5us4ita_rron4i4tagrri4vi3tani3tatbe3lorri4or4reoit4esbe1libe5gu4itiarre4frre4cbe3giit3igbe3dii2tim2itio4itisrp4h4r3pet4itonr4peait5rybe3debe3dai5tudit3ul4itz_4be2dbeat3beak4ro4varo4tyros4sro5roiv5ioiv1itror3i5root1roomval1ub3berva5mo4izarva5piron4eban3ijac4qban4ebal1ajer5srom4prom4iba4geazz5i5judgay5alax4idax4ickais4aw4ly3awaya1vorav5ocav3igke5liv3el_ve4lov4elyro1feke4tyv4erdv4e2sa5vanav3ag5k2ick4illkilo5au1thk4in_4ves_ro3crkin4gve4teaun5dk5ishau4l2au3gu4kleyaugh3ve4tyk5nes1k2noat3ulkosh4at5uekro5n4k1s2at5uaat4that5te5vianat4sk5vidil4abolaci4l4adela3dylag4nlam3o3landrob3la4tosr4noular4glar3ilas4ea4topr3nivr3nita2tomr5nica4toglbin44l1c2vi5gnat3ifat1ica5tiar3neyr5net4ati_ld5isat4hol4driv2incle4bileft55leg_5leggr4nerr3nel4len_3lencr4nar1lentle3phle4prvin5dler4e3lergr3mitl4eroat5evr4mio5lesq3lessr3menl3eva4vingrma5cvio3lvi1ou4leyevi5rovi3so4l1g4vi3sulgar3l4gesate5cat5apli4agli2amr3lo4li4asr4lisli5bir4ligr2led4lics4vitil4icul3icyl3idaat5ac3lidirk4lel4iffli4flr3ket3lighvit3r4vityriv3iri2tulim3ili4moris4pl4inar3ishris4clin3ir4is_li5og4l4iqlis4pas1trl2it_as4shas5phri2pla4socask3ia3sicl3kallka4ta3sibl4lawashi4l5leal3lecl3legl3lel5riphas4abar2shrin4grin4ear4sarin4dr2inal5lowarre4l5met3rimol4modlmon42l1n2a3roorim5ilo4civo4la5rigil5ogo3loguri5et5longlon4iri1erlood5r4icolop3il3opmlora44ricir4icerib3a5los_v5oleri4agria4blos4tlo4taar2mi2loutar2izar3iolpa5bl3phal5phi4rhall3pit5voltar4im3volv2l1s2vom5ivori4l4siear4fllt5agar4fivo4rylten4vo4talth3ia3reeltis4ar4drw5ablrgo4naraw4lu3brluch4lu3cilu3enwag5olu5idlu4ma5lumia5raur5gitwait5luo3rw5al_luss4r5gisar4atl5venrgi4nara3pwar4tar3alwas4tly5mely3no2lys4l5ysewa1teaque5ma2car3gicma4clr3get5magnwed4nmaid54maldrg3erweet3wee5vwel4lapoc5re4whwest3ap3in4aphires2tr4es_mar3vre5rumas4emas1t5matemath3rero4r4eriap5atr1er4m5bilre1pumbi4vapar4a5nuran3ul4med_an3uare5lure1lian4twre5itmel4tan2trre4fy4antomen4are3fire2fe4menemen4imens4re1de3ment2r2edme5onre4awwin4g5reavme4tare3anme1tere1alm4etr3wiserdin4rdi4aan4stwith3an2span4snan2samid4amid4gan5otwl4esr4dalm4illmin4a3mindrcum3rc4itr3charcen4min4tm4inumiot4wl3ina3niumis5lan3ita3nip4mithan3ioan1gla3neuws4per2bina3nena5neem4ninw5s4tan1dl4mocrrbi4fmo2d1mo4gomois2xac5ex4agor4bagmo3mer4baba3narrau4ta5monrare4rar5cra5nor4aniam1inr2amiam5ifra4lomo3spmoth3m5ouf3mousam3icxer4ixe5roraf4tr5aclm3petra3bixhil5mpi4aam3ag3quetm5pirmp5is3quer2que_qua5vmpov5mp4tram5ab3alyz4m1s25alyt4alysa4ly_ali4exi5di5multx4ime4aldia4laral3adal5abak1enain5opu3trn4abu4nac_na4can5act5putexpe3dna4lia4i4n4naltai5lya3ic_pur4rag5ulnank4nar3c4narenar3inar4ln5arm3agognas4c4ag4l4ageupul3cage4oaga4na4gab3nautnav4e4n1b4ncar5ad5umn3chaa3ducptu4rpti3mnc1innc4itad4suad3owad4len4dain5dana5diua3ditndi4ba3dion1ditn3dizn5ducndu4rnd2we3yar4n3eara3dianeb3uac4um5neckac3ulp4siba3cio5negene4laac1inne5mine4moa3cie4nene4a2cine4poyc5erac1er2p1s2pro1tn2erepro3lner4rych4e2nes_4nesp2nest4neswpri4sycom4n5evea4carab3uln4gabn3gelpre3vpre3rycot4ng5han3gibng1inn5gitn4glangov4ng5shabi5an4gumy4erf4n1h4a5bannhab3a5bal3n4iani3anni4apni3bani4bl_us5ani5dini4erni2fip3petn5igr_ure3_un3up3per_un5op3pennin4g_un5k5nis_p5pel_un1en4ithp4ped_un1ani3tr_to4pympa3_til4n3ketnk3inyn5ic_se2ny4o5gy4onsnmet44n1n2_ru4d5pounnni4vnob4lpo4tan5ocly4ped_ro4qyper5noge4pos1s_ri4gpo4ry1p4or_res2no4mono3my_ree2po4ninon5ipoin2y4poc5po4gpo5em5pod_4noscnos4enos5tno5tayp2ta3noun_ra4cnowl3_pi2tyra5m_pi4eyr5ia_out3_oth32n1s2ns5ab_or3t_or1d_or3cplu4mnsid1nsig4y3s2eys3ion4socns4pen5spiploi4_odd5nta4bpli4n_ni4cn5tib4plignti2fpli3a3plannti4p1p2l23ysis2p3k2ys3ta_mis1nu5enpi2tun3uinp3ithysur4nu1men5umi3nu4nyt3icnu3trz5a2b_li4t_li3o_li2n_li4g_lev1_lep5_len4pion4oard3oas4e3pi1ooat5ip4inoo5barobe4l_la4mo2binpind4_ju3rob3ul_is4i_ir5rp4in_ocif3o4cil_in3so4codpi3lopi3enocre33piec5pidipi3dep5ida_in2kod3icodi3oo2do4odor3pi4cypian4_ine2o5engze3rooe4ta_im3m_id4l_hov5_hi3b_het3_hes3_go4r_gi4bpho4ro5geoo4gero3gie3phobog3it_gi5azo5ol3phizo4groogu5i4z1z22ogyn_fes3ohab5_eye55phieph1icoiff4_en3sph4ero3ing_en3go5ism_to2qans3v_el5d_eer4bbi4to3kenok5iebio5mo4lanper1v4chs_old1eol3erpe5ruo3letol4fi_du4co3liaper3op4ernp4erio5lilpe5ono5liop4encpe4la_do4tpee4do5livcin2q3pediolo4rol5pld3tabol3ub3pedeol3uno5lusedg1le1loaom5ahoma5l2p2edom2beom4bl_de3o3fich3pe4ao4met_co4ro3mia_co3ek3shao5midom1inll1fll3teapa2teo4monom3pi3pare_ca4tlue1pon4aco3nanm2an_pa4pum2en_on5doo3nenng1hoon4guon1ico3nioon1iso5niupa3nypan4ao3nou_bri2pain4ra1oronsu4rk1hopac4tpa4ceon5umonva5_ber4ood5eood5i6rks_oop3io3ordoost5rz1scope5dop1erpa4ca_ba4g_awn4_av4i_au1down5io3pito5pon1sync_as1s_as1p_as3ctch1c_ar5so5ra_ow3elo3visov4enore5auea1mor3eioun2d_ant4orew4or4guou5etou3blo5rilor1ino1rio_ang4o3riuor2miorn2eo5rofoto5sor5pe3orrhor4seo3tisorst4o3tif_an5cor4tyo5rum_al3tos3al_af1tos4ceo4teso4tano5scros2taos4poos4paz2z3wosi4ue3pai",6:"os3ityos3itoz3ian_os4i4ey1stroos5tilos5titxquis3_am5atot3er_ot5erso3scopor3thyweek1noth3i4ot3ic_ot5icao3ticeor3thiors5enor3ougor3ityor3icaouch5i4o5ria_ani5mv1ativore5sho5realus2er__an3teover3sov4erttot3icoviti4o5v4olow3dero4r3agow5esto4posiop3ingo5phero5phanthy3sc3operaontif5on3t4ionten45paganp3agattele2gonspi4on3omyon4odipan3elpan4tyon3keyon5est3oncil_ar4tyswimm6par5diompro5par5elp4a4ripar4isomo4gepa5terst5scrpa5thy_atom5sta1tio5miniom3icaom3ic_ss3hatsky1scpear4lom3ena_ba5naol3umer1veilpedia4ped4icolli4er1treuo5liteol3ishpeli4epe4nano5lis_pen4thol3ingp4era_r1thoup4erago3li4f_bas4er1krauperme5ol5id_o3liceper3tio3lescolass4oi3terpe5tenpe5tiz_be5raoi5son_be3smphar5iphe3nooi5letph4es_oi3deroic3esph5ingr3ial_3ognizo5g2ly1o1gis3phone5phonio5geneo4gatora3mour2amenofit4tof5itera3chupi4ciepoly1eod5dedo5cureoc3ula1pole_5ocritpee2v1param4oc3raco4clamo3chetob5ingob3a3boast5eoke1st3nu3itpi5thanuf4fentu3meoerst2o3chasplas5tn3tinepli5ernti4ernter3sntre1pn4s3esplum4bnsati4npre4cns4moonon1eqnor5abpo3et5n5lessn5oniz5pointpoly5tnon4agnk3rup3nomicng1sprno5l4inois5i4n3o2dno3blenni3aln5keroppa5ran3itor3nitionis4ta5nine_ni3miznd3thrmu2dron3geripray4e5precipre5copre3emm3ma1bpre4lan5gerep3rese3press_can5cmedi2c5pri4e_ce4la3neticpris3op3rocal3chain4er5ipros3en4erarnera5bnel5iz_cit5rne4gatn5d2ifpt5a4bjanu3aign4itn3chisn5chiln5cheon4ces_nau3seid4iosna3talnas5tinan4itnanci4na5mitna5liahnau3zput3er2n1a2bhex2a3hatch1multi3hair1sm4pousg1utanmpo3rim4p1inmp5iesmphas4rach4empar5iraf5figriev1mpara5mo5seyram3et4mora_rane5oran4gemo3ny_monol4rap3er3raphymo3nizgno5morar5ef4raril1g2nacg1leadmoni3ara5vairav3elra5ziemon5gemon5etght1wemoi5sege3o1dmma5ryr5bine3fluoren1dixmis4ti_de3ra_de3rie3chasrch4err4ci4bm4inglm5ineedu2al_3miliame3tryrdi4er_des4crd3ingdi2rerme5thimet3alre5arr3mestim5ersadi2rende2ticdes3icre4cremen4temensu5re3disred5itre4facmen4dede2mosmen5acmem1o3reg3ismel5onm5e5dyme3died2d5ibren4te5mediare5pindd5a5bdata1bmba4t5cle4arma3tisma5scemar4lyre4spichs3huma5riz_dumb5re3strre4terbrus4qre3tribio1rhre5utiman3izre4valrev3elbi1orbbe2vie_eas3ire5vilba1thyman5is5maniamal4tymal4lima5linma3ligmag5inav3ioul5vet4rg3inglus3teanti1dl5umn_ltur3a_el3emltera4ltane5lp5ingloun5dans5gra2cabllos5etlor5ouric5aslo5rie_enam35ricidri4cie5lope_rid5erri3encri3ent_semi5lom3errig5an3logicril3iz5rimanlob5allm3ingrim4pell5out5rina__er4ril5linal2lin4l3le4tl3le4nriph5eliv3er_ge5og_han5k_hi3er_hon3olin3ea1l4inel4im4p_idol3_in3ci_la4cy_lath5rit3iclim4blrit5urriv5elriv3et4l4i4lli4gra_leg5elif3errk4linlid5er4lict_li4cor5licioli4atorl5ish_lig5a_mal5o_man5a_mer3c5less_rm5ersrm3ingy3thinle5sco3l4erilera5b5lene__mon3ele4matld4erild4erela4v4ar1nis44lativ_mo3rola5tanlan4telan5etlan4dllab3ic_mu5takin4dek3est_ro5filk3en4dro5ker5role__of5te4jestyys3icaron4al5izont_os4tlron4tai4v3ot_pe5tero3pelrop3ici5voreiv5il__pio5n_pre3mro4the_ran4tiv3en_rov5eliv3ellit3uati4tramr5pentrp5er__rit5ui4tismrp3ingit5ill_ros5tit3ica4i2tici5terirre4stit3era4ita5mita4bi_row5dist4lyis4ta_is4sesrsa5tiissen4is4sal_sci3erse4crrs5er_islan4rse5v2yo5netish5opis3honr4si4bis5han5iron_ir4minrtach4_self5iri3turten4diri5dei4rel4ire4de_sell5r4tieriq3uidrtil3irtil4lr4tilyr4tistiq5uefip4re4_sing4_ting4yn3chrru3e4lion3at2in4th_tin5krum3pli4no4cin3ityrun4ty_ton4aruti5nymbol5rvel4i_top5irv5er_r5vestin5geni5ness_tou5s_un3cein3cerincel45ryngei4n3auim3ulai5miniimi5lesac3riim5ida_ve5rasalar4ima5ryim3ageill5abil4istsan4deila5rai2l5am_wil5ii4ladeil3a4bsa5voright3iig3eraab5erd4ific_iff5enif5eroi3entiien5a45ie5gaidi5ou3s4cieab5latidi4arid5ianide3al4scopyab5rogid5ancic3ulaac5ardi2c5ocic3ipaic5inase2c3oi4carai4car_se4d4ei2b5riib5iteib5it_ib5ertib3eraac5aroi4ativ4ian4tse4molsen5ata5ceouh4warts5enedhus3t4s5enin4sentd4sentlsep3a34s1er_hun5kehu4min4servohro3poa5chethov5el5se5umhouse3sev3enho5senhort3eho5rishor5at3hol4ehol5arh5odizhlo3riac5robhis3elhion4ehimer4het4edsh5oldhe2s5ph5eroushort5here5aher4bahera3p3side_5sideshen5atsi5diz4signahel4lyact5ifhe3l4ihe5do55sine_h5ecathe4canad4dinsion5aad5er_har4lehard3e3sitioha5rasha3ranhan4tead3icahang5oadi4ersk5inesk5ing5hand_han4cyhan4cislith5hala3mh3ab4lsmall32g5y3n5gui5t3guard5smithad5ranaeri4eag5ellag3onia5guerso4labsol3d2so3licain5in4grada3s4on_gor5ougo5rizgondo5xpan4dait5ens5ophyal3end3g4o4ggnet4tglad5i5g4insgin5ge3g4in_spen4d2s5peog3imen5gies_3spher5giciagh5outsp5ingge5nizge4natge5lizge5lisgel4inxi5miz4gativgar5n4a5le5oga3nizgan5isga5mets5sengs4ses_fu4minfres5cfort5assi4erss5ilyfore5tfor5ayfo5ratal4ia_fon4dessur5aflo3ref5lessfis4tif1in3gstam4i5stands4ta4p5stat_fin2d5al5levs5tero4allicstew5afight5fi5del5ficie5ficiafi3cer5stickf3icena5log_st3ingf3icanama5ra5stockstom3a5stone2f3ic_3storef2f5iss4tradam5ascs4trays4tridf5fin_fend5efeath3fault5fa3thefar5thfam5is4fa4mafall5eew3inge5verbeven4ie5vengevel3oev3ellev5asteva2p5euti5let5roset3roget5rifsy5rinet3ricet5onaam5eraam5ilyami4noamor5ieti4noe5tidetai5loethod3eten4dtal5enes5urramp5enan3ageta5loge5strotan4detanta3ta5pere3ston4es2toes5times3tigta3rizestan43analy4taticta4tures4prean3arces3pertax4ises5onaes3olue5skintch5etanar4ies4i4ntead4ie2s5ima3natiande4sesh5enan3disan4dowang5iete5geres5ences5ecres5cana4n1icte2ma2tem3at3tenanwrita45erwau4tenesert3era3nieser3set5erniz4erniter4nis5ter3de4rivaan3i3fter3isan4imewo5vener3ineeri4ere3rient3ess_teth5e5ericke1ria4er3ester5esser3ent4erenea5nimier5enaer3emoth3easthe5atthe3iser5el_th5ic_th5icaere3in5thinkere5coth5odea5ninee3realan3ishan4klier4che5anniz4erandti4atoanoth5equi3lep5utat4ic1uan4scoe4probep3rehe4predans3poe4precan4surantal4e3penttim5ulep5anceo5rol3tine_eop3aran4tiewin4deap5eroen3ishen5icsen3etren5esten5esien5eroa3pheren3dicap3itae4nanten5amoem5ulaa3pituti3zen5emnize5missem5ishap5olaem5ine3tles_t5let_em1in2apor5iem3icaem5anael3op_el4labapos3te3liv3el5ishaps5esweath3e3lierel3icaar3actwa5verto3nate3libee4l1erel3egato3rietor5iza5radeelaxa4aran4gto3warelan4dej5udie5insttra5chtraci4ar5av4wa5gere5git5arbal4ar5easeg5ing4voteetrem5iar3enta5ressar5ial4tricsvor5abe3finetro5mitron5i4tronyar3iantro3sp5eficia3rieted5uloed3icae4d1erec3ulaec4tane4cremeco5roec3orae4concar5o5de4comme4cluse4clame5citeec5ifya5ronias3anta5sia_tu4nis2t3up_ecan5ce4belstur3ise4bel_eav3ene4a3tue5atifeath3ieat5eneart3eear4ilear4icear5eseam3ereal3oueal5erea5geread5iedum4be4ducts4duct_duc5eras3tenasur5adrea5rat3abl4d5outdo3natdom5izdo5lor4dlessu4bero3dles_at3alou3ble_d4is3tdirt5idi5niz3dine_at5ech5di3endi4cam1d4i3ad3ge4tud5estdev3ilde3strud3iedud3iesdes3tide2s5oat3egovis3itde4nardemor5at3en_uen4teuer4ilde5milat3eraugh3en3demicater5nuil5izdeli4ede5comde4cildecan4de4bonv3io4rdeb5it4dativ2d3a4bat3estu5laticu4tie5ulcheul3dercuss4icu5riaath5em3cultua5thenul3ingul5ishul4lar4vi4naul4liscu5ityctim3ic4ticuuls5esc5tantultra3ct5angcros4ecrop5ocro4pl5critiath5omum4blycre3at5vilitumor5oat5i5b5crat_cras5tcoro3ncop3iccom5ercol3orun5ishco3inc5clareat3ituunt3abat5ropun4tescit3iz4cisti4cista4cipicc5ing_cin3em3cinatuper5s5videsup3ingci2a5b5chini5videdupt5ib5vide_at4tag4ch1inch3ersch3er_ch5ene3chemiche5loure5atur4fercheap3vi5aliat3uravet3er4ch3abc5e4taau5sib3cessives4tece5ram2cen4e4cedenccou3turs5erur5tesur3theaut5enur4tiecav5al4cativave4nover3thcar5omca5percan4tycan3izcan5iscan4icus4lin3versecal4laver3ieca3latca5dencab3in3butiobuss4ebus5iebunt4iv4eresuten4i4u1t2iv3erenu3tineut3ingv4erelbroth35u5tizbound34b1orabon5at5vere_bom4bibol3icblun4t5blespblath5av3erav5enuebi3ogrbi5netven3om2v1a4bvac5ilbi3lizbet5izbe5strva5liebe5nigbbi4nabas4siva5nizbari4aav5ernbarbi5av5eryvel3liazi4eravi4er",7:"_dri5v4ban5dagvar5iedbina5r43bi3tio3bit5ua_ad4derution5auti5lizver5encbuf4ferus5terevermi4ncall5incast5ercas5tigccompa5z3o1phros5itiv5chanicuri4fico5stati5chine_y5che3dupport54v3iden5cific_un4ter_at5omiz4oscopiotele4g5craticu4m3ingv3i3liz4c3retaul4li4bcul4tiscur5a4b4c5utiva5ternauiv4er_del5i5qdem5ic_de4monsdenti5fdern5izdi4latou4b5ingdrag5on5drupliuar5ant5a5si4tec5essawo4k1enec5ifiee4compear5inate4f3eretro5phewide5sp5triciatri5cesefor5ese4fuse_oth5esiar5dinear4chantra5ventrac4tetrac4itar5ativa5ratioel5ativor5est_ar5adisel5ebraton4alie4l5ic_wea5rieel5igibe4l3ingto5cratem5igraem3i3niemoni5oench4erwave1g4a4pillavoice1ption5eewill5inent5age4enthesvaude3vtill5inep5recaep5ti5bva6guer4erati_tho5rizthor5it5thodicer5ence5ternitteri5zater5iesten4tage4sage_e4sagese4sert_an5est_e4sertse4servaes5idenes5ignaesis4tees5piraes4si4btal4lisestruc5e5titioounc5erxe4cutota5bleset5itiva4m5atoa4matis5stratu4f3ical5a5lyst4ficatefill5instern5isspend4gani5zasqual4la4lenti4g3o3nas5ophiz5sophicxpecto55graph_or5angeuri4al_4graphy4gress_smol5d4hang5erh5a5nizharp5enhar5terhel4lishith5erhro5niziam5eteia4tricic4t3uascour5au2r1al_5scin4dover4nescan4t55sa3tiou5do3ny_ven4de_under5ty2p5al_anti5sylla5bliner4arturn3ari5nite_5initioinsur5aion4eryiphras4_tim5o5_ten5an_sta5blrtroph4_se5rieiq3ui3t5i5r2izis5itiviso5mer4istral5i5ticki2t5o5mtsch3ie_re5mittro3fiti4v3er_i4vers_ros5per_pe5titiv3o3ro_ped5alro5n4is_or5ato4jestierom5ete_muta5bk5iness4latelitr4ial__mist5i_me5terr4ming_lev4er__mar5tilev4eralev4ers_mag5a5liar5iz5ligaterit5ers_lat5errit5er_r5ited__im5pinri3ta3blink5er_hon5ey5litica_hero5ior5aliz_hand5irip5lic_gen3t4tolo2gylloqui5_con5grt1li2erbad5ger4operag_eu4lertho3donter2ic__ar4tie_ge4ome_ge5ot1_he3mo1_he3p6a_he3roe_in5u2tpara5bl5tar2rht1a1mintalk1a5ta3gon_par5age_aster5_ne6o3f_noe1thstyl1is_poly1s5pathic_pre1ampa4tricl3o3niz_sem4ic_semid6_semip4_semir45ommend_semiv4lea4s1a_spin1oom5etryspher1o_to6poglo4ratospe3cio3s2paceso2lute_we2b1l_re1e4ca5bolicom5erseaf6fishside5swanal6ysano5a2cside5stl5ties_5lumniasid2ed_anti1reshoe1stscy4th1s4chitzsales5wsales3cat6tes_augh4tlau5li5fom5atizol5ogizo5litiorev5olure5vertre5versbi5d2ifbil2lab_earth5pera5blro1tronro3meshblan2d1blin2d1blon2d2bor1no5ro1bot1re4ti4zr5le5quperi5stper4malbut2ed_but4tedcad5e1moist5enre5stalress5ibchie5vocig3a3roint5er4matizariv1o1lcous2ticri3tie5phisti_be5stoog5ativo2g5a5rr3a3digm4b3ingre4posir4en4tade4als_od5uctsquasis6quasir6re5fer_p5trol3rec5olldic1aiddif5fra3pseu2dr5ebrat5metric2d1lead2d1li2epro2g1epre1neuod5uct_octor5apoin3came5triem5i5liepli5narpara3memin5glim5inglypi4grappal6matmis4er_m5istryeo3graporth1riop1ism__but4tio3normaonom1icfeb1ruafermi1o_de4moio5a5lesodit1icodel3lirb5ing_gen2cy_n4t3ingmo5lestration4get2ic_4g1lishobli2g1mon4ismnsta5blmon4istg2n1or_nov3el3ns5ceivno1vembmpa5rabno4rarymula5r4nom1a6lput4tinput4tedn5o5miz_cam4penag5er_nge5nesh2t1eoun1dieck2ne1skiifac1etncour5ane3backmono1s6mono3chmol1e5cpref5ac3militapre5tenith5i2lnge4n4end5est__capa5bje1re1mma1la1ply5styr1kovian_car5olprin4t3lo2ges_l2l3ishprof5it1s2tamp",8:"lead6er_url5ing_ces5si5bch5a5nis1le1noidlith1o5g_chill5ilar5ce1nym5e5trych5inessation5arload4ed_load6er_la4c3i5elth5i2lyneg5ativ1lunk3erwrit6er_wrap3arotrav5es51ke6linga5rameteman3u1scmar1gin1ap5illar5tisticamedio6c1me3gran3i1tesima3mi3da5bves1titemil2l1agv1er1eigmi6n3is_1verely_e4q3ui3s5tabolizg5rapher5graphicmo5e2lasinfra1s2mon4ey1lim3ped3amo4no1enab5o5liz_cor5nermoth4et2m1ou3sinm5shack2ppo5sitemul2ti5uab5it5abimenta5rignit1ernato5mizhypo1thani5ficatuad1ratu4n5i4an_ho6r1ic_ua3drati5nologishite3sidin5dling_trib5utin5glingnom5e1non1o1mistmpos5itenon1i4so_re5stattro1p2istrof4ic_g2norespgnet1ism5glo5binlem5aticflow2er_fla1g6elntrol5lifit5ted_treach1etra1versl5i5ticso3mecha6_for5mer_de5rivati2n3o1me3spac6i2t3i4an_thy4l1antho1k2er_eq5ui5to4s3phertha4l1amt3ess2es3ter1geiou3ba3dotele1r6ooxi6d1iceli2t1isonspir5apar4a1leed1ulingea4n3iesoc5ratiztch3i1er_kil2n3ipi2c1a3dpli2c1abt6ap6athdrom3e5d_le6icesdrif2t1a_me4ga1l1prema3cdren1a5lpres2plipro2cess_met4ala3do5word1syth3i2_non1e2m_post1ampto3mat4rec5ompepu5bes5cstrib5utqu6a3si31stor1ab_sem6is4star3tliqui3v4arr1abolic_sph6in1de5clar12d3aloneradi1o6gs3qui3tosports3wsports3cra5n2hascro5e2cor3bin1gespokes5wspi2c1il_te3legrcroc1o1d_un3at5t_dictio5cat1a1s2buss4ingbus6i2esbus6i2erbo2t1u1lro5e2las1s2pacinb1i3tivema5rine_r3pau5li_un5err5r5ev5er__vi2c3arback2er_ma5chinesi5resid5losophyan3ti1n2sca6p1ersca2t1olar2rangesep3temb1sci2uttse3mes1tar3che5tsem1a1ph",9:"re4t1ribuuto5maticl3chil6d1a4pe5able1lec3ta6bas5ymptotyes5ter1yl5mo3nell5losophizlo1bot1o1c5laratioba6r1onierse1rad1iro5epide1co6ph1o3nscrap4er_rec5t6angre2c3i1prlai6n3ess1lum5bia_3lyg1a1miec5ificatef5i5nites2s3i4an_1ki5neticjapan1e2smed3i3cinirre6v3ocde2c5linao3les3termil5li5listrat1a1gquain2t1eep5etitiostu1pi4d1v1oir5du1su2per1e6_mi1s4ers3di1methy_mim5i2c1i5nitely_5maph1ro15moc1ra1tmoro6n5isdu1op1o1l_ko6r1te1n3ar4chs_phi2l3ant_ga4s1om1teach4er_parag6ra4o6v3i4an_oth3e1o1sn3ch2es1to5tes3toro5test1eror5tively5nop5o5liha2p3ar5rttrib1ut1_eth1y6l1e2r3i4an_5nop1oly_graph5er_5eu2clid1o1lo3n4omtrai3tor1_ratio5na5mocratiz_rav5en1o",10:"se1mi6t5ic3tro1le1um5sa3par5iloli3gop1o1am1en3ta5bath3er1o1s3slova1kia3s2og1a1myo3no2t1o3nc2tro3me6c1cu2r1ance5noc3er1osth1o5gen1ih3i5pel1a4nfi6n3ites_ever5si5bs2s1a3chu1d1ri3pleg5_ta5pes1trproc3i3ty_s5sign5a3b3rab1o1loiitin5er5arwaste3w6a2mi1n2ut1erde3fin3itiquin5tes5svi1vip3a3r",11:"pseu3d6o3f2s2t1ant5shimi1n2ut1estpseu3d6o3d25tab1o1lismpo3lyph1onophi5lat1e3ltravers3a3bschro1ding12g1o4n3i1zat1ro1pol3it3trop1o5lis3trop1o5lesle3g6en2dreeth1y6l1eneor4tho3ni4t",12:"3ra4m5e1triz1e6p3i3neph1"}};Hyphenator.config({remoteloading:false});Hyphenator.run();
@@ -1,5 +1,3 @@
------ ------ $(function() { $('#gallery a').fancybox(); $('.fancybox').fancybox({@@ -15,19 +13,13 @@ if (posts == 1) { text = posts+" bookmark" };
$('#delcounter').text(text); } $(document).ready(function() { - $('.timeago').timeago(); - // TOC - $("#toc ol").tableOfContents("#content-body", {startLevel: 3, depth: 6, topLinks: "[top]"}); - // Drop Caps - /* - var first_paragraph = $('#content-body p:first'); - if (!first_paragraph) return false; - var t = first_paragraph.html(); - var first_letter = t.substr(0,1); - if (first_letter.match(/[a-z]/i)){ - first_paragraph.html(t.slice(1,t.length)); - $('<span></span>').addClass('dropcap').html(first_letter).prependTo( first_paragraph ); - } - */ - }); + // Manage dates + $('header.home > time').text(Date.today().toString("dddd, MMMM dS yyyy")); + $('header.home > time').attr('datetime', Date.today().toString("yyyy-MM-dd")); + $('.timeago').timeago(); + // Hyphenate contents + Hyphenator.run(); + // TOC + $("#auto-toc ol").tableOfContents("#body-text", {startLevel: 1, depth: 6, topLinks: "↑"}); +});
@@ -1,5 +1,3 @@
------ ------ /* * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ *
@@ -1,5 +1,3 @@
------ ------ /* * FancyBox - simple and fancy jQuery plugin * Examples and documentation at: http://fancy.klade.lv/
@@ -1,5 +1,3 @@
------ ------ /* * timeago: a jQuery plugin, version: 0.7.2 (2009-07-30) * @requires jQuery v1.2 or later
@@ -1,5 +1,3 @@
------ ------ /* TableOfContents Plugin for jQuery (by Doug Neiner)
@@ -1,977 +1,1462 @@
------ ------ /*! - * jQuery JavaScript Library v1.3.2 + * jQuery JavaScript Library v1.4.2 * http://jquery.com/ * - * Copyright (c) 2009 John Resig - * Dual licensed under the MIT and GPL licenses. - * http://docs.jquery.com/License + * Copyright 2010, John Resig + * Dual licensed under the MIT or GPL Version 2 licenses. + * http://jquery.org/license + * + * Includes Sizzle.js + * http://sizzlejs.com/ + * Copyright 2010, The Dojo Foundation + * Released under the MIT, BSD, and GPL Licenses. * - * Date: 2009-02-19 17:34:21 -0500 (Thu, 19 Feb 2009) - * Revision: 6246 + * Date: Sat Feb 13 22:33:48 2010 -0500 */ -(function(){ +(function( window, undefined ) { -var - // Will speed up references to window, and allows munging its name. - window = this, - // Will speed up references to undefined, and allows munging its name. - undefined, +// Define a local copy of jQuery +var jQuery = function( selector, context ) { + // The jQuery object is actually just the init constructor 'enhanced' + return new jQuery.fn.init( selector, context ); + }, + // Map over jQuery in case of overwrite _jQuery = window.jQuery, + // Map over the $ in case of overwrite _$ = window.$, - jQuery = window.jQuery = window.$ = function( selector, context ) { - // The jQuery object is actually just the init constructor 'enhanced' - return new jQuery.fn.init( selector, context ); - }, + // Use the correct document accordingly with window argument (sandbox) + document = window.document, + + // A central reference to the root jQuery(document) + rootjQuery, // A simple way to check for HTML strings or ID strings // (both of which we optimize for) - quickExpr = /^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/, + quickExpr = /^[^<]*(<[\w\W]+>)[^>]*$|^#([\w-]+)$/, + // Is it a simple selector - isSimple = /^.[^:#\[\.,]*$/; + isSimple = /^.[^:#\[\.,]*$/, + + // Check if a string has a non-whitespace character in it + rnotwhite = /\S/, + + // Used for trimming whitespace + rtrim = /^(\s|\u00A0)+|(\s|\u00A0)+$/g, + + // Match a standalone tag + rsingleTag = /^<(\w+)\s*\/?>(?:<\/\1>)?$/, + + // Keep a UserAgent string for use with jQuery.browser + userAgent = navigator.userAgent, + + // For matching the engine and version of the browser + browserMatch, + + // Has the ready events already been bound? + readyBound = false, + + // The functions to execute on DOM ready + readyList = [], + + // The ready event handler + DOMContentLoaded, + + // Save a reference to some core methods + toString = Object.prototype.toString, + hasOwnProperty = Object.prototype.hasOwnProperty, + push = Array.prototype.push, + slice = Array.prototype.slice, + indexOf = Array.prototype.indexOf; jQuery.fn = jQuery.prototype = { init: function( selector, context ) { - // Make sure that a selection was provided - selector = selector || document; + var match, elem, ret, doc; + + // Handle $(""), $(null), or $(undefined) + if ( !selector ) { + return this; + } // Handle $(DOMElement) if ( selector.nodeType ) { - this[0] = selector; + this.context = this[0] = selector; this.length = 1; - this.context = selector; return this; } + + // The body element only exists once, optimize finding it + if ( selector === "body" && !context ) { + this.context = document; + this[0] = document.body; + this.selector = "body"; + this.length = 1; + return this; + } + // Handle HTML strings if ( typeof selector === "string" ) { // Are we dealing with HTML string or an ID? - var match = quickExpr.exec( selector ); + match = quickExpr.exec( selector ); // Verify a match, and that no context was specified for #id if ( match && (match[1] || !context) ) { // HANDLE: $(html) -> $(array) - if ( match[1] ) - selector = jQuery.clean( [ match[1] ], context ); + if ( match[1] ) { + doc = (context ? context.ownerDocument || context : document); + + // If a single string is passed in and it's a single tag + // just do a createElement and skip the rest + ret = rsingleTag.exec( selector ); + + if ( ret ) { + if ( jQuery.isPlainObject( context ) ) { + selector = [ document.createElement( ret[1] ) ]; + jQuery.fn.attr.call( selector, context, true ); + + } else { + selector = [ doc.createElement( ret[1] ) ]; + } + } else { + ret = buildFragment( [ match[1] ], [ doc ] ); + selector = (ret.cacheable ? ret.fragment.cloneNode(true) : ret.fragment).childNodes; + } + + return jQuery.merge( this, selector ); + // HANDLE: $("#id") - else { - var elem = document.getElementById( match[3] ); + } else { + elem = document.getElementById( match[2] ); + + if ( elem ) { + // Handle the case where IE and Opera return items + // by name instead of ID + if ( elem.id !== match[2] ) { + return rootjQuery.find( selector ); + } - // Handle the case where IE and Opera return items - // by name instead of ID - if ( elem && elem.id != match[3] ) - return jQuery().find( selector ); + // Otherwise, we inject the element directly into the jQuery object + this.length = 1; + this[0] = elem; + } - // Otherwise, we inject the element directly into the jQuery object - var ret = jQuery( elem || [] ); - ret.context = document; - ret.selector = selector; - return ret; + this.context = document; + this.selector = selector; + return this; } - // HANDLE: $(expr, [context]) - // (which is just equivalent to: $(content).find(expr) - } else + // HANDLE: $("TAG") + } else if ( !context && /^\w+$/.test( selector ) ) { + this.selector = selector; + this.context = document; + selector = document.getElementsByTagName( selector ); + return jQuery.merge( this, selector ); + + // HANDLE: $(expr, $(...)) + } else if ( !context || context.jquery ) { + return (context || rootjQuery).find( selector ); + + // HANDLE: $(expr, context) + // (which is just equivalent to: $(context).find(expr) + } else { return jQuery( context ).find( selector ); + } // HANDLE: $(function) // Shortcut for document ready - } else if ( jQuery.isFunction( selector ) ) - return jQuery( document ).ready( selector ); + } else if ( jQuery.isFunction( selector ) ) { + return rootjQuery.ready( selector ); + } - // Make sure that old selector state is passed along - if ( selector.selector && selector.context ) { + if (selector.selector !== undefined) { this.selector = selector.selector; this.context = selector.context; } - return this.setArray(jQuery.isArray( selector ) ? - selector : - jQuery.makeArray(selector)); + return jQuery.makeArray( selector, this ); }, // Start with an empty selector selector: "", // The current version of jQuery being used - jquery: "1.3.2", + jquery: "1.4.2", + + // The default length of a jQuery object is 0 + length: 0, // The number of elements contained in the matched element set size: function() { return this.length; }, + toArray: function() { + return slice.call( this, 0 ); + }, + // Get the Nth element in the matched element set OR // Get the whole matched element set as a clean array get: function( num ) { - return num === undefined ? + return num == null ? // Return a 'clean' array - Array.prototype.slice.call( this ) : + this.toArray() : // Return just the object - this[ num ]; + ( num < 0 ? this.slice(num)[ 0 ] : this[ num ] ); }, // Take an array of elements and push it onto the stack // (returning the new matched element set) pushStack: function( elems, name, selector ) { // Build a new jQuery matched element set - var ret = jQuery( elems ); + var ret = jQuery(); + + if ( jQuery.isArray( elems ) ) { + push.apply( ret, elems ); + + } else { + jQuery.merge( ret, elems ); + } // Add the old object onto the stack (as a reference) ret.prevObject = this; ret.context = this.context; - if ( name === "find" ) + if ( name === "find" ) { ret.selector = this.selector + (this.selector ? " " : "") + selector; - else if ( name ) + } else if ( name ) { ret.selector = this.selector + "." + name + "(" + selector + ")"; + } // Return the newly-formed element set return ret; }, - // Force the current matched set of elements to become - // the specified array of elements (destroying the stack in the process) - // You should use pushStack() in order to do this, but maintain the stack - setArray: function( elems ) { - // Resetting the length to 0, then using the native Array push - // is a super-fast way to populate an object with array-like properties - this.length = 0; - Array.prototype.push.apply( this, elems ); - - return this; - }, - // Execute a callback for every element in the matched set. // (You can seed the arguments with an array of args, but this is // only used internally.) each: function( callback, args ) { return jQuery.each( this, callback, args ); }, + + ready: function( fn ) { + // Attach the listeners + jQuery.bindReady(); - // Determine the position of an element within - // the matched set of elements - index: function( elem ) { - // Locate the position of the desired element - return jQuery.inArray( - // If it receives a jQuery object, the first element is used - elem && elem.jquery ? elem[0] : elem - , this ); + // If the DOM is already ready + if ( jQuery.isReady ) { + // Execute the function immediately + fn.call( document, jQuery ); + + // Otherwise, remember the function for later + } else if ( readyList ) { + // Add the function to the wait list + readyList.push( fn ); + } + + return this; + }, + + eq: function( i ) { + return i === -1 ? + this.slice( i ) : + this.slice( i, +i + 1 ); }, - attr: function( name, value, type ) { - var options = name; + first: function() { + return this.eq( 0 ); + }, - // Look for the case where we're accessing a style value - if ( typeof name === "string" ) - if ( value === undefined ) - return this[0] && jQuery[ type || "attr" ]( this[0], name ); + last: function() { + return this.eq( -1 ); + }, - else { - options = {}; - options[ name ] = value; - } + slice: function() { + return this.pushStack( slice.apply( this, arguments ), + "slice", slice.call(arguments).join(",") ); + }, - // Check to see if we're setting style values - return this.each(function(i){ - // Set all the styles - for ( name in options ) - jQuery.attr( - type ? - this.style : - this, - name, jQuery.prop( this, options[ name ], type, i, name ) - ); - }); + map: function( callback ) { + return this.pushStack( jQuery.map(this, function( elem, i ) { + return callback.call( elem, i, elem ); + })); + }, + + end: function() { + return this.prevObject || jQuery(null); }, - css: function( key, value ) { - // ignore negative width and height values - if ( (key == 'width' || key == 'height') && parseFloat(value) < 0 ) - value = undefined; - return this.attr( key, value, "curCSS" ); - }, + // For internal use only. + // Behaves like an Array's method, not like a jQuery method. + push: push, + sort: [].sort, + splice: [].splice +}; - text: function( text ) { - if ( typeof text !== "object" && text != null ) - return this.empty().append( (this[0] && this[0].ownerDocument || document).createTextNode( text ) ); +// Give the init function the jQuery prototype for later instantiation +jQuery.fn.init.prototype = jQuery.fn; - var ret = ""; +jQuery.extend = jQuery.fn.extend = function() { + // copy reference to target object + var target = arguments[0] || {}, i = 1, length = arguments.length, deep = false, options, name, src, copy; - jQuery.each( text || this, function(){ - jQuery.each( this.childNodes, function(){ - if ( this.nodeType != 8 ) - ret += this.nodeType != 1 ? - this.nodeValue : - jQuery.fn.text( [ this ] ); - }); - }); + // Handle a deep copy situation + if ( typeof target === "boolean" ) { + deep = target; + target = arguments[1] || {}; + // skip the boolean and the target + i = 2; + } - return ret; - }, + // Handle case when target is a string or something (possible in deep copy) + if ( typeof target !== "object" && !jQuery.isFunction(target) ) { + target = {}; + } - wrapAll: function( html ) { - if ( this[0] ) { - // The elements to wrap the target around - var wrap = jQuery( html, this[0].ownerDocument ).clone(); + // extend jQuery itself if only one argument is passed + if ( length === i ) { + target = this; + --i; + } - if ( this[0].parentNode ) - wrap.insertBefore( this[0] ); + for ( ; i < length; i++ ) { + // Only deal with non-null/undefined values + if ( (options = arguments[ i ]) != null ) { + // Extend the base object + for ( name in options ) { + src = target[ name ]; + copy = options[ name ]; - wrap.map(function(){ - var elem = this; + // Prevent never-ending loop + if ( target === copy ) { + continue; + } + + // Recurse if we're merging object literal values or arrays + if ( deep && copy && ( jQuery.isPlainObject(copy) || jQuery.isArray(copy) ) ) { + var clone = src && ( jQuery.isPlainObject(src) || jQuery.isArray(src) ) ? src + : jQuery.isArray(copy) ? [] : {}; - while ( elem.firstChild ) - elem = elem.firstChild; + // Never move original objects, clone them + target[ name ] = jQuery.extend( deep, clone, copy ); - return elem; - }).append(this); + // Don't bring in undefined values + } else if ( copy !== undefined ) { + target[ name ] = copy; + } + } } + } - return this; - }, + // Return the modified object + return target; +}; - wrapInner: function( html ) { - return this.each(function(){ - jQuery( this ).contents().wrapAll( html ); - }); +jQuery.extend({ + noConflict: function( deep ) { + window.$ = _$; + + if ( deep ) { + window.jQuery = _jQuery; + } + + return jQuery; }, + + // Is the DOM ready to be used? Set to true once it occurs. + isReady: false, + + // Handle when the DOM is ready + ready: function() { + // Make sure that the DOM is not already loaded + if ( !jQuery.isReady ) { + // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443). + if ( !document.body ) { + return setTimeout( jQuery.ready, 13 ); + } - wrap: function( html ) { - return this.each(function(){ - jQuery( this ).wrapAll( html ); - }); + // Remember that the DOM is ready + jQuery.isReady = true; + + // If there are functions bound, to execute + if ( readyList ) { + // Execute all of them + var fn, i = 0; + while ( (fn = readyList[ i++ ]) ) { + fn.call( document, jQuery ); + } + + // Reset the list of functions + readyList = null; + } + + // Trigger any bound ready events + if ( jQuery.fn.triggerHandler ) { + jQuery( document ).triggerHandler( "ready" ); + } + } }, + + bindReady: function() { + if ( readyBound ) { + return; + } - append: function() { - return this.domManip(arguments, true, function(elem){ - if (this.nodeType == 1) - this.appendChild( elem ); - }); + readyBound = true; + + // Catch cases where $(document).ready() is called after the + // browser event has already occurred. + if ( document.readyState === "complete" ) { + return jQuery.ready(); + } + + // Mozilla, Opera and webkit nightlies currently support this event + if ( document.addEventListener ) { + // Use the handy event callback + document.addEventListener( "DOMContentLoaded", DOMContentLoaded, false ); + + // A fallback to window.onload, that will always work + window.addEventListener( "load", jQuery.ready, false ); + + // If IE event model is used + } else if ( document.attachEvent ) { + // ensure firing before onload, + // maybe late but safe also for iframes + document.attachEvent("onreadystatechange", DOMContentLoaded); + + // A fallback to window.onload, that will always work + window.attachEvent( "onload", jQuery.ready ); + + // If IE and not a frame + // continually check to see if the document is ready + var toplevel = false; + + try { + toplevel = window.frameElement == null; + } catch(e) {} + + if ( document.documentElement.doScroll && toplevel ) { + doScrollCheck(); + } + } }, - prepend: function() { - return this.domManip(arguments, true, function(elem){ - if (this.nodeType == 1) - this.insertBefore( elem, this.firstChild ); - }); + // See test/unit/core.js for details concerning isFunction. + // Since version 1.3, DOM methods and functions like alert + // aren't supported. They return false on IE (#2968). + isFunction: function( obj ) { + return toString.call(obj) === "[object Function]"; }, - before: function() { - return this.domManip(arguments, false, function(elem){ - this.parentNode.insertBefore( elem, this ); - }); + isArray: function( obj ) { + return toString.call(obj) === "[object Array]"; }, - after: function() { - return this.domManip(arguments, false, function(elem){ - this.parentNode.insertBefore( elem, this.nextSibling ); - }); + isPlainObject: function( obj ) { + // Must be an Object. + // Because of IE, we also have to check the presence of the constructor property. + // Make sure that DOM nodes and window objects don't pass through, as well + if ( !obj || toString.call(obj) !== "[object Object]" || obj.nodeType || obj.setInterval ) { + return false; + } + + // Not own constructor property must be Object + if ( obj.constructor + && !hasOwnProperty.call(obj, "constructor") + && !hasOwnProperty.call(obj.constructor.prototype, "isPrototypeOf") ) { + return false; + } + + // Own properties are enumerated firstly, so to speed up, + // if last one is own, then all properties are own. + + var key; + for ( key in obj ) {} + + return key === undefined || hasOwnProperty.call( obj, key ); }, - end: function() { - return this.prevObject || jQuery( [] ); + isEmptyObject: function( obj ) { + for ( var name in obj ) { + return false; + } + return true; }, + + error: function( msg ) { + throw msg; + }, + + parseJSON: function( data ) { + if ( typeof data !== "string" || !data ) { + return null; + } - // For internal use only. - // Behaves like an Array's method, not like a jQuery method. - push: [].push, - sort: [].sort, - splice: [].splice, + // Make sure leading/trailing whitespace is removed (IE can't handle it) + data = jQuery.trim( data ); + + // Make sure the incoming data is actual JSON + // Logic borrowed from http://json.org/json2.js + if ( /^[\],:{}\s]*$/.test(data.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g, "@") + .replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g, "]") + .replace(/(?:^|:|,)(?:\s*\[)+/g, "")) ) { + + // Try to use the native JSON parser first + return window.JSON && window.JSON.parse ? + window.JSON.parse( data ) : + (new Function("return " + data))(); - find: function( selector ) { - if ( this.length === 1 ) { - var ret = this.pushStack( [], "find", selector ); - ret.length = 0; - jQuery.find( selector, this[0], ret ); - return ret; } else { - return this.pushStack( jQuery.unique(jQuery.map(this, function(elem){ - return jQuery.find( selector, elem ); - })), "find", selector ); + jQuery.error( "Invalid JSON: " + data ); } }, - clone: function( events ) { - // Do the clone - var ret = this.map(function(){ - if ( !jQuery.support.noCloneEvent && !jQuery.isXMLDoc(this) ) { - // IE copies events bound via attachEvent when - // using cloneNode. Calling detachEvent on the - // clone will also remove the events from the orignal - // In order to get around this, we use innerHTML. - // Unfortunately, this means some modifications to - // attributes in IE that are actually only stored - // as properties will not be copied (such as the - // the name attribute on an input). - var html = this.outerHTML; - if ( !html ) { - var div = this.ownerDocument.createElement("div"); - div.appendChild( this.cloneNode(true) ); - html = div.innerHTML; - } + noop: function() {}, + + // Evalulates a script in a global context + globalEval: function( data ) { + if ( data && rnotwhite.test(data) ) { + // Inspired by code by Andrea Giammarchi + // http://webreflection.blogspot.com/2007/08/global-scope-evaluation-and-dom.html + var head = document.getElementsByTagName("head")[0] || document.documentElement, + script = document.createElement("script"); - return jQuery.clean([html.replace(/ jQuery\d+="(?:\d+|null)"/g, "").replace(/^\s*/, "")])[0]; - } else - return this.cloneNode(true); - }); + script.type = "text/javascript"; + + if ( jQuery.support.scriptEval ) { + script.appendChild( document.createTextNode( data ) ); + } else { + script.text = data; + } - // Copy the events from the original to the clone - if ( events === true ) { - var orig = this.find("*").andSelf(), i = 0; + // Use insertBefore instead of appendChild to circumvent an IE6 bug. + // This arises when a base node is used (#2709). + head.insertBefore( script, head.firstChild ); + head.removeChild( script ); + } + }, - ret.find("*").andSelf().each(function(){ - if ( this.nodeName !== orig[i].nodeName ) - return; + nodeName: function( elem, name ) { + return elem.nodeName && elem.nodeName.toUpperCase() === name.toUpperCase(); + }, - var events = jQuery.data( orig[i], "events" ); + // args is for internal usage only + each: function( object, callback, args ) { + var name, i = 0, + length = object.length, + isObj = length === undefined || jQuery.isFunction(object); - for ( var type in events ) { - for ( var handler in events[ type ] ) { - jQuery.event.add( this, type, events[ type ][ handler ], events[ type ][ handler ].data ); + if ( args ) { + if ( isObj ) { + for ( name in object ) { + if ( callback.apply( object[ name ], args ) === false ) { + break; + } + } + } else { + for ( ; i < length; ) { + if ( callback.apply( object[ i++ ], args ) === false ) { + break; } } + } - i++; - }); + // A special, fast, case for the most common use of each + } else { + if ( isObj ) { + for ( name in object ) { + if ( callback.call( object[ name ], name, object[ name ] ) === false ) { + break; + } + } + } else { + for ( var value = object[0]; + i < length && callback.call( value, i, value ) !== false; value = object[++i] ) {} + } } - // Return the cloned set - return ret; + return object; }, - filter: function( selector ) { - return this.pushStack( - jQuery.isFunction( selector ) && - jQuery.grep(this, function(elem, i){ - return selector.call( elem, i ); - }) || - - jQuery.multiFilter( selector, jQuery.grep(this, function(elem){ - return elem.nodeType === 1; - }) ), "filter", selector ); + trim: function( text ) { + return (text || "").replace( rtrim, "" ); }, - closest: function( selector ) { - var pos = jQuery.expr.match.POS.test( selector ) ? jQuery(selector) : null, - closer = 0; + // results is for internal usage only + makeArray: function( array, results ) { + var ret = results || []; - return this.map(function(){ - var cur = this; - while ( cur && cur.ownerDocument ) { - if ( pos ? pos.index(cur) > -1 : jQuery(cur).is(selector) ) { - jQuery.data(cur, "closest", closer); - return cur; - } - cur = cur.parentNode; - closer++; + if ( array != null ) { + // The window, strings (and functions) also have 'length' + // The extra typeof function check is to prevent crashes + // in Safari 2 (See: #3039) + if ( array.length == null || typeof array === "string" || jQuery.isFunction(array) || (typeof array !== "function" && array.setInterval) ) { + push.call( ret, array ); + } else { + jQuery.merge( ret, array ); } - }); - }, + } - not: function( selector ) { - if ( typeof selector === "string" ) - // test special case where just one selector is passed in - if ( isSimple.test( selector ) ) - return this.pushStack( jQuery.multiFilter( selector, this, true ), "not", selector ); - else - selector = jQuery.multiFilter( selector, this ); - - var isArrayLike = selector.length && selector[selector.length - 1] !== undefined && !selector.nodeType; - return this.filter(function() { - return isArrayLike ? jQuery.inArray( this, selector ) < 0 : this != selector; - }); + return ret; }, - add: function( selector ) { - return this.pushStack( jQuery.unique( jQuery.merge( - this.get(), - typeof selector === "string" ? - jQuery( selector ) : - jQuery.makeArray( selector ) - ))); - }, + inArray: function( elem, array ) { + if ( array.indexOf ) { + return array.indexOf( elem ); + } - is: function( selector ) { - return !!selector && jQuery.multiFilter( selector, this ).length > 0; - }, + for ( var i = 0, length = array.length; i < length; i++ ) { + if ( array[ i ] === elem ) { + return i; + } + } - hasClass: function( selector ) { - return !!selector && this.is( "." + selector ); + return -1; }, - val: function( value ) { - if ( value === undefined ) { - var elem = this[0]; + merge: function( first, second ) { + var i = first.length, j = 0; - if ( elem ) { - if( jQuery.nodeName( elem, 'option' ) ) - return (elem.attributes.value || {}).specified ? elem.value : elem.text; - - // We need to handle select boxes special - if ( jQuery.nodeName( elem, "select" ) ) { - var index = elem.selectedIndex, - values = [], - options = elem.options, - one = elem.type == "select-one"; + if ( typeof second.length === "number" ) { + for ( var l = second.length; j < l; j++ ) { + first[ i++ ] = second[ j ]; + } + + } else { + while ( second[j] !== undefined ) { + first[ i++ ] = second[ j++ ]; + } + } - // Nothing was selected - if ( index < 0 ) - return null; + first.length = i; - // Loop through all the selected options - for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i < max; i++ ) { - var option = options[ i ]; + return first; + }, - if ( option.selected ) { - // Get the specifc value for the option - value = jQuery(option).val(); + grep: function( elems, callback, inv ) { + var ret = []; - // We don't need an array for one selects - if ( one ) - return value; + // Go through the array, only saving the items + // that pass the validator function + for ( var i = 0, length = elems.length; i < length; i++ ) { + if ( !inv !== !callback( elems[ i ], i ) ) { + ret.push( elems[ i ] ); + } + } - // Multi-Selects return an array - values.push( value ); - } - } + return ret; + }, - return values; - } + // arg is for internal usage only + map: function( elems, callback, arg ) { + var ret = [], value; - // Everything else, we just grab the value - return (elem.value || "").replace(/\r/g, ""); + // Go through the array, translating each of the items to their + // new value (or values). + for ( var i = 0, length = elems.length; i < length; i++ ) { + value = callback( elems[ i ], i, arg ); + if ( value != null ) { + ret[ ret.length ] = value; } - - return undefined; } - if ( typeof value === "number" ) - value += ''; + return ret.concat.apply( [], ret ); + }, - return this.each(function(){ - if ( this.nodeType != 1 ) - return; + // A global GUID counter for objects + guid: 1, - if ( jQuery.isArray(value) && /radio|checkbox/.test( this.type ) ) - this.checked = (jQuery.inArray(this.value, value) >= 0 || - jQuery.inArray(this.name, value) >= 0); + proxy: function( fn, proxy, thisObject ) { + if ( arguments.length === 2 ) { + if ( typeof proxy === "string" ) { + thisObject = fn; + fn = thisObject[ proxy ]; + proxy = undefined; - else if ( jQuery.nodeName( this, "select" ) ) { - var values = jQuery.makeArray(value); + } else if ( proxy && !jQuery.isFunction( proxy ) ) { + thisObject = proxy; + proxy = undefined; + } + } - jQuery( "option", this ).each(function(){ - this.selected = (jQuery.inArray( this.value, values ) >= 0 || - jQuery.inArray( this.text, values ) >= 0); - }); + if ( !proxy && fn ) { + proxy = function() { + return fn.apply( thisObject || this, arguments ); + }; + } - if ( !values.length ) - this.selectedIndex = -1; + // Set the guid of unique handler to the same of original handler, so it can be removed + if ( fn ) { + proxy.guid = fn.guid = fn.guid || proxy.guid || jQuery.guid++; + } - } else - this.value = value; - }); + // So proxy can be declared as an argument + return proxy; }, - html: function( value ) { - return value === undefined ? - (this[0] ? - this[0].innerHTML.replace(/ jQuery\d+="(?:\d+|null)"/g, "") : - null) : - this.empty().append( value ); - }, + // Use of jQuery.browser is frowned upon. + // More details: http://docs.jquery.com/Utilities/jQuery.browser + uaMatch: function( ua ) { + ua = ua.toLowerCase(); - replaceWith: function( value ) { - return this.after( value ).remove(); - }, + var match = /(webkit)[ \/]([\w.]+)/.exec( ua ) || + /(opera)(?:.*version)?[ \/]([\w.]+)/.exec( ua ) || + /(msie) ([\w.]+)/.exec( ua ) || + !/compatible/.test( ua ) && /(mozilla)(?:.*? rv:([\w.]+))?/.exec( ua ) || + []; - eq: function( i ) { - return this.slice( i, +i + 1 ); + return { browser: match[1] || "", version: match[2] || "0" }; }, - slice: function() { - return this.pushStack( Array.prototype.slice.apply( this, arguments ), - "slice", Array.prototype.slice.call(arguments).join(",") ); - }, + browser: {} +}); - map: function( callback ) { - return this.pushStack( jQuery.map(this, function(elem, i){ - return callback.call( elem, i, elem ); - })); - }, +browserMatch = jQuery.uaMatch( userAgent ); +if ( browserMatch.browser ) { + jQuery.browser[ browserMatch.browser ] = true; + jQuery.browser.version = browserMatch.version; +} - andSelf: function() { - return this.add( this.prevObject ); - }, +// Deprecated, use jQuery.browser.webkit instead +if ( jQuery.browser.webkit ) { + jQuery.browser.safari = true; +} - domManip: function( args, table, callback ) { - if ( this[0] ) { - var fragment = (this[0].ownerDocument || this[0]).createDocumentFragment(), - scripts = jQuery.clean( args, (this[0].ownerDocument || this[0]), fragment ), - first = fragment.firstChild; +if ( indexOf ) { + jQuery.inArray = function( elem, array ) { + return indexOf.call( array, elem ); + }; +} + +// All jQuery objects should point back to these +rootjQuery = jQuery(document); + +// Cleanup functions for the document ready method +if ( document.addEventListener ) { + DOMContentLoaded = function() { + document.removeEventListener( "DOMContentLoaded", DOMContentLoaded, false ); + jQuery.ready(); + }; - if ( first ) - for ( var i = 0, l = this.length; i < l; i++ ) - callback.call( root(this[i], first), this.length > 1 || i > 0 ? - fragment.cloneNode(true) : fragment ); - - if ( scripts ) - jQuery.each( scripts, evalScript ); +} else if ( document.attachEvent ) { + DOMContentLoaded = function() { + // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443). + if ( document.readyState === "complete" ) { + document.detachEvent( "onreadystatechange", DOMContentLoaded ); + jQuery.ready(); } + }; +} + +// The DOM ready check for Internet Explorer +function doScrollCheck() { + if ( jQuery.isReady ) { + return; + } - return this; - - function root( elem, cur ) { - return table && jQuery.nodeName(elem, "table") && jQuery.nodeName(cur, "tr") ? - (elem.getElementsByTagName("tbody")[0] || - elem.appendChild(elem.ownerDocument.createElement("tbody"))) : - elem; - } + try { + // If IE is used, use the trick by Diego Perini + // http://javascript.nwbox.com/IEContentLoaded/ + document.documentElement.doScroll("left"); + } catch( error ) { + setTimeout( doScrollCheck, 1 ); + return; } -}; -// Give the init function the jQuery prototype for later instantiation -jQuery.fn.init.prototype = jQuery.fn; + // and execute any waiting functions + jQuery.ready(); +} function evalScript( i, elem ) { - if ( elem.src ) + if ( elem.src ) { jQuery.ajax({ url: elem.src, async: false, dataType: "script" }); - - else + } else { jQuery.globalEval( elem.text || elem.textContent || elem.innerHTML || "" ); + } - if ( elem.parentNode ) + if ( elem.parentNode ) { elem.parentNode.removeChild( elem ); + } } -function now(){ - return +new Date; +// Mutifunctional method to get and set values to a collection +// The value/s can be optionally by executed if its a function +function access( elems, key, value, exec, fn, pass ) { + var length = elems.length; + + // Setting many attributes + if ( typeof key === "object" ) { + for ( var k in key ) { + access( elems, k, key[k], exec, fn, value ); + } + return elems; + } + + // Setting one attribute + if ( value !== undefined ) { + // Optionally, function values get executed if exec is true + exec = !pass && exec && jQuery.isFunction(value); + + for ( var i = 0; i < length; i++ ) { + fn( elems[i], key, exec ? value.call( elems[i], i, fn( elems[i], key ) ) : value, pass ); + } + + return elems; + } + + // Getting an attribute + return length ? fn( elems[0], key ) : undefined; +} + +function now() { + return (new Date).getTime(); } +(function() { + + jQuery.support = {}; + + var root = document.documentElement, + script = document.createElement("script"), + div = document.createElement("div"), + id = "script" + now(); + + div.style.display = "none"; + div.innerHTML = " <link/><table></table><a href='/a' style='color:red;float:left;opacity:.55;'>a</a><input type='checkbox'/>"; + + var all = div.getElementsByTagName("*"), + a = div.getElementsByTagName("a")[0]; + + // Can't get basic test support + if ( !all || !all.length || !a ) { + return; + } + + jQuery.support = { + // IE strips leading whitespace when .innerHTML is used + leadingWhitespace: div.firstChild.nodeType === 3, + + // Make sure that tbody elements aren't automatically inserted + // IE will insert them into empty tables + tbody: !div.getElementsByTagName("tbody").length, + + // Make sure that link elements get serialized correctly by innerHTML + // This requires a wrapper element in IE + htmlSerialize: !!div.getElementsByTagName("link").length, + + // Get the style information from getAttribute + // (IE uses .cssText insted) + style: /red/.test( a.getAttribute("style") ), + + // Make sure that URLs aren't manipulated + // (IE normalizes it by default) + hrefNormalized: a.getAttribute("href") === "/a", + + // Make sure that element opacity exists + // (IE uses filter instead) + // Use a regex to work around a WebKit issue. See #5145 + opacity: /^0.55$/.test( a.style.opacity ), + + // Verify style float existence + // (IE uses styleFloat instead of cssFloat) + cssFloat: !!a.style.cssFloat, -jQuery.extend = jQuery.fn.extend = function() { - // copy reference to target object - var target = arguments[0] || {}, i = 1, length = arguments.length, deep = false, options; + // Make sure that if no value is specified for a checkbox + // that it defaults to "on". + // (WebKit defaults to "" instead) + checkOn: div.getElementsByTagName("input")[0].value === "on", + + // Make sure that a selected-by-default option has a working selected property. + // (WebKit defaults to false instead of true, IE too, if it's in an optgroup) + optSelected: document.createElement("select").appendChild( document.createElement("option") ).selected, + + parentNode: div.removeChild( div.appendChild( document.createElement("div") ) ).parentNode === null, + + // Will be defined later + deleteExpando: true, + checkClone: false, + scriptEval: false, + noCloneEvent: true, + boxModel: null + }; + + script.type = "text/javascript"; + try { + script.appendChild( document.createTextNode( "window." + id + "=1;" ) ); + } catch(e) {} + + root.insertBefore( script, root.firstChild ); - // Handle a deep copy situation - if ( typeof target === "boolean" ) { - deep = target; - target = arguments[1] || {}; - // skip the boolean and the target - i = 2; + // Make sure that the execution of code works by injecting a script + // tag with appendChild/createTextNode + // (IE doesn't support this, fails, and uses .text instead) + if ( window[ id ] ) { + jQuery.support.scriptEval = true; + delete window[ id ]; + } + + // Test to see if it's possible to delete an expando from an element + // Fails in Internet Explorer + try { + delete script.test; + + } catch(e) { + jQuery.support.deleteExpando = false; } - // Handle case when target is a string or something (possible in deep copy) - if ( typeof target !== "object" && !jQuery.isFunction(target) ) - target = {}; + root.removeChild( script ); - // extend jQuery itself if only one argument is passed - if ( length == i ) { - target = this; - --i; + if ( div.attachEvent && div.fireEvent ) { + div.attachEvent("onclick", function click() { + // Cloning a node shouldn't copy over any + // bound event handlers (IE does this) + jQuery.support.noCloneEvent = false; + div.detachEvent("onclick", click); + }); + div.cloneNode(true).fireEvent("onclick"); } - for ( ; i < length; i++ ) - // Only deal with non-null/undefined values - if ( (options = arguments[ i ]) != null ) - // Extend the base object - for ( var name in options ) { - var src = target[ name ], copy = options[ name ]; + div = document.createElement("div"); + div.innerHTML = "<input type='radio' name='radiotest' checked='checked'/>"; - // Prevent never-ending loop - if ( target === copy ) - continue; + var fragment = document.createDocumentFragment(); + fragment.appendChild( div.firstChild ); - // Recurse if we're merging object values - if ( deep && copy && typeof copy === "object" && !copy.nodeType ) - target[ name ] = jQuery.extend( deep, - // Never move original objects, clone them - src || ( copy.length != null ? [ ] : { } ) - , copy ); + // WebKit doesn't clone checked state correctly in fragments + jQuery.support.checkClone = fragment.cloneNode(true).cloneNode(true).lastChild.checked; - // Don't bring in undefined values - else if ( copy !== undefined ) - target[ name ] = copy; + // Figure out if the W3C box model works as expected + // document.body must exist before we can do this + jQuery(function() { + var div = document.createElement("div"); + div.style.width = div.style.paddingLeft = "1px"; - } + document.body.appendChild( div ); + jQuery.boxModel = jQuery.support.boxModel = div.offsetWidth === 2; + document.body.removeChild( div ).style.display = 'none'; - // Return the modified object - return target; + div = null; + }); + + // Technique from Juriy Zaytsev + // http://thinkweb2.com/projects/prototype/detecting-event-support-without-browser-sniffing/ + var eventSupported = function( eventName ) { + var el = document.createElement("div"); + eventName = "on" + eventName; + + var isSupported = (eventName in el); + if ( !isSupported ) { + el.setAttribute(eventName, "return;"); + isSupported = typeof el[eventName] === "function"; + } + el = null; + + return isSupported; + }; + + jQuery.support.submitBubbles = eventSupported("submit"); + jQuery.support.changeBubbles = eventSupported("change"); + + // release memory in IE + root = script = div = all = a = null; +})(); + +jQuery.props = { + "for": "htmlFor", + "class": "className", + readonly: "readOnly", + maxlength: "maxLength", + cellspacing: "cellSpacing", + rowspan: "rowSpan", + colspan: "colSpan", + tabindex: "tabIndex", + usemap: "useMap", + frameborder: "frameBorder" }; +var expando = "jQuery" + now(), uuid = 0, windowData = {}; -// exclude the following css properties to add px -var exclude = /z-?index|font-?weight|opacity|zoom|line-?height/i, - // cache defaultView - defaultView = document.defaultView || {}, - toString = Object.prototype.toString; +jQuery.extend({ + cache: {}, + + expando:expando, + + // The following elements throw uncatchable exceptions if you + // attempt to add expando properties to them. + noData: { + "embed": true, + "object": true, + "applet": true + }, -jQuery.extend({ - noConflict: function( deep ) { - window.$ = _$; + data: function( elem, name, data ) { + if ( elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()] ) { + return; + } - if ( deep ) - window.jQuery = _jQuery; + elem = elem == window ? + windowData : + elem; - return jQuery; - }, + var id = elem[ expando ], cache = jQuery.cache, thisCache; - // See test/unit/core.js for details concerning isFunction. - // Since version 1.3, DOM methods and functions like alert - // aren't supported. They return false on IE (#2968). - isFunction: function( obj ) { - return toString.call(obj) === "[object Function]"; - }, + if ( !id && typeof name === "string" && data === undefined ) { + return null; + } - isArray: function( obj ) { - return toString.call(obj) === "[object Array]"; - }, + // Compute a unique ID for the element + if ( !id ) { + id = ++uuid; + } - // check if an element is in a (or is an) XML document - isXMLDoc: function( elem ) { - return elem.nodeType === 9 && elem.documentElement.nodeName !== "HTML" || - !!elem.ownerDocument && jQuery.isXMLDoc( elem.ownerDocument ); - }, + // Avoid generating a new cache unless none exists and we + // want to manipulate it. + if ( typeof name === "object" ) { + elem[ expando ] = id; + thisCache = cache[ id ] = jQuery.extend(true, {}, name); - // Evalulates a script in a global context - globalEval: function( data ) { - if ( data && /\S/.test(data) ) { - // Inspired by code by Andrea Giammarchi - // http://webreflection.blogspot.com/2007/08/global-scope-evaluation-and-dom.html - var head = document.getElementsByTagName("head")[0] || document.documentElement, - script = document.createElement("script"); + } else if ( !cache[ id ] ) { + elem[ expando ] = id; + cache[ id ] = {}; + } - script.type = "text/javascript"; - if ( jQuery.support.scriptEval ) - script.appendChild( document.createTextNode( data ) ); - else - script.text = data; + thisCache = cache[ id ]; - // Use insertBefore instead of appendChild to circumvent an IE6 bug. - // This arises when a base node is used (#2709). - head.insertBefore( script, head.firstChild ); - head.removeChild( script ); + // Prevent overriding the named cache with undefined values + if ( data !== undefined ) { + thisCache[ name ] = data; } + + return typeof name === "string" ? thisCache[ name ] : thisCache; }, - nodeName: function( elem, name ) { - return elem.nodeName && elem.nodeName.toUpperCase() == name.toUpperCase(); - }, + removeData: function( elem, name ) { + if ( elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()] ) { + return; + } - // args is for internal usage only - each: function( object, callback, args ) { - var name, i = 0, length = object.length; + elem = elem == window ? + windowData : + elem; - if ( args ) { - if ( length === undefined ) { - for ( name in object ) - if ( callback.apply( object[ name ], args ) === false ) - break; - } else - for ( ; i < length; ) - if ( callback.apply( object[ i++ ], args ) === false ) - break; + var id = elem[ expando ], cache = jQuery.cache, thisCache = cache[ id ]; + + // If we want to remove a specific section of the element's data + if ( name ) { + if ( thisCache ) { + // Remove the section of cache data + delete thisCache[ name ]; + + // If we've removed all the data, remove the element's cache + if ( jQuery.isEmptyObject(thisCache) ) { + jQuery.removeData( elem ); + } + } - // A special, fast, case for the most common use of each + // Otherwise, we want to remove all of the element's data } else { - if ( length === undefined ) { - for ( name in object ) - if ( callback.call( object[ name ], name, object[ name ] ) === false ) - break; - } else - for ( var value = object[0]; - i < length && callback.call( value, i, value ) !== false; value = object[++i] ){} - } + if ( jQuery.support.deleteExpando ) { + delete elem[ jQuery.expando ]; - return object; - }, + } else if ( elem.removeAttribute ) { + elem.removeAttribute( jQuery.expando ); + } - prop: function( elem, value, type, i, name ) { - // Handle executable functions - if ( jQuery.isFunction( value ) ) - value = value.call( elem, i ); + // Completely remove the data cache + delete cache[ id ]; + } + } +}); - // Handle passing in a number to a CSS property - return typeof value === "number" && type == "curCSS" && !exclude.test( name ) ? - value + "px" : - value; - }, +jQuery.fn.extend({ + data: function( key, value ) { + if ( typeof key === "undefined" && this.length ) { + return jQuery.data( this[0] ); - className: { - // internal only, use addClass("class") - add: function( elem, classNames ) { - jQuery.each((classNames || "").split(/\s+/), function(i, className){ - if ( elem.nodeType == 1 && !jQuery.className.has( elem.className, className ) ) - elem.className += (elem.className ? " " : "") + className; + } else if ( typeof key === "object" ) { + return this.each(function() { + jQuery.data( this, key ); }); - }, + } - // internal only, use removeClass("class") - remove: function( elem, classNames ) { - if (elem.nodeType == 1) - elem.className = classNames !== undefined ? - jQuery.grep(elem.className.split(/\s+/), function(className){ - return !jQuery.className.has( classNames, className ); - }).join(" ") : - ""; - }, + var parts = key.split("."); + parts[1] = parts[1] ? "." + parts[1] : ""; + + if ( value === undefined ) { + var data = this.triggerHandler("getData" + parts[1] + "!", [parts[0]]); - // internal only, use hasClass("class") - has: function( elem, className ) { - return elem && jQuery.inArray( className, (elem.className || elem).toString().split(/\s+/) ) > -1; + if ( data === undefined && this.length ) { + data = jQuery.data( this[0], key ); + } + return data === undefined && parts[1] ? + this.data( parts[0] ) : + data; + } else { + return this.trigger("setData" + parts[1] + "!", [parts[0], value]).each(function() { + jQuery.data( this, key, value ); + }); } }, - // A method for quickly swapping in/out CSS properties to get correct calculations - swap: function( elem, options, callback ) { - var old = {}; - // Remember the old values, and insert the new ones - for ( var name in options ) { - old[ name ] = elem.style[ name ]; - elem.style[ name ] = options[ name ]; + removeData: function( key ) { + return this.each(function() { + jQuery.removeData( this, key ); + }); + } +}); +jQuery.extend({ + queue: function( elem, type, data ) { + if ( !elem ) { + return; } - callback.call( elem ); + type = (type || "fx") + "queue"; + var q = jQuery.data( elem, type ); + + // Speed up dequeue by getting out quickly if this is just a lookup + if ( !data ) { + return q || []; + } + + if ( !q || jQuery.isArray(data) ) { + q = jQuery.data( elem, type, jQuery.makeArray(data) ); - // Revert the old values - for ( var name in options ) - elem.style[ name ] = old[ name ]; + } else { + q.push( data ); + } + + return q; }, - css: function( elem, name, force, extra ) { - if ( name == "width" || name == "height" ) { - var val, props = { position: "absolute", visibility: "hidden", display:"block" }, which = name == "width" ? [ "Left", "Right" ] : [ "Top", "Bottom" ]; + dequeue: function( elem, type ) { + type = type || "fx"; - function getWH() { - val = name == "width" ? elem.offsetWidth : elem.offsetHeight; + var queue = jQuery.queue( elem, type ), fn = queue.shift(); - if ( extra === "border" ) - return; + // If the fx queue is dequeued, always remove the progress sentinel + if ( fn === "inprogress" ) { + fn = queue.shift(); + } - jQuery.each( which, function() { - if ( !extra ) - val -= parseFloat(jQuery.curCSS( elem, "padding" + this, true)) || 0; - if ( extra === "margin" ) - val += parseFloat(jQuery.curCSS( elem, "margin" + this, true)) || 0; - else - val -= parseFloat(jQuery.curCSS( elem, "border" + this + "Width", true)) || 0; - }); + if ( fn ) { + // Add a progress sentinel to prevent the fx queue from being + // automatically dequeued + if ( type === "fx" ) { + queue.unshift("inprogress"); } - if ( elem.offsetWidth !== 0 ) - getWH(); - else - jQuery.swap( elem, props, getWH ); + fn.call(elem, function() { + jQuery.dequeue(elem, type); + }); + } + } +}); + +jQuery.fn.extend({ + queue: function( type, data ) { + if ( typeof type !== "string" ) { + data = type; + type = "fx"; + } - return Math.max(0, Math.round(val)); + if ( data === undefined ) { + return jQuery.queue( this[0], type ); } + return this.each(function( i, elem ) { + var queue = jQuery.queue( this, type, data ); - return jQuery.curCSS( elem, name, force ); + if ( type === "fx" && queue[0] !== "inprogress" ) { + jQuery.dequeue( this, type ); + } + }); + }, + dequeue: function( type ) { + return this.each(function() { + jQuery.dequeue( this, type ); + }); }, - curCSS: function( elem, name, force ) { - var ret, style = elem.style; + // Based off of the plugin by Clint Helfers, with permission. + // http://blindsignals.com/index.php/2009/07/jquery-delay/ + delay: function( time, type ) { + time = jQuery.fx ? jQuery.fx.speeds[time] || time : time; + type = type || "fx"; - // We need to handle opacity special in IE - if ( name == "opacity" && !jQuery.support.opacity ) { - ret = jQuery.attr( style, "opacity" ); + return this.queue( type, function() { + var elem = this; + setTimeout(function() { + jQuery.dequeue( elem, type ); + }, time ); + }); + }, - return ret == "" ? - "1" : - ret; - } + clearQueue: function( type ) { + return this.queue( type || "fx", [] ); + } +}); +var rclass = /[\n\t]/g, + rspace = /\s+/, + rreturn = /\r/g, + rspecialurl = /href|src|style/, + rtype = /(button|input)/i, + rfocusable = /(button|input|object|select|textarea)/i, + rclickable = /^(a|area)$/i, + rradiocheck = /radio|checkbox/; - // Make sure we're using the right name for getting the float value - if ( name.match( /float/i ) ) - name = styleFloat; +jQuery.fn.extend({ + attr: function( name, value ) { + return access( this, name, value, true, jQuery.attr ); + }, - if ( !force && style && style[ name ] ) - ret = style[ name ]; + removeAttr: function( name, fn ) { + return this.each(function(){ + jQuery.attr( this, name, "" ); + if ( this.nodeType === 1 ) { + this.removeAttribute( name ); + } + }); + }, - else if ( defaultView.getComputedStyle ) { + addClass: function( value ) { + if ( jQuery.isFunction(value) ) { + return this.each(function(i) { + var self = jQuery(this); + self.addClass( value.call(this, i, self.attr("class")) ); + }); + } - // Only "float" is needed here - if ( name.match( /float/i ) ) - name = "float"; + if ( value && typeof value === "string" ) { + var classNames = (value || "").split( rspace ); - name = name.replace( /([A-Z])/g, "-$1" ).toLowerCase(); + for ( var i = 0, l = this.length; i < l; i++ ) { + var elem = this[i]; - var computedStyle = defaultView.getComputedStyle( elem, null ); + if ( elem.nodeType === 1 ) { + if ( !elem.className ) { + elem.className = value; - if ( computedStyle ) - ret = computedStyle.getPropertyValue( name ); + } else { + var className = " " + elem.className + " ", setClass = elem.className; + for ( var c = 0, cl = classNames.length; c < cl; c++ ) { + if ( className.indexOf( " " + classNames[c] + " " ) < 0 ) { + setClass += " " + classNames[c]; + } + } + elem.className = jQuery.trim( setClass ); + } + } + } + } - // We should always get a number back from opacity - if ( name == "opacity" && ret == "" ) - ret = "1"; + return this; + }, - } else if ( elem.currentStyle ) { - var camelCase = name.replace(/\-(\w)/g, function(all, letter){ - return letter.toUpperCase(); + removeClass: function( value ) { + if ( jQuery.isFunction(value) ) { + return this.each(function(i) { + var self = jQuery(this); + self.removeClass( value.call(this, i, self.attr("class")) ); }); + } - ret = elem.currentStyle[ name ] || elem.currentStyle[ camelCase ]; + if ( (value && typeof value === "string") || value === undefined ) { + var classNames = (value || "").split(rspace); - // From the awesome hack by Dean Edwards - // http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291 + for ( var i = 0, l = this.length; i < l; i++ ) { + var elem = this[i]; - // If we're not dealing with a regular pixel number - // but a number that has a weird ending, we need to convert it to pixels - if ( !/^\d+(px)?$/i.test( ret ) && /^\d/.test( ret ) ) { - // Remember the original values - var left = style.left, rsLeft = elem.runtimeStyle.left; + if ( elem.nodeType === 1 && elem.className ) { + if ( value ) { + var className = (" " + elem.className + " ").replace(rclass, " "); + for ( var c = 0, cl = classNames.length; c < cl; c++ ) { + className = className.replace(" " + classNames[c] + " ", " "); + } + elem.className = jQuery.trim( className ); - // Put in the new values to get a computed value out - elem.runtimeStyle.left = elem.currentStyle.left; - style.left = ret || 0; - ret = style.pixelLeft + "px"; - - // Revert the changed values - style.left = left; - elem.runtimeStyle.left = rsLeft; + } else { + elem.className = ""; + } + } } } - return ret; + return this; }, - clean: function( elems, context, fragment ) { - context = context || document; - - // !context.createElement fails in IE with an error but returns typeof 'object' - if ( typeof context.createElement === "undefined" ) - context = context.ownerDocument || context[0] && context[0].ownerDocument || document; + toggleClass: function( value, stateVal ) { + var type = typeof value, isBool = typeof stateVal === "boolean"; - // If a single string is passed in and it's a single tag - // just do a createElement and skip the rest - if ( !fragment && elems.length === 1 && typeof elems[0] === "string" ) { - var match = /^<(\w+)\s*\/?>$/.exec(elems[0]); - if ( match ) - return [ context.createElement( match[1] ) ]; + if ( jQuery.isFunction( value ) ) { + return this.each(function(i) { + var self = jQuery(this); + self.toggleClass( value.call(this, i, self.attr("class"), stateVal), stateVal ); + }); } - var ret = [], scripts = [], div = context.createElement("div"); + return this.each(function() { + if ( type === "string" ) { + // toggle individual class names + var className, i = 0, self = jQuery(this), + state = stateVal, + classNames = value.split( rspace ); - jQuery.each(elems, function(i, elem){ - if ( typeof elem === "number" ) - elem += ''; + while ( (className = classNames[ i++ ]) ) { + // check each className given, space seperated list + state = isBool ? state : !self.hasClass( className ); + self[ state ? "addClass" : "removeClass" ]( className ); + } - if ( !elem ) - return; + } else if ( type === "undefined" || type === "boolean" ) { + if ( this.className ) { + // store className if set + jQuery.data( this, "__className__", this.className ); + } - // Convert html string into DOM nodes - if ( typeof elem === "string" ) { - // Fix "XHTML"-style tags in all browsers - elem = elem.replace(/(<(\w+)[^>]*?)\/>/g, function(all, front, tag){ - return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i) ? - all : - front + "></" + tag + ">"; - }); + // toggle whole className + this.className = this.className || value === false ? "" : jQuery.data( this, "__className__" ) || ""; + } + }); + }, - // Trim whitespace, otherwise indexOf won't work as expected - var tags = elem.replace(/^\s+/, "").substring(0, 10).toLowerCase(); + hasClass: function( selector ) { + var className = " " + selector + " "; + for ( var i = 0, l = this.length; i < l; i++ ) { + if ( (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) > -1 ) { + return true; + } + } - var wrap = - // option or optgroup - !tags.indexOf("<opt") && - [ 1, "<select multiple='multiple'>", "</select>" ] || + return false; + }, - !tags.indexOf("<leg") && - [ 1, "<fieldset>", "</fieldset>" ] || + val: function( value ) { + if ( value === undefined ) { + var elem = this[0]; - tags.match(/^<(thead|tbody|tfoot|colg|cap)/) && - [ 1, "<table>", "</table>" ] || + if ( elem ) { + if ( jQuery.nodeName( elem, "option" ) ) { + return (elem.attributes.value || {}).specified ? elem.value : elem.text; + } - !tags.indexOf("<tr") && - [ 2, "<table><tbody>", "</tbody></table>" ] || + // We need to handle select boxes special + if ( jQuery.nodeName( elem, "select" ) ) { + var index = elem.selectedIndex, + values = [], + options = elem.options, + one = elem.type === "select-one"; - // <thead> matched above - (!tags.indexOf("<td") || !tags.indexOf("<th")) && - [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ] || + // Nothing was selected + if ( index < 0 ) { + return null; + } - !tags.indexOf("<col") && - [ 2, "<table><tbody></tbody><colgroup>", "</colgroup></table>" ] || + // Loop through all the selected options + for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i < max; i++ ) { + var option = options[ i ]; - // IE can't serialize <link> and <script> tags normally - !jQuery.support.htmlSerialize && - [ 1, "div<div>", "</div>" ] || + if ( option.selected ) { + // Get the specifc value for the option + value = jQuery(option).val(); - [ 0, "", "" ]; + // We don't need an array for one selects + if ( one ) { + return value; + } - // Go to html and back, then peel off extra wrappers - div.innerHTML = wrap[1] + elem + wrap[2]; + // Multi-Selects return an array + values.push( value ); + } + } + + return values; + } + + // Handle the case where in Webkit "" is returned instead of "on" if a value isn't specified + if ( rradiocheck.test( elem.type ) && !jQuery.support.checkOn ) { + return elem.getAttribute("value") === null ? "on" : elem.value; + } + - // Move to the right depth - while ( wrap[0]-- ) - div = div.lastChild; + // Everything else, we just grab the value + return (elem.value || "").replace(rreturn, ""); - // Remove IE's autoinserted <tbody> from table fragments - if ( !jQuery.support.tbody ) { + } + + return undefined; + } - // String was a <table>, *may* have spurious <tbody> - var hasBody = /<tbody/i.test(elem), - tbody = !tags.indexOf("<table") && !hasBody ? - div.firstChild && div.firstChild.childNodes : + var isFunction = jQuery.isFunction(value); - // String was a bare <thead> or <tfoot> - wrap[1] == "<table>" && !hasBody ? - div.childNodes : - []; + return this.each(function(i) { + var self = jQuery(this), val = value; - for ( var j = tbody.length - 1; j >= 0 ; --j ) - if ( jQuery.nodeName( tbody[ j ], "tbody" ) && !tbody[ j ].childNodes.length ) - tbody[ j ].parentNode.removeChild( tbody[ j ] ); + if ( this.nodeType !== 1 ) { + return; + } - } + if ( isFunction ) { + val = value.call(this, i, self.val()); + } - // IE completely kills leading whitespace when innerHTML is used - if ( !jQuery.support.leadingWhitespace && /^\s/.test( elem ) ) - div.insertBefore( context.createTextNode( elem.match(/^\s*/)[0] ), div.firstChild ); - - elem = jQuery.makeArray( div.childNodes ); + // Typecast each time if the value is a Function and the appended + // value is therefore different each time. + if ( typeof val === "number" ) { + val += ""; } - if ( elem.nodeType ) - ret.push( elem ); - else - ret = jQuery.merge( ret, elem ); + if ( jQuery.isArray(val) && rradiocheck.test( this.type ) ) { + this.checked = jQuery.inArray( self.val(), val ) >= 0; - }); + } else if ( jQuery.nodeName( this, "select" ) ) { + var values = jQuery.makeArray(val); - if ( fragment ) { - for ( var i = 0; ret[i]; i++ ) { - if ( jQuery.nodeName( ret[i], "script" ) && (!ret[i].type || ret[i].type.toLowerCase() === "text/javascript") ) { - scripts.push( ret[i].parentNode ? ret[i].parentNode.removeChild( ret[i] ) : ret[i] ); - } else { - if ( ret[i].nodeType === 1 ) - ret.splice.apply( ret, [i + 1, 0].concat(jQuery.makeArray(ret[i].getElementsByTagName("script"))) ); - fragment.appendChild( ret[i] ); + jQuery( "option", this ).each(function() { + this.selected = jQuery.inArray( jQuery(this).val(), values ) >= 0; + }); + + if ( !values.length ) { + this.selectedIndex = -1; } + + } else { + this.value = val; } - - return scripts; - } + }); + } +}); - return ret; +jQuery.extend({ + attrFn: { + val: true, + css: true, + html: true, + text: true, + data: true, + width: true, + height: true, + offset: true }, - - attr: function( elem, name, value ) { + + attr: function( elem, name, value, pass ) { // don't set attributes on text and comment nodes - if (!elem || elem.nodeType == 3 || elem.nodeType == 8) + if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 ) { return undefined; + } + + if ( pass && name in jQuery.attrFn ) { + return jQuery(elem)[name](value); + } - var notxml = !jQuery.isXMLDoc( elem ), + var notxml = elem.nodeType !== 1 || !jQuery.isXMLDoc( elem ), // Whether we are setting (or getting) set = value !== undefined;@@ -979,472 +1464,1209 @@ // Try to normalize/fix the name
name = notxml && jQuery.props[ name ] || name; // Only do all the following if this is a node (faster for style) - // IE elem.getAttribute passes even for style - if ( elem.tagName ) { - + if ( elem.nodeType === 1 ) { // These attributes require special treatment - var special = /href|src|style/.test( name ); + var special = rspecialurl.test( name ); - // Safari mis-reports the default selected property of a hidden option + // Safari mis-reports the default selected property of an option // Accessing the parent's selectedIndex property fixes it - if ( name == "selected" && elem.parentNode ) - elem.parentNode.selectedIndex; + if ( name === "selected" && !jQuery.support.optSelected ) { + var parent = elem.parentNode; + if ( parent ) { + parent.selectedIndex; + + // Make sure that it also works with optgroups, see #5701 + if ( parent.parentNode ) { + parent.parentNode.selectedIndex; + } + } + } // If applicable, access the attribute via the DOM 0 way if ( name in elem && notxml && !special ) { - if ( set ){ + if ( set ) { // We can't allow the type property to be changed (since it causes problems in IE) - if ( name == "type" && jQuery.nodeName( elem, "input" ) && elem.parentNode ) - throw "type property can't be changed"; + if ( name === "type" && rtype.test( elem.nodeName ) && elem.parentNode ) { + jQuery.error( "type property can't be changed" ); + } elem[ name ] = value; } // browsers index elements by id/name on forms, give priority to attributes. - if( jQuery.nodeName( elem, "form" ) && elem.getAttributeNode(name) ) + if ( jQuery.nodeName( elem, "form" ) && elem.getAttributeNode(name) ) { return elem.getAttributeNode( name ).nodeValue; + } // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/ - if ( name == "tabIndex" ) { + if ( name === "tabIndex" ) { var attributeNode = elem.getAttributeNode( "tabIndex" ); - return attributeNode && attributeNode.specified - ? attributeNode.value - : elem.nodeName.match(/(button|input|object|select|textarea)/i) - ? 0 - : elem.nodeName.match(/^(a|area)$/i) && elem.href - ? 0 - : undefined; + + return attributeNode && attributeNode.specified ? + attributeNode.value : + rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ? + 0 : + undefined; } return elem[ name ]; } - if ( !jQuery.support.style && notxml && name == "style" ) - return jQuery.attr( elem.style, "cssText", value ); + if ( !jQuery.support.style && notxml && name === "style" ) { + if ( set ) { + elem.style.cssText = "" + value; + } - if ( set ) + return elem.style.cssText; + } + + if ( set ) { // convert the value to a string (all browsers do this but IE) see #1070 elem.setAttribute( name, "" + value ); + } - var attr = !jQuery.support.hrefNormalized && notxml && special + var attr = !jQuery.support.hrefNormalized && notxml && special ? // Some attributes require a special call on IE - ? elem.getAttribute( name, 2 ) - : elem.getAttribute( name ); + elem.getAttribute( name, 2 ) : + elem.getAttribute( name ); // Non-existent attributes return null, we normalize to undefined return attr === null ? undefined : attr; } // elem is actually elem.style ... set the style + // Using attr for specific style information is now deprecated. Use style instead. + return jQuery.style( elem, name, value ); + } +}); +var rnamespaces = /\.(.*)$/, + fcleanup = function( nm ) { + return nm.replace(/[^\w\s\.\|`]/g, function( ch ) { + return "\\" + ch; + }); + }; + +/* + * A number of helper functions used for managing events. + * Many of the ideas behind this code originated from + * Dean Edwards' addEvent library. + */ +jQuery.event = { + + // Bind an event to an element + // Original by Dean Edwards + add: function( elem, types, handler, data ) { + if ( elem.nodeType === 3 || elem.nodeType === 8 ) { + return; + } + + // For whatever reason, IE has trouble passing the window object + // around, causing it to be cloned in the process + if ( elem.setInterval && ( elem !== window && !elem.frameElement ) ) { + elem = window; + } + + var handleObjIn, handleObj; + + if ( handler.handler ) { + handleObjIn = handler; + handler = handleObjIn.handler; + } + + // Make sure that the function being executed has a unique ID + if ( !handler.guid ) { + handler.guid = jQuery.guid++; + } + + // Init the element's event structure + var elemData = jQuery.data( elem ); + + // If no elemData is found then we must be trying to bind to one of the + // banned noData elements + if ( !elemData ) { + return; + } + + var events = elemData.events = elemData.events || {}, + eventHandle = elemData.handle, eventHandle; + + if ( !eventHandle ) { + elemData.handle = eventHandle = function() { + // Handle the second event of a trigger and when + // an event is called after a page has unloaded + return typeof jQuery !== "undefined" && !jQuery.event.triggered ? + jQuery.event.handle.apply( eventHandle.elem, arguments ) : + undefined; + }; + } + + // Add elem as a property of the handle function + // This is to prevent a memory leak with non-native events in IE. + eventHandle.elem = elem; + + // Handle multiple events separated by a space + // jQuery(...).bind("mouseover mouseout", fn); + types = types.split(" "); + + var type, i = 0, namespaces; + + while ( (type = types[ i++ ]) ) { + handleObj = handleObjIn ? + jQuery.extend({}, handleObjIn) : + { handler: handler, data: data }; + + // Namespaced event handlers + if ( type.indexOf(".") > -1 ) { + namespaces = type.split("."); + type = namespaces.shift(); + handleObj.namespace = namespaces.slice(0).sort().join("."); + + } else { + namespaces = []; + handleObj.namespace = ""; + } + + handleObj.type = type; + handleObj.guid = handler.guid; - // IE uses filters for opacity - if ( !jQuery.support.opacity && name == "opacity" ) { - if ( set ) { - // IE has trouble with opacity if it does not have layout - // Force it by setting the zoom level - elem.zoom = 1; + // Get the current list of functions bound to this event + var handlers = events[ type ], + special = jQuery.event.special[ type ] || {}; + + // Init the event handler queue + if ( !handlers ) { + handlers = events[ type ] = []; + + // Check for a special event handler + // Only use addEventListener/attachEvent if the special + // events handler returns false + if ( !special.setup || special.setup.call( elem, data, namespaces, eventHandle ) === false ) { + // Bind the global event handler to the element + if ( elem.addEventListener ) { + elem.addEventListener( type, eventHandle, false ); - // Set the alpha filter to set the opacity - elem.filter = (elem.filter || "").replace( /alpha\([^)]*\)/, "" ) + - (parseInt( value ) + '' == "NaN" ? "" : "alpha(opacity=" + value * 100 + ")"); + } else if ( elem.attachEvent ) { + elem.attachEvent( "on" + type, eventHandle ); + } + } + } + + if ( special.add ) { + special.add.call( elem, handleObj ); + + if ( !handleObj.handler.guid ) { + handleObj.handler.guid = handler.guid; + } } - return elem.filter && elem.filter.indexOf("opacity=") >= 0 ? - (parseFloat( elem.filter.match(/opacity=([^)]*)/)[1] ) / 100) + '': - ""; + // Add the function to the element's handler list + handlers.push( handleObj ); + + // Keep track of which events have been used, for global triggering + jQuery.event.global[ type ] = true; + } + + // Nullify elem to prevent memory leaks in IE + elem = null; + }, + + global: {}, + + // Detach an event or set of events from an element + remove: function( elem, types, handler, pos ) { + // don't do events on text and comment nodes + if ( elem.nodeType === 3 || elem.nodeType === 8 ) { + return; } - name = name.replace(/-([a-z])/ig, function(all, letter){ - return letter.toUpperCase(); - }); + var ret, type, fn, i = 0, all, namespaces, namespace, special, eventType, handleObj, origType, + elemData = jQuery.data( elem ), + events = elemData && elemData.events; - if ( set ) - elem[ name ] = value; + if ( !elemData || !events ) { + return; + } - return elem[ name ]; - }, + // types is actually an event object here + if ( types && types.type ) { + handler = types.handler; + types = types.type; + } - trim: function( text ) { - return (text || "").replace( /^\s+|\s+$/g, "" ); - }, + // Unbind all events for the element + if ( !types || typeof types === "string" && types.charAt(0) === "." ) { + types = types || ""; - makeArray: function( array ) { - var ret = []; + for ( type in events ) { + jQuery.event.remove( elem, type + types ); + } - if( array != null ){ - var i = array.length; - // The window, strings (and functions) also have 'length' - if( i == null || typeof array === "string" || jQuery.isFunction(array) || array.setInterval ) - ret[0] = array; - else - while( i ) - ret[--i] = array[i]; + return; } - return ret; - }, + // Handle multiple events separated by a space + // jQuery(...).unbind("mouseover mouseout", fn); + types = types.split(" "); + + while ( (type = types[ i++ ]) ) { + origType = type; + handleObj = null; + all = type.indexOf(".") < 0; + namespaces = []; + + if ( !all ) { + // Namespaced event handlers + namespaces = type.split("."); + type = namespaces.shift(); + + namespace = new RegExp("(^|\\.)" + + jQuery.map( namespaces.slice(0).sort(), fcleanup ).join("\\.(?:.*\\.)?") + "(\\.|$)") + } - inArray: function( elem, array ) { - for ( var i = 0, length = array.length; i < length; i++ ) - // Use === because on IE, window == document - if ( array[ i ] === elem ) - return i; + eventType = events[ type ]; - return -1; - }, + if ( !eventType ) { + continue; + } - merge: function( first, second ) { - // We have to loop this way because IE & Opera overwrite the length - // expando of getElementsByTagName - var i = 0, elem, pos = first.length; - // Also, we need to make sure that the correct elements are being returned - // (IE returns comment nodes in a '*' query) - if ( !jQuery.support.getAll ) { - while ( (elem = second[ i++ ]) != null ) - if ( elem.nodeType != 8 ) - first[ pos++ ] = elem; + if ( !handler ) { + for ( var j = 0; j < eventType.length; j++ ) { + handleObj = eventType[ j ]; - } else - while ( (elem = second[ i++ ]) != null ) - first[ pos++ ] = elem; + if ( all || namespace.test( handleObj.namespace ) ) { + jQuery.event.remove( elem, origType, handleObj.handler, j ); + eventType.splice( j--, 1 ); + } + } - return first; + continue; + } + + special = jQuery.event.special[ type ] || {}; + + for ( var j = pos || 0; j < eventType.length; j++ ) { + handleObj = eventType[ j ]; + + if ( handler.guid === handleObj.guid ) { + // remove the given handler for the given type + if ( all || namespace.test( handleObj.namespace ) ) { + if ( pos == null ) { + eventType.splice( j--, 1 ); + } + + if ( special.remove ) { + special.remove.call( elem, handleObj ); + } + } + + if ( pos != null ) { + break; + } + } + } + + // remove generic event handler if no more handlers exist + if ( eventType.length === 0 || pos != null && eventType.length === 1 ) { + if ( !special.teardown || special.teardown.call( elem, namespaces ) === false ) { + removeEvent( elem, type, elemData.handle ); + } + + ret = null; + delete events[ type ]; + } + } + + // Remove the expando if it's no longer used + if ( jQuery.isEmptyObject( events ) ) { + var handle = elemData.handle; + if ( handle ) { + handle.elem = null; + } + + delete elemData.events; + delete elemData.handle; + + if ( jQuery.isEmptyObject( elemData ) ) { + jQuery.removeData( elem ); + } + } }, - unique: function( array ) { - var ret = [], done = {}; + // bubbling is internal + trigger: function( event, data, elem /*, bubbling */ ) { + // Event object or event type + var type = event.type || event, + bubbling = arguments[3]; + + if ( !bubbling ) { + event = typeof event === "object" ? + // jQuery.Event object + event[expando] ? event : + // Object literal + jQuery.extend( jQuery.Event(type), event ) : + // Just the event type (string) + jQuery.Event(type); + + if ( type.indexOf("!") >= 0 ) { + event.type = type = type.slice(0, -1); + event.exclusive = true; + } + + // Handle a global trigger + if ( !elem ) { + // Don't bubble custom events when global (to avoid too much overhead) + event.stopPropagation(); + + // Only trigger if we've ever bound an event for it + if ( jQuery.event.global[ type ] ) { + jQuery.each( jQuery.cache, function() { + if ( this.events && this.events[type] ) { + jQuery.event.trigger( event, data, this.handle.elem ); + } + }); + } + } + + // Handle triggering a single element + + // don't do events on text and comment nodes + if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 ) { + return undefined; + } + + // Clean up in case it is reused + event.result = undefined; + event.target = elem; + + // Clone the incoming data, if any + data = jQuery.makeArray( data ); + data.unshift( event ); + } + + event.currentTarget = elem; + + // Trigger the event, it is assumed that "handle" is a function + var handle = jQuery.data( elem, "handle" ); + if ( handle ) { + handle.apply( elem, data ); + } + + var parent = elem.parentNode || elem.ownerDocument; + // Trigger an inline bound script try { + if ( !(elem && elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()]) ) { + if ( elem[ "on" + type ] && elem[ "on" + type ].apply( elem, data ) === false ) { + event.result = false; + } + } - for ( var i = 0, length = array.length; i < length; i++ ) { - var id = jQuery.data( array[ i ] ); + // prevent IE from throwing an error for some elements with some event types, see #3533 + } catch (e) {} + + if ( !event.isPropagationStopped() && parent ) { + jQuery.event.trigger( event, data, parent, true ); + + } else if ( !event.isDefaultPrevented() ) { + var target = event.target, old, + isClick = jQuery.nodeName(target, "a") && type === "click", + special = jQuery.event.special[ type ] || {}; + + if ( (!special._default || special._default.call( elem, event ) === false) && + !isClick && !(target && target.nodeName && jQuery.noData[target.nodeName.toLowerCase()]) ) { + + try { + if ( target[ type ] ) { + // Make sure that we don't accidentally re-trigger the onFOO events + old = target[ "on" + type ]; + + if ( old ) { + target[ "on" + type ] = null; + } + + jQuery.event.triggered = true; + target[ type ](); + } + + // prevent IE from throwing an error for some elements with some event types, see #3533 + } catch (e) {} - if ( !done[ id ] ) { - done[ id ] = true; - ret.push( array[ i ] ); + if ( old ) { + target[ "on" + type ] = old; } + + jQuery.event.triggered = false; } + } + }, - } catch( e ) { - ret = array; + handle: function( event ) { + var all, handlers, namespaces, namespace, events; + + event = arguments[0] = jQuery.event.fix( event || window.event ); + event.currentTarget = this; + + // Namespaced event handlers + all = event.type.indexOf(".") < 0 && !event.exclusive; + + if ( !all ) { + namespaces = event.type.split("."); + event.type = namespaces.shift(); + namespace = new RegExp("(^|\\.)" + namespaces.slice(0).sort().join("\\.(?:.*\\.)?") + "(\\.|$)"); } - return ret; - }, + var events = jQuery.data(this, "events"), handlers = events[ event.type ]; - grep: function( elems, callback, inv ) { - var ret = []; + if ( events && handlers ) { + // Clone the handlers to prevent manipulation + handlers = handlers.slice(0); - // Go through the array, only saving the items - // that pass the validator function - for ( var i = 0, length = elems.length; i < length; i++ ) - if ( !inv != !callback( elems[ i ], i ) ) - ret.push( elems[ i ] ); + for ( var j = 0, l = handlers.length; j < l; j++ ) { + var handleObj = handlers[ j ]; - return ret; + // Filter the functions by class + if ( all || namespace.test( handleObj.namespace ) ) { + // Pass in a reference to the handler function itself + // So that we can later remove it + event.handler = handleObj.handler; + event.data = handleObj.data; + event.handleObj = handleObj; + + var ret = handleObj.handler.apply( this, arguments ); + + if ( ret !== undefined ) { + event.result = ret; + if ( ret === false ) { + event.preventDefault(); + event.stopPropagation(); + } + } + + if ( event.isImmediatePropagationStopped() ) { + break; + } + } + } + } + + return event.result; }, - map: function( elems, callback ) { - var ret = []; + props: "altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "), + + fix: function( event ) { + if ( event[ expando ] ) { + return event; + } - // Go through the array, translating each of the items to their - // new value (or values). - for ( var i = 0, length = elems.length; i < length; i++ ) { - var value = callback( elems[ i ], i ); + // store a copy of the original event object + // and "clone" to set read-only properties + var originalEvent = event; + event = jQuery.Event( originalEvent ); - if ( value != null ) - ret[ ret.length ] = value; + for ( var i = this.props.length, prop; i; ) { + prop = this.props[ --i ]; + event[ prop ] = originalEvent[ prop ]; } - return ret.concat.apply( [], ret ); - } -}); + // Fix target property, if necessary + if ( !event.target ) { + event.target = event.srcElement || document; // Fixes #1925 where srcElement might not be defined either + } -// Use of jQuery.browser is deprecated. -// It's included for backwards compatibility and plugins, -// although they should work to migrate away. + // check if target is a textnode (safari) + if ( event.target.nodeType === 3 ) { + event.target = event.target.parentNode; + } -var userAgent = navigator.userAgent.toLowerCase(); + // Add relatedTarget, if necessary + if ( !event.relatedTarget && event.fromElement ) { + event.relatedTarget = event.fromElement === event.target ? event.toElement : event.fromElement; + } -// Figure out what browser is being used -jQuery.browser = { - version: (userAgent.match( /.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/ ) || [0,'0'])[1], - safari: /webkit/.test( userAgent ), - opera: /opera/.test( userAgent ), - msie: /msie/.test( userAgent ) && !/opera/.test( userAgent ), - mozilla: /mozilla/.test( userAgent ) && !/(compatible|webkit)/.test( userAgent ) -}; + // Calculate pageX/Y if missing and clientX/Y available + if ( event.pageX == null && event.clientX != null ) { + var doc = document.documentElement, body = document.body; + event.pageX = event.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0); + event.pageY = event.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0); + } -jQuery.each({ - parent: function(elem){return elem.parentNode;}, - parents: function(elem){return jQuery.dir(elem,"parentNode");}, - next: function(elem){return jQuery.nth(elem,2,"nextSibling");}, - prev: function(elem){return jQuery.nth(elem,2,"previousSibling");}, - nextAll: function(elem){return jQuery.dir(elem,"nextSibling");}, - prevAll: function(elem){return jQuery.dir(elem,"previousSibling");}, - siblings: function(elem){return jQuery.sibling(elem.parentNode.firstChild,elem);}, - children: function(elem){return jQuery.sibling(elem.firstChild);}, - contents: function(elem){return jQuery.nodeName(elem,"iframe")?elem.contentDocument||elem.contentWindow.document:jQuery.makeArray(elem.childNodes);} -}, function(name, fn){ - jQuery.fn[ name ] = function( selector ) { - var ret = jQuery.map( this, fn ); + // Add which for key events + if ( !event.which && ((event.charCode || event.charCode === 0) ? event.charCode : event.keyCode) ) { + event.which = event.charCode || event.keyCode; + } + + // Add metaKey to non-Mac browsers (use ctrl for PC's and Meta for Macs) + if ( !event.metaKey && event.ctrlKey ) { + event.metaKey = event.ctrlKey; + } + + // Add which for click: 1 === left; 2 === middle; 3 === right + // Note: button is not normalized, so don't use it + if ( !event.which && event.button !== undefined ) { + event.which = (event.button & 1 ? 1 : ( event.button & 2 ? 3 : ( event.button & 4 ? 2 : 0 ) )); + } + + return event; + }, + + // Deprecated, use jQuery.guid instead + guid: 1E8, + + // Deprecated, use jQuery.proxy instead + proxy: jQuery.proxy, - if ( selector && typeof selector == "string" ) - ret = jQuery.multiFilter( selector, ret ); + special: { + ready: { + // Make sure the ready event is setup + setup: jQuery.bindReady, + teardown: jQuery.noop + }, - return this.pushStack( jQuery.unique( ret ), name, selector ); - }; -}); + live: { + add: function( handleObj ) { + jQuery.event.add( this, handleObj.origType, jQuery.extend({}, handleObj, {handler: liveHandler}) ); + }, -jQuery.each({ - appendTo: "append", - prependTo: "prepend", - insertBefore: "before", - insertAfter: "after", - replaceAll: "replaceWith" -}, function(name, original){ - jQuery.fn[ name ] = function( selector ) { - var ret = [], insert = jQuery( selector ); + remove: function( handleObj ) { + var remove = true, + type = handleObj.origType.replace(rnamespaces, ""); + + jQuery.each( jQuery.data(this, "events").live || [], function() { + if ( type === this.origType.replace(rnamespaces, "") ) { + remove = false; + return false; + } + }); - for ( var i = 0, l = insert.length; i < l; i++ ) { - var elems = (i > 0 ? this.clone(true) : this).get(); - jQuery.fn[ original ].apply( jQuery(insert[i]), elems ); - ret = ret.concat( elems ); + if ( remove ) { + jQuery.event.remove( this, handleObj.origType, liveHandler ); + } + } + + }, + + beforeunload: { + setup: function( data, namespaces, eventHandle ) { + // We only want to do this special case on windows + if ( this.setInterval ) { + this.onbeforeunload = eventHandle; + } + + return false; + }, + teardown: function( namespaces, eventHandle ) { + if ( this.onbeforeunload === eventHandle ) { + this.onbeforeunload = null; + } + } } + } +}; - return this.pushStack( ret, name, selector ); +var removeEvent = document.removeEventListener ? + function( elem, type, handle ) { + elem.removeEventListener( type, handle, false ); + } : + function( elem, type, handle ) { + elem.detachEvent( "on" + type, handle ); }; -}); + +jQuery.Event = function( src ) { + // Allow instantiation without the 'new' keyword + if ( !this.preventDefault ) { + return new jQuery.Event( src ); + } + + // Event object + if ( src && src.type ) { + this.originalEvent = src; + this.type = src.type; + // Event type + } else { + this.type = src; + } + + // timeStamp is buggy for some events on Firefox(#3843) + // So we won't rely on the native value + this.timeStamp = now(); + + // Mark it as fixed + this[ expando ] = true; +}; + +function returnFalse() { + return false; +} +function returnTrue() { + return true; +} + +// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding +// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html +jQuery.Event.prototype = { + preventDefault: function() { + this.isDefaultPrevented = returnTrue; -jQuery.each({ - removeAttr: function( name ) { - jQuery.attr( this, name, "" ); - if (this.nodeType == 1) - this.removeAttribute( name ); + var e = this.originalEvent; + if ( !e ) { + return; + } + + // if preventDefault exists run it on the original event + if ( e.preventDefault ) { + e.preventDefault(); + } + // otherwise set the returnValue property of the original event to false (IE) + e.returnValue = false; }, + stopPropagation: function() { + this.isPropagationStopped = returnTrue; - addClass: function( classNames ) { - jQuery.className.add( this, classNames ); + var e = this.originalEvent; + if ( !e ) { + return; + } + // if stopPropagation exists run it on the original event + if ( e.stopPropagation ) { + e.stopPropagation(); + } + // otherwise set the cancelBubble property of the original event to true (IE) + e.cancelBubble = true; + }, + stopImmediatePropagation: function() { + this.isImmediatePropagationStopped = returnTrue; + this.stopPropagation(); }, + isDefaultPrevented: returnFalse, + isPropagationStopped: returnFalse, + isImmediatePropagationStopped: returnFalse +}; - removeClass: function( classNames ) { - jQuery.className.remove( this, classNames ); - }, +// Checks if an event happened on an element within another element +// Used in jQuery.event.special.mouseenter and mouseleave handlers +var withinElement = function( event ) { + // Check if mouse(over|out) are still within the same parent element + var parent = event.relatedTarget; - toggleClass: function( classNames, state ) { - if( typeof state !== "boolean" ) - state = !jQuery.className.has( this, classNames ); - jQuery.className[ state ? "add" : "remove" ]( this, classNames ); - }, + // Firefox sometimes assigns relatedTarget a XUL element + // which we cannot access the parentNode property of + try { + // Traverse up the tree + while ( parent && parent !== this ) { + parent = parent.parentNode; + } - remove: function( selector ) { - if ( !selector || jQuery.filter( selector, [ this ] ).length ) { - // Prevent memory leaks - jQuery( "*", this ).add([this]).each(function(){ - jQuery.event.remove(this); - jQuery.removeData(this); - }); - if (this.parentNode) - this.parentNode.removeChild( this ); + if ( parent !== this ) { + // set the correct event type + event.type = event.data; + + // handle event if we actually just moused on to a non sub-element + jQuery.event.handle.apply( this, arguments ); } - }, - empty: function() { - // Remove element nodes and prevent memory leaks - jQuery(this).children().remove(); + // assuming we've left the element since we most likely mousedover a xul element + } catch(e) { } +}, + +// In case of event delegation, we only need to rename the event.type, +// liveHandler will take care of the rest. +delegate = function( event ) { + event.type = event.data; + jQuery.event.handle.apply( this, arguments ); +}; - // Remove any remaining nodes - while ( this.firstChild ) - this.removeChild( this.firstChild ); - } -}, function(name, fn){ - jQuery.fn[ name ] = function(){ - return this.each( fn, arguments ); +// Create mouseenter and mouseleave events +jQuery.each({ + mouseenter: "mouseover", + mouseleave: "mouseout" +}, function( orig, fix ) { + jQuery.event.special[ orig ] = { + setup: function( data ) { + jQuery.event.add( this, fix, data && data.selector ? delegate : withinElement, orig ); + }, + teardown: function( data ) { + jQuery.event.remove( this, fix, data && data.selector ? delegate : withinElement ); + } }; }); -// Helper function used by the dimensions and offset modules -function num(elem, prop) { - return elem[0] && parseInt( jQuery.curCSS(elem[0], prop, true), 10 ) || 0; +// submit delegation +if ( !jQuery.support.submitBubbles ) { + + jQuery.event.special.submit = { + setup: function( data, namespaces ) { + if ( this.nodeName.toLowerCase() !== "form" ) { + jQuery.event.add(this, "click.specialSubmit", function( e ) { + var elem = e.target, type = elem.type; + + if ( (type === "submit" || type === "image") && jQuery( elem ).closest("form").length ) { + return trigger( "submit", this, arguments ); + } + }); + + jQuery.event.add(this, "keypress.specialSubmit", function( e ) { + var elem = e.target, type = elem.type; + + if ( (type === "text" || type === "password") && jQuery( elem ).closest("form").length && e.keyCode === 13 ) { + return trigger( "submit", this, arguments ); + } + }); + + } else { + return false; + } + }, + + teardown: function( namespaces ) { + jQuery.event.remove( this, ".specialSubmit" ); + } + }; + } -var expando = "jQuery" + now(), uuid = 0, windowData = {}; -jQuery.extend({ - cache: {}, +// change delegation, happens here so we have bind. +if ( !jQuery.support.changeBubbles ) { - data: function( elem, name, data ) { - elem = elem == window ? - windowData : - elem; + var formElems = /textarea|input|select/i, - var id = elem[ expando ]; + changeFilters, - // Compute a unique ID for the element - if ( !id ) - id = elem[ expando ] = ++uuid; + getVal = function( elem ) { + var type = elem.type, val = elem.value; - // Only generate the data cache if we're - // trying to access or manipulate it - if ( name && !jQuery.cache[ id ] ) - jQuery.cache[ id ] = {}; + if ( type === "radio" || type === "checkbox" ) { + val = elem.checked; - // Prevent overriding the named cache with undefined values - if ( data !== undefined ) - jQuery.cache[ id ][ name ] = data; + } else if ( type === "select-multiple" ) { + val = elem.selectedIndex > -1 ? + jQuery.map( elem.options, function( elem ) { + return elem.selected; + }).join("-") : + ""; - // Return the named cache data, or the ID for the element - return name ? - jQuery.cache[ id ][ name ] : - id; + } else if ( elem.nodeName.toLowerCase() === "select" ) { + val = elem.selectedIndex; + } + + return val; }, - removeData: function( elem, name ) { - elem = elem == window ? - windowData : - elem; + testChange = function testChange( e ) { + var elem = e.target, data, val; + + if ( !formElems.test( elem.nodeName ) || elem.readOnly ) { + return; + } + + data = jQuery.data( elem, "_change_data" ); + val = getVal(elem); + + // the current data will be also retrieved by beforeactivate + if ( e.type !== "focusout" || elem.type !== "radio" ) { + jQuery.data( elem, "_change_data", val ); + } + + if ( data === undefined || val === data ) { + return; + } + + if ( data != null || val ) { + e.type = "change"; + return jQuery.event.trigger( e, arguments[1], elem ); + } + }; + + jQuery.event.special.change = { + filters: { + focusout: testChange, + + click: function( e ) { + var elem = e.target, type = elem.type; + + if ( type === "radio" || type === "checkbox" || elem.nodeName.toLowerCase() === "select" ) { + return testChange.call( this, e ); + } + }, + + // Change has to be called before submit + // Keydown will be called before keypress, which is used in submit-event delegation + keydown: function( e ) { + var elem = e.target, type = elem.type; + + if ( (e.keyCode === 13 && elem.nodeName.toLowerCase() !== "textarea") || + (e.keyCode === 32 && (type === "checkbox" || type === "radio")) || + type === "select-multiple" ) { + return testChange.call( this, e ); + } + }, - var id = elem[ expando ]; + // Beforeactivate happens also before the previous element is blurred + // with this event you can't trigger a change event, but you can store + // information/focus[in] is not needed anymore + beforeactivate: function( e ) { + var elem = e.target; + jQuery.data( elem, "_change_data", getVal(elem) ); + } + }, - // If we want to remove a specific section of the element's data - if ( name ) { - if ( jQuery.cache[ id ] ) { - // Remove the section of cache data - delete jQuery.cache[ id ][ name ]; + setup: function( data, namespaces ) { + if ( this.type === "file" ) { + return false; + } - // If we've removed all the data, remove the element's cache - name = ""; + for ( var type in changeFilters ) { + jQuery.event.add( this, type + ".specialChange", changeFilters[type] ); + } + + return formElems.test( this.nodeName ); + }, + + teardown: function( namespaces ) { + jQuery.event.remove( this, ".specialChange" ); + + return formElems.test( this.nodeName ); + } + }; + + changeFilters = jQuery.event.special.change.filters; +} + +function trigger( type, elem, args ) { + args[0].type = type; + return jQuery.event.handle.apply( elem, args ); +} + +// Create "bubbling" focus and blur events +if ( document.addEventListener ) { + jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) { + jQuery.event.special[ fix ] = { + setup: function() { + this.addEventListener( orig, handler, true ); + }, + teardown: function() { + this.removeEventListener( orig, handler, true ); + } + }; - for ( name in jQuery.cache[ id ] ) - break; + function handler( e ) { + e = jQuery.event.fix( e ); + e.type = fix; + return jQuery.event.handle.call( this, e ); + } + }); +} - if ( !name ) - jQuery.removeData( elem ); +jQuery.each(["bind", "one"], function( i, name ) { + jQuery.fn[ name ] = function( type, data, fn ) { + // Handle object literals + if ( typeof type === "object" ) { + for ( var key in type ) { + this[ name ](key, data, type[key], fn); } + return this; + } + + if ( jQuery.isFunction( data ) ) { + fn = data; + data = undefined; + } - // Otherwise, we want to remove all of the element's data + var handler = name === "one" ? jQuery.proxy( fn, function( event ) { + jQuery( this ).unbind( event, handler ); + return fn.apply( this, arguments ); + }) : fn; + + if ( type === "unload" && name !== "one" ) { + this.one( type, data, fn ); + } else { - // Clean up the element expando - try { - delete elem[ expando ]; - } catch(e){ - // IE has trouble directly removing the expando - // but it's ok with using removeAttribute - if ( elem.removeAttribute ) - elem.removeAttribute( expando ); + for ( var i = 0, l = this.length; i < l; i++ ) { + jQuery.event.add( this[i], type, handler, data ); + } + } + + return this; + }; +}); + +jQuery.fn.extend({ + unbind: function( type, fn ) { + // Handle object literals + if ( typeof type === "object" && !type.preventDefault ) { + for ( var key in type ) { + this.unbind(key, type[key]); } - // Completely remove the data cache - delete jQuery.cache[ id ]; + } else { + for ( var i = 0, l = this.length; i < l; i++ ) { + jQuery.event.remove( this[i], type, fn ); + } } + + return this; }, - queue: function( elem, type, data ) { - if ( elem ){ - type = (type || "fx") + "queue"; - - var q = jQuery.data( elem, type ); + delegate: function( selector, types, data, fn ) { + return this.live( types, data, fn, selector ); + }, - if ( !q || jQuery.isArray(data) ) - q = jQuery.data( elem, type, jQuery.makeArray(data) ); - else if( data ) - q.push( data ); + undelegate: function( selector, types, fn ) { + if ( arguments.length === 0 ) { + return this.unbind( "live" ); + + } else { + return this.die( types, null, fn, selector ); + } + }, + trigger: function( type, data ) { + return this.each(function() { + jQuery.event.trigger( type, data, this ); + }); + }, + + triggerHandler: function( type, data ) { + if ( this[0] ) { + var event = jQuery.Event( type ); + event.preventDefault(); + event.stopPropagation(); + jQuery.event.trigger( event, data, this[0] ); + return event.result; } - return q; + }, + + toggle: function( fn ) { + // Save reference to arguments for access in closure + var args = arguments, i = 1; + + // link all the functions, so any of them can unbind this click handler + while ( i < args.length ) { + jQuery.proxy( fn, args[ i++ ] ); + } + + return this.click( jQuery.proxy( fn, function( event ) { + // Figure out which function to execute + var lastToggle = ( jQuery.data( this, "lastToggle" + fn.guid ) || 0 ) % i; + jQuery.data( this, "lastToggle" + fn.guid, lastToggle + 1 ); + + // Make sure that clicks stop + event.preventDefault(); + + // and execute the function + return args[ lastToggle ].apply( this, arguments ) || false; + })); }, - dequeue: function( elem, type ){ - var queue = jQuery.queue( elem, type ), - fn = queue.shift(); + hover: function( fnOver, fnOut ) { + return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver ); + } +}); + +var liveMap = { + focus: "focusin", + blur: "focusout", + mouseenter: "mouseover", + mouseleave: "mouseout" +}; + +jQuery.each(["live", "die"], function( i, name ) { + jQuery.fn[ name ] = function( types, data, fn, origSelector /* Internal Use Only */ ) { + var type, i = 0, match, namespaces, preType, + selector = origSelector || this.selector, + context = origSelector ? this : jQuery( this.context ); + + if ( jQuery.isFunction( data ) ) { + fn = data; + data = undefined; + } + + types = (types || "").split(" "); + + while ( (type = types[ i++ ]) != null ) { + match = rnamespaces.exec( type ); + namespaces = ""; + + if ( match ) { + namespaces = match[0]; + type = type.replace( rnamespaces, "" ); + } + + if ( type === "hover" ) { + types.push( "mouseenter" + namespaces, "mouseleave" + namespaces ); + continue; + } + + preType = type; + + if ( type === "focus" || type === "blur" ) { + types.push( liveMap[ type ] + namespaces ); + type = type + namespaces; + + } else { + type = (liveMap[ type ] || type) + namespaces; + } + + if ( name === "live" ) { + // bind live handler + context.each(function(){ + jQuery.event.add( this, liveConvert( type, selector ), + { data: data, selector: selector, handler: fn, origType: type, origHandler: fn, preType: preType } ); + }); + + } else { + // unbind live handler + context.unbind( liveConvert( type, selector ), fn ); + } + } - if( !type || type === "fx" ) - fn = queue[0]; - - if( fn !== undefined ) - fn.call(elem); + return this; } }); -jQuery.fn.extend({ - data: function( key, value ){ - var parts = key.split("."); - parts[1] = parts[1] ? "." + parts[1] : ""; +function liveHandler( event ) { + var stop, elems = [], selectors = [], args = arguments, + related, match, handleObj, elem, j, i, l, data, + events = jQuery.data( this, "events" ); + + // Make sure we avoid non-left-click bubbling in Firefox (#3861) + if ( event.liveFired === this || !events || !events.live || event.button && event.type === "click" ) { + return; + } + + event.liveFired = this; + + var live = events.live.slice(0); + + for ( j = 0; j < live.length; j++ ) { + handleObj = live[j]; + + if ( handleObj.origType.replace( rnamespaces, "" ) === event.type ) { + selectors.push( handleObj.selector ); + + } else { + live.splice( j--, 1 ); + } + } - if ( value === undefined ) { - var data = this.triggerHandler("getData" + parts[1] + "!", [parts[0]]); + match = jQuery( event.target ).closest( selectors, event.currentTarget ); - if ( data === undefined && this.length ) - data = jQuery.data( this[0], key ); + for ( i = 0, l = match.length; i < l; i++ ) { + for ( j = 0; j < live.length; j++ ) { + handleObj = live[j]; + + if ( match[i].selector === handleObj.selector ) { + elem = match[i].elem; + related = null; + + // Those two events require additional checking + if ( handleObj.preType === "mouseenter" || handleObj.preType === "mouseleave" ) { + related = jQuery( event.relatedTarget ).closest( handleObj.selector )[0]; + } + + if ( !related || related !== elem ) { + elems.push({ elem: elem, handleObj: handleObj }); + } + } + } + } - return data === undefined && parts[1] ? - this.data( parts[0] ) : - data; - } else - return this.trigger("setData" + parts[1] + "!", [parts[0], value]).each(function(){ - jQuery.data( this, key, value ); - }); - }, + for ( i = 0, l = elems.length; i < l; i++ ) { + match = elems[i]; + event.currentTarget = match.elem; + event.data = match.handleObj.data; + event.handleObj = match.handleObj; - removeData: function( key ){ - return this.each(function(){ - jQuery.removeData( this, key ); - }); - }, - queue: function(type, data){ - if ( typeof type !== "string" ) { - data = type; - type = "fx"; + if ( match.handleObj.origHandler.apply( match.elem, args ) === false ) { + stop = false; + break; } + } - if ( data === undefined ) - return jQuery.queue( this[0], type ); + return stop; +} - return this.each(function(){ - var queue = jQuery.queue( this, type, data ); - - if( type == "fx" && queue.length == 1 ) - queue[0].call(this); - }); - }, - dequeue: function(type){ - return this.each(function(){ - jQuery.dequeue( this, type ); - }); +function liveConvert( type, selector ) { + return "live." + (type && type !== "*" ? type + "." : "") + selector.replace(/\./g, "`").replace(/ /g, "&"); +} + +jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " + + "mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " + + "change select submit keydown keypress keyup error").split(" "), function( i, name ) { + + // Handle event binding + jQuery.fn[ name ] = function( fn ) { + return fn ? this.bind( name, fn ) : this.trigger( name ); + }; + + if ( jQuery.attrFn ) { + jQuery.attrFn[ name ] = true; } -});/*! - * Sizzle CSS Selector Engine - v0.9.3 +}); + +// Prevent memory leaks in IE +// Window isn't included so as not to unbind existing unload events +// More info: +// - http://isaacschlueter.com/2006/10/msie-memory-leaks/ +if ( window.attachEvent && !window.addEventListener ) { + window.attachEvent("onunload", function() { + for ( var id in jQuery.cache ) { + if ( jQuery.cache[ id ].handle ) { + // Try/Catch is to handle iframes being unloaded, see #4280 + try { + jQuery.event.remove( jQuery.cache[ id ].handle.elem ); + } catch(e) {} + } + } + }); +} +/*! + * Sizzle CSS Selector Engine - v1.0 * Copyright 2009, The Dojo Foundation * Released under the MIT, BSD, and GPL Licenses. * More information: http://sizzlejs.com/ */ (function(){ -var chunker = /((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g, +var chunker = /((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g, done = 0, - toString = Object.prototype.toString; + toString = Object.prototype.toString, + hasDuplicate = false, + baseHasDuplicate = true; + +// Here we check if the JavaScript engine is using some sort of +// optimization where it does not always call our comparision +// function. If that is the case, discard the hasDuplicate value. +// Thus far that includes Google Chrome. +[0, 0].sort(function(){ + baseHasDuplicate = false; + return 0; +}); var Sizzle = function(selector, context, results, seed) { results = results || []; - context = context || document; + var origContext = context = context || document; - if ( context.nodeType !== 1 && context.nodeType !== 9 ) + if ( context.nodeType !== 1 && context.nodeType !== 9 ) { return []; + } if ( !selector || typeof selector !== "string" ) { return results; } - var parts = [], m, set, checkSet, check, mode, extra, prune = true; + var parts = [], m, set, checkSet, extra, prune = true, contextXML = isXML(context), + soFar = selector; // Reset the position of the chunker regexp (start from head) - chunker.lastIndex = 0; - - while ( (m = chunker.exec(selector)) !== null ) { + while ( (chunker.exec(""), m = chunker.exec(soFar)) !== null ) { + soFar = m[3]; + parts.push( m[1] ); if ( m[2] ) { - extra = RegExp.rightContext; + extra = m[3]; break; } }@@ -1460,38 +2682,51 @@
while ( parts.length ) { selector = parts.shift(); - if ( Expr.relative[ selector ] ) + if ( Expr.relative[ selector ] ) { selector += parts.shift(); - + } + set = posProcess( selector, set ); } } } else { - var ret = seed ? - { expr: parts.pop(), set: makeArray(seed) } : - Sizzle.find( parts.pop(), parts.length === 1 && context.parentNode ? context.parentNode : context, isXML(context) ); - set = Sizzle.filter( ret.expr, ret.set ); - - if ( parts.length > 0 ) { - checkSet = makeArray(set); - } else { - prune = false; + // Take a shortcut and set the context if the root selector is an ID + // (but not if it'll be faster if the inner selector is an ID) + if ( !seed && parts.length > 1 && context.nodeType === 9 && !contextXML && + Expr.match.ID.test(parts[0]) && !Expr.match.ID.test(parts[parts.length - 1]) ) { + var ret = Sizzle.find( parts.shift(), context, contextXML ); + context = ret.expr ? Sizzle.filter( ret.expr, ret.set )[0] : ret.set[0]; } - while ( parts.length ) { - var cur = parts.pop(), pop = cur; + if ( context ) { + var ret = seed ? + { expr: parts.pop(), set: makeArray(seed) } : + Sizzle.find( parts.pop(), parts.length === 1 && (parts[0] === "~" || parts[0] === "+") && context.parentNode ? context.parentNode : context, contextXML ); + set = ret.expr ? Sizzle.filter( ret.expr, ret.set ) : ret.set; - if ( !Expr.relative[ cur ] ) { - cur = ""; + if ( parts.length > 0 ) { + checkSet = makeArray(set); } else { - pop = parts.pop(); + prune = false; } - if ( pop == null ) { - pop = context; + while ( parts.length ) { + var cur = parts.pop(), pop = cur; + + if ( !Expr.relative[ cur ] ) { + cur = ""; + } else { + pop = parts.pop(); + } + + if ( pop == null ) { + pop = context; + } + + Expr.relative[ cur ]( checkSet, pop, contextXML ); } - - Expr.relative[ cur ]( checkSet, pop, isXML(context) ); + } else { + checkSet = parts = []; } }@@ -1500,13 +2735,13 @@ checkSet = set;
} if ( !checkSet ) { - throw "Syntax error, unrecognized expression: " + (cur || selector); + Sizzle.error( cur || selector ); } if ( toString.call(checkSet) === "[object Array]" ) { if ( !prune ) { results.push.apply( results, checkSet ); - } else if ( context.nodeType === 1 ) { + } else if ( context && context.nodeType === 1 ) { for ( var i = 0; checkSet[i] != null; i++ ) { if ( checkSet[i] && (checkSet[i] === true || checkSet[i].nodeType === 1 && contains(context, checkSet[i])) ) { results.push( set[i] );@@ -1524,17 +2759,22 @@ makeArray( checkSet, results );
} if ( extra ) { - Sizzle( extra, context, results, seed ); + Sizzle( extra, origContext, results, seed ); + Sizzle.uniqueSort( results ); + } - if ( sortOrder ) { - hasDuplicate = false; - results.sort(sortOrder); + return results; +}; - if ( hasDuplicate ) { - for ( var i = 1; i < results.length; i++ ) { - if ( results[i] === results[i-1] ) { - results.splice(i--, 1); - } +Sizzle.uniqueSort = function(results){ + if ( sortOrder ) { + hasDuplicate = baseHasDuplicate; + results.sort(sortOrder); + + if ( hasDuplicate ) { + for ( var i = 1; i < results.length; i++ ) { + if ( results[i] === results[i-1] ) { + results.splice(i--, 1); } } }@@ -1557,8 +2797,9 @@
for ( var i = 0, l = Expr.order.length; i < l; i++ ) { var type = Expr.order[i], match; - if ( (match = Expr.match[ type ].exec( expr )) ) { - var left = RegExp.leftContext; + if ( (match = Expr.leftMatch[ type ].exec( expr )) ) { + var left = match[1]; + match.splice(1,1); if ( left.substr( left.length - 1 ) !== "\\" ) { match[1] = (match[1] || "").replace(/\\/g, "");@@ -1584,11 +2825,17 @@ isXMLFilter = set && set[0] && isXML(set[0]);
while ( expr && set.length ) { for ( var type in Expr.filter ) { - if ( (match = Expr.match[ type ].exec( expr )) != null ) { - var filter = Expr.filter[ type ], found, item; + if ( (match = Expr.leftMatch[ type ].exec( expr )) != null && match[2] ) { + var filter = Expr.filter[ type ], found, item, left = match[1]; anyFound = false; - if ( curLoop == result ) { + match.splice(1,1); + + if ( left.substr( left.length - 1 ) === "\\" ) { + continue; + } + + if ( curLoop === result ) { result = []; }@@ -1639,9 +2886,9 @@ }
} // Improper expression - if ( expr == old ) { + if ( expr === old ) { if ( anyFound == null ) { - throw "Syntax error, unrecognized expression: " + expr; + Sizzle.error( expr ); } else { break; }@@ -1653,18 +2900,23 @@
return curLoop; }; +Sizzle.error = function( msg ) { + throw "Syntax error, unrecognized expression: " + msg; +}; + var Expr = Sizzle.selectors = { order: [ "ID", "NAME", "TAG" ], match: { - ID: /#((?:[\w\u00c0-\uFFFF_-]|\\.)+)/, - CLASS: /\.((?:[\w\u00c0-\uFFFF_-]|\\.)+)/, - NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF_-]|\\.)+)['"]*\]/, - ATTR: /\[\s*((?:[\w\u00c0-\uFFFF_-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/, - TAG: /^((?:[\w\u00c0-\uFFFF\*_-]|\\.)+)/, + ID: /#((?:[\w\u00c0-\uFFFF-]|\\.)+)/, + CLASS: /\.((?:[\w\u00c0-\uFFFF-]|\\.)+)/, + NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF-]|\\.)+)['"]*\]/, + ATTR: /\[\s*((?:[\w\u00c0-\uFFFF-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/, + TAG: /^((?:[\w\u00c0-\uFFFF\*-]|\\.)+)/, CHILD: /:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/, POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/, - PSEUDO: /:((?:[\w\u00c0-\uFFFF_-]|\\.)+)(?:\((['"]*)((?:\([^\)]+\)|[^\2\(\)]*)+)\2\))?/ + PSEUDO: /:((?:[\w\u00c0-\uFFFF-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/ }, + leftMatch: {}, attrMap: { "class": "className", "for": "htmlFor"@@ -1675,20 +2927,20 @@ return elem.getAttribute("href");
} }, relative: { - "+": function(checkSet, part, isXML){ + "+": function(checkSet, part){ var isPartStr = typeof part === "string", isTag = isPartStr && !/\W/.test(part), isPartStrNotTag = isPartStr && !isTag; - if ( isTag && !isXML ) { - part = part.toUpperCase(); + if ( isTag ) { + part = part.toLowerCase(); } for ( var i = 0, l = checkSet.length, elem; i < l; i++ ) { if ( (elem = checkSet[i]) ) { while ( (elem = elem.previousSibling) && elem.nodeType !== 1 ) {} - checkSet[i] = isPartStrNotTag || elem && elem.nodeName === part ? + checkSet[i] = isPartStrNotTag || elem && elem.nodeName.toLowerCase() === part ? elem || false : elem === part; }@@ -1698,17 +2950,17 @@ if ( isPartStrNotTag ) {
Sizzle.filter( part, checkSet, true ); } }, - ">": function(checkSet, part, isXML){ + ">": function(checkSet, part){ var isPartStr = typeof part === "string"; if ( isPartStr && !/\W/.test(part) ) { - part = isXML ? part : part.toUpperCase(); + part = part.toLowerCase(); for ( var i = 0, l = checkSet.length; i < l; i++ ) { var elem = checkSet[i]; if ( elem ) { var parent = elem.parentNode; - checkSet[i] = parent.nodeName === part ? parent : false; + checkSet[i] = parent.nodeName.toLowerCase() === part ? parent : false; } } } else {@@ -1729,8 +2981,8 @@ },
"": function(checkSet, part, isXML){ var doneName = done++, checkFn = dirCheck; - if ( !part.match(/\W/) ) { - var nodeCheck = part = isXML ? part : part.toUpperCase(); + if ( typeof part === "string" && !/\W/.test(part) ) { + var nodeCheck = part = part.toLowerCase(); checkFn = dirNodeCheck; }@@ -1739,8 +2991,8 @@ },
"~": function(checkSet, part, isXML){ var doneName = done++, checkFn = dirCheck; - if ( typeof part === "string" && !part.match(/\W/) ) { - var nodeCheck = part = isXML ? part : part.toUpperCase(); + if ( typeof part === "string" && !/\W/.test(part) ) { + var nodeCheck = part = part.toLowerCase(); checkFn = dirNodeCheck; }@@ -1754,7 +3006,7 @@ var m = context.getElementById(match[1]);
return m ? [m] : []; } }, - NAME: function(match, context, isXML){ + NAME: function(match, context){ if ( typeof context.getElementsByName !== "undefined" ) { var ret = [], results = context.getElementsByName(match[1]);@@ -1781,9 +3033,10 @@ }
for ( var i = 0, elem; (elem = curLoop[i]) != null; i++ ) { if ( elem ) { - if ( not ^ (elem.className && (" " + elem.className + " ").indexOf(match) >= 0) ) { - if ( !inplace ) + if ( not ^ (elem.className && (" " + elem.className + " ").replace(/[\t\n]/g, " ").indexOf(match) >= 0) ) { + if ( !inplace ) { result.push( elem ); + } } else if ( inplace ) { curLoop[i] = false; }@@ -1796,14 +3049,13 @@ ID: function(match){
return match[1].replace(/\\/g, ""); }, TAG: function(match, curLoop){ - for ( var i = 0; curLoop[i] === false; i++ ){} - return curLoop[i] && isXML(curLoop[i]) ? match[1] : match[1].toUpperCase(); + return match[1].toLowerCase(); }, CHILD: function(match){ - if ( match[1] == "nth" ) { + if ( match[1] === "nth" ) { // parse equations like 'even', 'odd', '5', '2n', '3n+2', '4n-1', '-n+6' var test = /(-?)(\d*)n((?:\+|-)?\d*)/.exec( - match[2] == "even" && "2n" || match[2] == "odd" && "2n+1" || + match[2] === "even" && "2n" || match[2] === "odd" && "2n+1" || !/\D/.test( match[2] ) && "0n+" + match[2] || match[2]); // calculate the numbers (first)n+(last) including if they are negative@@ -1832,7 +3084,7 @@ },
PSEUDO: function(match, curLoop, inplace, result, not){ if ( match[1] === "not" ) { // If we're dealing with a complex expression, or a simple one - if ( match[3].match(chunker).length > 1 || /^\w/.test(match[3]) ) { + if ( ( chunker.exec(match[3]) || "" ).length > 1 || /^\w/.test(match[3]) ) { match[3] = Sizzle(match[3], null, null, curLoop); } else { var ret = Sizzle.filter(match[3], curLoop, inplace, true ^ not);@@ -1905,7 +3157,7 @@ reset: function(elem){
return "reset" === elem.type; }, button: function(elem){ - return "button" === elem.type || elem.nodeName.toUpperCase() === "BUTTON"; + return "button" === elem.type || elem.nodeName.toLowerCase() === "button"; }, input: function(elem){ return /input|select|textarea|button/i.test(elem.nodeName);@@ -1931,10 +3183,10 @@ gt: function(elem, i, match){
return i > match[3] - 0; }, nth: function(elem, i, match){ - return match[3] - 0 == i; + return match[3] - 0 === i; }, eq: function(elem, i, match){ - return match[3] - 0 == i; + return match[3] - 0 === i; } }, filter: {@@ -1944,7 +3196,7 @@
if ( filter ) { return filter( elem, i, match, array ); } else if ( name === "contains" ) { - return (elem.textContent || elem.innerText || "").indexOf(match[3]) >= 0; + return (elem.textContent || elem.innerText || getText([ elem ]) || "").indexOf(match[3]) >= 0; } else if ( name === "not" ) { var not = match[3];@@ -1955,6 +3207,8 @@ }
} return true; + } else { + Sizzle.error( "Syntax error, unrecognized expression: " + name ); } }, CHILD: function(elem, match){@@ -1962,20 +3216,26 @@ var type = match[1], node = elem;
switch (type) { case 'only': case 'first': - while (node = node.previousSibling) { - if ( node.nodeType === 1 ) return false; + while ( (node = node.previousSibling) ) { + if ( node.nodeType === 1 ) { + return false; + } } - if ( type == 'first') return true; + if ( type === "first" ) { + return true; + } node = elem; case 'last': - while (node = node.nextSibling) { - if ( node.nodeType === 1 ) return false; + while ( (node = node.nextSibling) ) { + if ( node.nodeType === 1 ) { + return false; + } } return true; case 'nth': var first = match[2], last = match[3]; - if ( first == 1 && last == 0 ) { + if ( first === 1 && last === 0 ) { return true; }@@ -1993,10 +3253,10 @@ parent.sizcache = doneName;
} var diff = elem.nodeIndex - last; - if ( first == 0 ) { - return diff == 0; + if ( first === 0 ) { + return diff === 0; } else { - return ( diff % first == 0 && diff / first >= 0 ); + return ( diff % first === 0 && diff / first >= 0 ); } } },@@ -2004,7 +3264,7 @@ ID: function(elem, match){
return elem.nodeType === 1 && elem.getAttribute("id") === match; }, TAG: function(elem, match){ - return (match === "*" && elem.nodeType === 1) || elem.nodeName === match; + return (match === "*" && elem.nodeType === 1) || elem.nodeName.toLowerCase() === match; }, CLASS: function(elem, match){ return (" " + (elem.className || elem.getAttribute("class")) + " ")@@ -2032,7 +3292,7 @@ (" " + value + " ").indexOf(check) >= 0 :
!check ? value && result !== false : type === "!=" ? - value != check : + value !== check : type === "^=" ? value.indexOf(check) === 0 : type === "$=" ?@@ -2054,11 +3314,14 @@
var origPOS = Expr.match.POS; for ( var type in Expr.match ) { - Expr.match[ type ] = RegExp( Expr.match[ type ].source + /(?![^\[]*\])(?![^\(]*\))/.source ); + Expr.match[ type ] = new RegExp( Expr.match[ type ].source + /(?![^\[]*\])(?![^\(]*\))/.source ); + Expr.leftMatch[ type ] = new RegExp( /(^(?:.|\r|\n)*?)/.source + Expr.match[ type ].source.replace(/\\(\d+)/g, function(all, num){ + return "\\" + (num - 0 + 1); + })); } var makeArray = function(array, results) { - array = Array.prototype.slice.call( array ); + array = Array.prototype.slice.call( array, 0 ); if ( results ) { results.push.apply( results, array );@@ -2070,8 +3333,10 @@ };
// Perform a simple check to determine if the browser is capable of // converting a NodeList to an array using builtin methods. +// Also verifies that the returned array holds DOM nodes +// (which is not the case in the Blackberry browser) try { - Array.prototype.slice.call( document.documentElement.childNodes ); + Array.prototype.slice.call( document.documentElement.childNodes, 0 )[0].nodeType; // Provide a fallback method if it does not work } catch(e){@@ -2100,6 +3365,13 @@ var sortOrder;
if ( document.documentElement.compareDocumentPosition ) { sortOrder = function( a, b ) { + if ( !a.compareDocumentPosition || !b.compareDocumentPosition ) { + if ( a == b ) { + hasDuplicate = true; + } + return a.compareDocumentPosition ? -1 : 1; + } + var ret = a.compareDocumentPosition(b) & 4 ? -1 : a === b ? 0 : 1; if ( ret === 0 ) { hasDuplicate = true;@@ -2108,6 +3380,13 @@ return ret;
}; } else if ( "sourceIndex" in document.documentElement ) { sortOrder = function( a, b ) { + if ( !a.sourceIndex || !b.sourceIndex ) { + if ( a == b ) { + hasDuplicate = true; + } + return a.sourceIndex ? -1 : 1; + } + var ret = a.sourceIndex - b.sourceIndex; if ( ret === 0 ) { hasDuplicate = true;@@ -2116,11 +3395,18 @@ return ret;
}; } else if ( document.createRange ) { sortOrder = function( a, b ) { + if ( !a.ownerDocument || !b.ownerDocument ) { + if ( a == b ) { + hasDuplicate = true; + } + return a.ownerDocument ? -1 : 1; + } + var aRange = a.ownerDocument.createRange(), bRange = b.ownerDocument.createRange(); - aRange.selectNode(a); - aRange.collapse(true); - bRange.selectNode(b); - bRange.collapse(true); + aRange.setStart(a, 0); + aRange.setEnd(a, 0); + bRange.setStart(b, 0); + bRange.setEnd(b, 0); var ret = aRange.compareBoundaryPoints(Range.START_TO_END, bRange); if ( ret === 0 ) { hasDuplicate = true;@@ -2129,13 +3415,33 @@ return ret;
}; } +// Utility function for retreiving the text value of an array of DOM nodes +function getText( elems ) { + var ret = "", elem; + + for ( var i = 0; elems[i]; i++ ) { + elem = elems[i]; + + // Get the text from text nodes and CDATA nodes + if ( elem.nodeType === 3 || elem.nodeType === 4 ) { + ret += elem.nodeValue; + + // Traverse everything else, except comment nodes + } else if ( elem.nodeType !== 8 ) { + ret += getText( elem.childNodes ); + } + } + + return ret; +} + // Check to see if the browser returns elements by name when // querying by getElementById (and provide a workaround) (function(){ // We're going to inject a fake input element with a specified name - var form = document.createElement("form"), + var form = document.createElement("div"), id = "script" + (new Date).getTime(); - form.innerHTML = "<input name='" + id + "'/>"; + form.innerHTML = "<a name='" + id + "'/>"; // Inject it into the root element, check its status, and remove it quickly var root = document.documentElement;@@ -2143,7 +3449,7 @@ root.insertBefore( form, root.firstChild );
// The workaround has to do additional checks after a getElementById // Which slows things down for other browsers (hence the branching) - if ( !!document.getElementById( id ) ) { + if ( document.getElementById( id ) ) { Expr.find.ID = function(match, context, isXML){ if ( typeof context.getElementById !== "undefined" && !isXML ) { var m = context.getElementById(match[1]);@@ -2158,6 +3464,7 @@ };
} root.removeChild( form ); + root = form = null; // release memory in IE })(); (function(){@@ -2198,69 +3505,75 @@ Expr.attrHandle.href = function(elem){
return elem.getAttribute("href", 2); }; } + + div = null; // release memory in IE })(); -if ( document.querySelectorAll ) (function(){ - var oldSizzle = Sizzle, div = document.createElement("div"); - div.innerHTML = "<p class='TEST'></p>"; +if ( document.querySelectorAll ) { + (function(){ + var oldSizzle = Sizzle, div = document.createElement("div"); + div.innerHTML = "<p class='TEST'></p>"; - // Safari can't handle uppercase or unicode characters when - // in quirks mode. - if ( div.querySelectorAll && div.querySelectorAll(".TEST").length === 0 ) { - return; - } + // Safari can't handle uppercase or unicode characters when + // in quirks mode. + if ( div.querySelectorAll && div.querySelectorAll(".TEST").length === 0 ) { + return; + } - Sizzle = function(query, context, extra, seed){ - context = context || document; + Sizzle = function(query, context, extra, seed){ + context = context || document; + + // Only use querySelectorAll on non-XML documents + // (ID selectors don't work in non-HTML documents) + if ( !seed && context.nodeType === 9 && !isXML(context) ) { + try { + return makeArray( context.querySelectorAll(query), extra ); + } catch(e){} + } + + return oldSizzle(query, context, extra, seed); + }; - // Only use querySelectorAll on non-XML documents - // (ID selectors don't work in non-HTML documents) - if ( !seed && context.nodeType === 9 && !isXML(context) ) { - try { - return makeArray( context.querySelectorAll(query), extra ); - } catch(e){} + for ( var prop in oldSizzle ) { + Sizzle[ prop ] = oldSizzle[ prop ]; } - - return oldSizzle(query, context, extra, seed); - }; - Sizzle.find = oldSizzle.find; - Sizzle.filter = oldSizzle.filter; - Sizzle.selectors = oldSizzle.selectors; - Sizzle.matches = oldSizzle.matches; -})(); + div = null; // release memory in IE + })(); +} -if ( document.getElementsByClassName && document.documentElement.getElementsByClassName ) (function(){ +(function(){ var div = document.createElement("div"); + div.innerHTML = "<div class='test e'></div><div class='test'></div>"; // Opera can't find a second classname (in 9.6) - if ( div.getElementsByClassName("e").length === 0 ) + // Also, make sure that getElementsByClassName actually exists + if ( !div.getElementsByClassName || div.getElementsByClassName("e").length === 0 ) { return; + } // Safari caches class attributes, doesn't catch changes (in 3.2) div.lastChild.className = "e"; - if ( div.getElementsByClassName("e").length === 1 ) + if ( div.getElementsByClassName("e").length === 1 ) { return; - + } + Expr.order.splice(1, 0, "CLASS"); Expr.find.CLASS = function(match, context, isXML) { if ( typeof context.getElementsByClassName !== "undefined" && !isXML ) { return context.getElementsByClassName(match[1]); } }; + + div = null; // release memory in IE })(); function dirNodeCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) { - var sibDir = dir == "previousSibling" && !isXML; for ( var i = 0, l = checkSet.length; i < l; i++ ) { var elem = checkSet[i]; if ( elem ) { - if ( sibDir && elem.nodeType === 1 ){ - elem.sizcache = doneName; - elem.sizset = i; - } elem = elem[dir]; var match = false;@@ -2275,7 +3588,7 @@ elem.sizcache = doneName;
elem.sizset = i; } - if ( elem.nodeName === cur ) { + if ( elem.nodeName.toLowerCase() === cur ) { match = elem; break; }@@ -2289,14 +3602,9 @@ }
} function dirCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) { - var sibDir = dir == "previousSibling" && !isXML; for ( var i = 0, l = checkSet.length; i < l; i++ ) { var elem = checkSet[i]; if ( elem ) { - if ( sibDir && elem.nodeType === 1 ) { - elem.sizcache = doneName; - elem.sizset = i; - } elem = elem[dir]; var match = false;@@ -2331,15 +3639,17 @@ }
} } -var contains = document.compareDocumentPosition ? function(a, b){ - return a.compareDocumentPosition(b) & 16; +var contains = document.compareDocumentPosition ? function(a, b){ + return !!(a.compareDocumentPosition(b) & 16); } : function(a, b){ return a !== b && (a.contains ? a.contains(b) : true); }; var isXML = function(elem){ - return elem.nodeType === 9 && elem.documentElement.nodeName !== "HTML" || - !!elem.ownerDocument && isXML( elem.ownerDocument ); + // documentElement is verified for cases where it doesn't yet exist + // (such as loading iframes in IE - #4833) + var documentElement = (elem ? elem.ownerDocument || elem : 0).documentElement; + return documentElement ? documentElement.nodeName !== "HTML" : false; }; var posProcess = function(selector, context){@@ -2364,872 +3674,1122 @@ };
// EXPOSE jQuery.find = Sizzle; -jQuery.filter = Sizzle.filter; jQuery.expr = Sizzle.selectors; jQuery.expr[":"] = jQuery.expr.filters; +jQuery.unique = Sizzle.uniqueSort; +jQuery.text = getText; +jQuery.isXMLDoc = isXML; +jQuery.contains = contains; -Sizzle.selectors.filters.hidden = function(elem){ - return elem.offsetWidth === 0 || elem.offsetHeight === 0; -}; +return; -Sizzle.selectors.filters.visible = function(elem){ - return elem.offsetWidth > 0 || elem.offsetHeight > 0; -}; +window.Sizzle = Sizzle; -Sizzle.selectors.filters.animated = function(elem){ - return jQuery.grep(jQuery.timers, function(fn){ - return elem === fn.elem; - }).length; -}; +})(); +var runtil = /Until$/, + rparentsprev = /^(?:parents|prevUntil|prevAll)/, + // Note: This RegExp should be improved, or likely pulled from Sizzle + rmultiselector = /,/, + slice = Array.prototype.slice; -jQuery.multiFilter = function( expr, elems, not ) { - if ( not ) { - expr = ":not(" + expr + ")"; - } +// Implement the identical functionality for filter and not +var winnow = function( elements, qualifier, keep ) { + if ( jQuery.isFunction( qualifier ) ) { + return jQuery.grep(elements, function( elem, i ) { + return !!qualifier.call( elem, i, elem ) === keep; + }); - return Sizzle.matches(expr, elems); -}; + } else if ( qualifier.nodeType ) { + return jQuery.grep(elements, function( elem, i ) { + return (elem === qualifier) === keep; + }); + + } else if ( typeof qualifier === "string" ) { + var filtered = jQuery.grep(elements, function( elem ) { + return elem.nodeType === 1; + }); -jQuery.dir = function( elem, dir ){ - var matched = [], cur = elem[dir]; - while ( cur && cur != document ) { - if ( cur.nodeType == 1 ) - matched.push( cur ); - cur = cur[dir]; + if ( isSimple.test( qualifier ) ) { + return jQuery.filter(qualifier, filtered, !keep); + } else { + qualifier = jQuery.filter( qualifier, filtered ); + } } - return matched; + + return jQuery.grep(elements, function( elem, i ) { + return (jQuery.inArray( elem, qualifier ) >= 0) === keep; + }); }; -jQuery.nth = function(cur, result, dir, elem){ - result = result || 1; - var num = 0; +jQuery.fn.extend({ + find: function( selector ) { + var ret = this.pushStack( "", "find", selector ), length = 0; - for ( ; cur; cur = cur[dir] ) - if ( cur.nodeType == 1 && ++num == result ) - break; + for ( var i = 0, l = this.length; i < l; i++ ) { + length = ret.length; + jQuery.find( selector, this[i], ret ); - return cur; -}; + if ( i > 0 ) { + // Make sure that the results are unique + for ( var n = length; n < ret.length; n++ ) { + for ( var r = 0; r < length; r++ ) { + if ( ret[r] === ret[n] ) { + ret.splice(n--, 1); + break; + } + } + } + } + } -jQuery.sibling = function(n, elem){ - var r = []; + return ret; + }, - for ( ; n; n = n.nextSibling ) { - if ( n.nodeType == 1 && n != elem ) - r.push( n ); - } + has: function( target ) { + var targets = jQuery( target ); + return this.filter(function() { + for ( var i = 0, l = targets.length; i < l; i++ ) { + if ( jQuery.contains( this, targets[i] ) ) { + return true; + } + } + }); + }, - return r; -}; + not: function( selector ) { + return this.pushStack( winnow(this, selector, false), "not", selector); + }, -return; + filter: function( selector ) { + return this.pushStack( winnow(this, selector, true), "filter", selector ); + }, + + is: function( selector ) { + return !!selector && jQuery.filter( selector, this ).length > 0; + }, -window.Sizzle = Sizzle; + closest: function( selectors, context ) { + if ( jQuery.isArray( selectors ) ) { + var ret = [], cur = this[0], match, matches = {}, selector; -})(); -/* - * A number of helper functions used for managing events. - * Many of the ideas behind this code originated from - * Dean Edwards' addEvent library. - */ -jQuery.event = { + if ( cur && selectors.length ) { + for ( var i = 0, l = selectors.length; i < l; i++ ) { + selector = selectors[i]; - // Bind an event to an element - // Original by Dean Edwards - add: function(elem, types, handler, data) { - if ( elem.nodeType == 3 || elem.nodeType == 8 ) - return; + if ( !matches[selector] ) { + matches[selector] = jQuery.expr.match.POS.test( selector ) ? + jQuery( selector, context || this.context ) : + selector; + } + } + + while ( cur && cur.ownerDocument && cur !== context ) { + for ( selector in matches ) { + match = matches[selector]; + + if ( match.jquery ? match.index(cur) > -1 : jQuery(cur).is(match) ) { + ret.push({ selector: selector, elem: cur }); + delete matches[selector]; + } + } + cur = cur.parentNode; + } + } + + return ret; + } + + var pos = jQuery.expr.match.POS.test( selectors ) ? + jQuery( selectors, context || this.context ) : null; + + return this.map(function( i, cur ) { + while ( cur && cur.ownerDocument && cur !== context ) { + if ( pos ? pos.index(cur) > -1 : jQuery(cur).is(selectors) ) { + return cur; + } + cur = cur.parentNode; + } + return null; + }); + }, + + // Determine the position of an element within + // the matched set of elements + index: function( elem ) { + if ( !elem || typeof elem === "string" ) { + return jQuery.inArray( this[0], + // If it receives a string, the selector is used + // If it receives nothing, the siblings are used + elem ? jQuery( elem ) : this.parent().children() ); + } + // Locate the position of the desired element + return jQuery.inArray( + // If it receives a jQuery object, the first element is used + elem.jquery ? elem[0] : elem, this ); + }, + + add: function( selector, context ) { + var set = typeof selector === "string" ? + jQuery( selector, context || this.context ) : + jQuery.makeArray( selector ), + all = jQuery.merge( this.get(), set ); + + return this.pushStack( isDisconnected( set[0] ) || isDisconnected( all[0] ) ? + all : + jQuery.unique( all ) ); + }, + + andSelf: function() { + return this.add( this.prevObject ); + } +}); - // For whatever reason, IE has trouble passing the window object - // around, causing it to be cloned in the process - if ( elem.setInterval && elem != window ) - elem = window; +// A painfully simple check to see if an element is disconnected +// from a document (should be improved, where feasible). +function isDisconnected( node ) { + return !node || !node.parentNode || node.parentNode.nodeType === 11; +} - // Make sure that the function being executed has a unique ID - if ( !handler.guid ) - handler.guid = this.guid++; +jQuery.each({ + parent: function( elem ) { + var parent = elem.parentNode; + return parent && parent.nodeType !== 11 ? parent : null; + }, + parents: function( elem ) { + return jQuery.dir( elem, "parentNode" ); + }, + parentsUntil: function( elem, i, until ) { + return jQuery.dir( elem, "parentNode", until ); + }, + next: function( elem ) { + return jQuery.nth( elem, 2, "nextSibling" ); + }, + prev: function( elem ) { + return jQuery.nth( elem, 2, "previousSibling" ); + }, + nextAll: function( elem ) { + return jQuery.dir( elem, "nextSibling" ); + }, + prevAll: function( elem ) { + return jQuery.dir( elem, "previousSibling" ); + }, + nextUntil: function( elem, i, until ) { + return jQuery.dir( elem, "nextSibling", until ); + }, + prevUntil: function( elem, i, until ) { + return jQuery.dir( elem, "previousSibling", until ); + }, + siblings: function( elem ) { + return jQuery.sibling( elem.parentNode.firstChild, elem ); + }, + children: function( elem ) { + return jQuery.sibling( elem.firstChild ); + }, + contents: function( elem ) { + return jQuery.nodeName( elem, "iframe" ) ? + elem.contentDocument || elem.contentWindow.document : + jQuery.makeArray( elem.childNodes ); + } +}, function( name, fn ) { + jQuery.fn[ name ] = function( until, selector ) { + var ret = jQuery.map( this, fn, until ); + + if ( !runtil.test( name ) ) { + selector = until; + } - // if data is passed, bind to handler - if ( data !== undefined ) { - // Create temporary function pointer to original handler - var fn = handler; + if ( selector && typeof selector === "string" ) { + ret = jQuery.filter( selector, ret ); + } - // Create unique handler function, wrapped around original handler - handler = this.proxy( fn ); + ret = this.length > 1 ? jQuery.unique( ret ) : ret; - // Store data in unique handler - handler.data = data; + if ( (this.length > 1 || rmultiselector.test( selector )) && rparentsprev.test( name ) ) { + ret = ret.reverse(); } - // Init the element's event structure - var events = jQuery.data(elem, "events") || jQuery.data(elem, "events", {}), - handle = jQuery.data(elem, "handle") || jQuery.data(elem, "handle", function(){ - // Handle the second event of a trigger and when - // an event is called after a page has unloaded - return typeof jQuery !== "undefined" && !jQuery.event.triggered ? - jQuery.event.handle.apply(arguments.callee.elem, arguments) : - undefined; - }); - // Add elem as a property of the handle function - // This is to prevent a memory leak with non-native - // event in IE. - handle.elem = elem; + return this.pushStack( ret, name, slice.call(arguments).join(",") ); + }; +}); - // Handle multiple events separated by a space - // jQuery(...).bind("mouseover mouseout", fn); - jQuery.each(types.split(/\s+/), function(index, type) { - // Namespaced event handlers - var namespaces = type.split("."); - type = namespaces.shift(); - handler.type = namespaces.slice().sort().join("."); +jQuery.extend({ + filter: function( expr, elems, not ) { + if ( not ) { + expr = ":not(" + expr + ")"; + } - // Get the current list of functions bound to this event - var handlers = events[type]; - - if ( jQuery.event.specialAll[type] ) - jQuery.event.specialAll[type].setup.call(elem, data, namespaces); + return jQuery.find.matches(expr, elems); + }, + + dir: function( elem, dir, until ) { + var matched = [], cur = elem[dir]; + while ( cur && cur.nodeType !== 9 && (until === undefined || cur.nodeType !== 1 || !jQuery( cur ).is( until )) ) { + if ( cur.nodeType === 1 ) { + matched.push( cur ); + } + cur = cur[dir]; + } + return matched; + }, - // Init the event handler queue - if (!handlers) { - handlers = events[type] = {}; + nth: function( cur, result, dir, elem ) { + result = result || 1; + var num = 0; - // Check for a special event handler - // Only use addEventListener/attachEvent if the special - // events handler returns false - if ( !jQuery.event.special[type] || jQuery.event.special[type].setup.call(elem, data, namespaces) === false ) { - // Bind the global event handler to the element - if (elem.addEventListener) - elem.addEventListener(type, handle, false); - else if (elem.attachEvent) - elem.attachEvent("on" + type, handle); - } + for ( ; cur; cur = cur[dir] ) { + if ( cur.nodeType === 1 && ++num === result ) { + break; } + } - // Add the function to the element's handler list - handlers[handler.guid] = handler; + return cur; + }, - // Keep track of which events have been used, for global triggering - jQuery.event.global[type] = true; - }); + sibling: function( n, elem ) { + var r = []; + + for ( ; n; n = n.nextSibling ) { + if ( n.nodeType === 1 && n !== elem ) { + r.push( n ); + } + } - // Nullify elem to prevent memory leaks in IE - elem = null; + return r; + } +}); +var rinlinejQuery = / jQuery\d+="(?:\d+|null)"/g, + rleadingWhitespace = /^\s+/, + rxhtmlTag = /(<([\w:]+)[^>]*?)\/>/g, + rselfClosing = /^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i, + rtagName = /<([\w:]+)/, + rtbody = /<tbody/i, + rhtml = /<|&#?\w+;/, + rnocache = /<script|<object|<embed|<option|<style/i, + rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i, // checked="checked" or checked (html5) + fcloseTag = function( all, front, tag ) { + return rselfClosing.test( tag ) ? + all : + front + "></" + tag + ">"; }, + wrapMap = { + option: [ 1, "<select multiple='multiple'>", "</select>" ], + legend: [ 1, "<fieldset>", "</fieldset>" ], + thead: [ 1, "<table>", "</table>" ], + tr: [ 2, "<table><tbody>", "</tbody></table>" ], + td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ], + col: [ 2, "<table><tbody></tbody><colgroup>", "</colgroup></table>" ], + area: [ 1, "<map>", "</map>" ], + _default: [ 0, "", "" ] + }; - guid: 1, - global: {}, +wrapMap.optgroup = wrapMap.option; +wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead; +wrapMap.th = wrapMap.td; - // Detach an event or set of events from an element - remove: function(elem, types, handler) { - // don't do events on text and comment nodes - if ( elem.nodeType == 3 || elem.nodeType == 8 ) - return; +// IE can't serialize <link> and <script> tags normally +if ( !jQuery.support.htmlSerialize ) { + wrapMap._default = [ 1, "div<div>", "</div>" ]; +} - var events = jQuery.data(elem, "events"), ret, index; +jQuery.fn.extend({ + text: function( text ) { + if ( jQuery.isFunction(text) ) { + return this.each(function(i) { + var self = jQuery(this); + self.text( text.call(this, i, self.text()) ); + }); + } - if ( events ) { - // Unbind all events for the element - if ( types === undefined || (typeof types === "string" && types.charAt(0) == ".") ) - for ( var type in events ) - this.remove( elem, type + (types || "") ); - else { - // types is actually an event object here - if ( types.type ) { - handler = types.handler; - types = types.type; - } + if ( typeof text !== "object" && text !== undefined ) { + return this.empty().append( (this[0] && this[0].ownerDocument || document).createTextNode( text ) ); + } - // Handle multiple events seperated by a space - // jQuery(...).unbind("mouseover mouseout", fn); - jQuery.each(types.split(/\s+/), function(index, type){ - // Namespaced event handlers - var namespaces = type.split("."); - type = namespaces.shift(); - var namespace = RegExp("(^|\\.)" + namespaces.slice().sort().join(".*\\.") + "(\\.|$)"); + return jQuery.text( this ); + }, - if ( events[type] ) { - // remove the given handler for the given type - if ( handler ) - delete events[type][handler.guid]; + wrapAll: function( html ) { + if ( jQuery.isFunction( html ) ) { + return this.each(function(i) { + jQuery(this).wrapAll( html.call(this, i) ); + }); + } - // remove all handlers for the given type - else - for ( var handle in events[type] ) - // Handle the removal of namespaced events - if ( namespace.test(events[type][handle].type) ) - delete events[type][handle]; - - if ( jQuery.event.specialAll[type] ) - jQuery.event.specialAll[type].teardown.call(elem, namespaces); + if ( this[0] ) { + // The elements to wrap the target around + var wrap = jQuery( html, this[0].ownerDocument ).eq(0).clone(true); - // remove generic event handler if no more handlers exist - for ( ret in events[type] ) break; - if ( !ret ) { - if ( !jQuery.event.special[type] || jQuery.event.special[type].teardown.call(elem, namespaces) === false ) { - if (elem.removeEventListener) - elem.removeEventListener(type, jQuery.data(elem, "handle"), false); - else if (elem.detachEvent) - elem.detachEvent("on" + type, jQuery.data(elem, "handle")); - } - ret = null; - delete events[type]; - } - } - }); + if ( this[0].parentNode ) { + wrap.insertBefore( this[0] ); } - // Remove the expando if it's no longer used - for ( ret in events ) break; - if ( !ret ) { - var handle = jQuery.data( elem, "handle" ); - if ( handle ) handle.elem = null; - jQuery.removeData( elem, "events" ); - jQuery.removeData( elem, "handle" ); - } + wrap.map(function() { + var elem = this; + + while ( elem.firstChild && elem.firstChild.nodeType === 1 ) { + elem = elem.firstChild; + } + + return elem; + }).append(this); } + + return this; }, - // bubbling is internal - trigger: function( event, data, elem, bubbling ) { - // Event object or event type - var type = event.type || event; + wrapInner: function( html ) { + if ( jQuery.isFunction( html ) ) { + return this.each(function(i) { + jQuery(this).wrapInner( html.call(this, i) ); + }); + } + + return this.each(function() { + var self = jQuery( this ), contents = self.contents(); - if( !bubbling ){ - event = typeof event === "object" ? - // jQuery.Event object - event[expando] ? event : - // Object literal - jQuery.extend( jQuery.Event(type), event ) : - // Just the event type (string) - jQuery.Event(type); + if ( contents.length ) { + contents.wrapAll( html ); - if ( type.indexOf("!") >= 0 ) { - event.type = type = type.slice(0, -1); - event.exclusive = true; + } else { + self.append( html ); } + }); + }, - // Handle a global trigger - if ( !elem ) { - // Don't bubble custom events when global (to avoid too much overhead) - event.stopPropagation(); - // Only trigger if we've ever bound an event for it - if ( this.global[type] ) - jQuery.each( jQuery.cache, function(){ - if ( this.events && this.events[type] ) - jQuery.event.trigger( event, data, this.handle.elem ); - }); + wrap: function( html ) { + return this.each(function() { + jQuery( this ).wrapAll( html ); + }); + }, + + unwrap: function() { + return this.parent().each(function() { + if ( !jQuery.nodeName( this, "body" ) ) { + jQuery( this ).replaceWith( this.childNodes ); } + }).end(); + }, - // Handle triggering a single element + append: function() { + return this.domManip(arguments, true, function( elem ) { + if ( this.nodeType === 1 ) { + this.appendChild( elem ); + } + }); + }, - // don't do events on text and comment nodes - if ( !elem || elem.nodeType == 3 || elem.nodeType == 8 ) - return undefined; - - // Clean up in case it is reused - event.result = undefined; - event.target = elem; - - // Clone the incoming data, if any - data = jQuery.makeArray(data); - data.unshift( event ); + prepend: function() { + return this.domManip(arguments, true, function( elem ) { + if ( this.nodeType === 1 ) { + this.insertBefore( elem, this.firstChild ); + } + }); + }, + + before: function() { + if ( this[0] && this[0].parentNode ) { + return this.domManip(arguments, false, function( elem ) { + this.parentNode.insertBefore( elem, this ); + }); + } else if ( arguments.length ) { + var set = jQuery(arguments[0]); + set.push.apply( set, this.toArray() ); + return this.pushStack( set, "before", arguments ); } + }, - event.currentTarget = elem; + after: function() { + if ( this[0] && this[0].parentNode ) { + return this.domManip(arguments, false, function( elem ) { + this.parentNode.insertBefore( elem, this.nextSibling ); + }); + } else if ( arguments.length ) { + var set = this.pushStack( this, "after", arguments ); + set.push.apply( set, jQuery(arguments[0]).toArray() ); + return set; + } + }, + + // keepData is for internal use only--do not document + remove: function( selector, keepData ) { + for ( var i = 0, elem; (elem = this[i]) != null; i++ ) { + if ( !selector || jQuery.filter( selector, [ elem ] ).length ) { + if ( !keepData && elem.nodeType === 1 ) { + jQuery.cleanData( elem.getElementsByTagName("*") ); + jQuery.cleanData( [ elem ] ); + } - // Trigger the event, it is assumed that "handle" is a function - var handle = jQuery.data(elem, "handle"); - if ( handle ) - handle.apply( elem, data ); + if ( elem.parentNode ) { + elem.parentNode.removeChild( elem ); + } + } + } + + return this; + }, - // Handle triggering native .onfoo handlers (and on links since we don't call .click() for links) - if ( (!elem[type] || (jQuery.nodeName(elem, 'a') && type == "click")) && elem["on"+type] && elem["on"+type].apply( elem, data ) === false ) - event.result = false; + empty: function() { + for ( var i = 0, elem; (elem = this[i]) != null; i++ ) { + // Remove element nodes and prevent memory leaks + if ( elem.nodeType === 1 ) { + jQuery.cleanData( elem.getElementsByTagName("*") ); + } - // Trigger the native events (except for clicks on links) - if ( !bubbling && elem[type] && !event.isDefaultPrevented() && !(jQuery.nodeName(elem, 'a') && type == "click") ) { - this.triggered = true; - try { - elem[ type ](); - // prevent IE from throwing an error for some hidden elements - } catch (e) {} + // Remove any remaining nodes + while ( elem.firstChild ) { + elem.removeChild( elem.firstChild ); + } } + + return this; + }, - this.triggered = false; + clone: function( events ) { + // Do the clone + var ret = this.map(function() { + if ( !jQuery.support.noCloneEvent && !jQuery.isXMLDoc(this) ) { + // IE copies events bound via attachEvent when + // using cloneNode. Calling detachEvent on the + // clone will also remove the events from the orignal + // In order to get around this, we use innerHTML. + // Unfortunately, this means some modifications to + // attributes in IE that are actually only stored + // as properties will not be copied (such as the + // the name attribute on an input). + var html = this.outerHTML, ownerDocument = this.ownerDocument; + if ( !html ) { + var div = ownerDocument.createElement("div"); + div.appendChild( this.cloneNode(true) ); + html = div.innerHTML; + } - if ( !event.isPropagationStopped() ) { - var parent = elem.parentNode || elem.ownerDocument; - if ( parent ) - jQuery.event.trigger(event, data, parent, true); + return jQuery.clean([html.replace(rinlinejQuery, "") + // Handle the case in IE 8 where action=/test/> self-closes a tag + .replace(/=([^="'>\s]+\/)>/g, '="$1">') + .replace(rleadingWhitespace, "")], ownerDocument)[0]; + } else { + return this.cloneNode(true); + } + }); + + // Copy the events from the original to the clone + if ( events === true ) { + cloneCopyEvent( this, ret ); + cloneCopyEvent( this.find("*"), ret.find("*") ); } + + // Return the cloned set + return ret; }, - handle: function(event) { - // returned undefined or false - var all, handlers; + html: function( value ) { + if ( value === undefined ) { + return this[0] && this[0].nodeType === 1 ? + this[0].innerHTML.replace(rinlinejQuery, "") : + null; - event = arguments[0] = jQuery.event.fix( event || window.event ); - event.currentTarget = this; - - // Namespaced event handlers - var namespaces = event.type.split("."); - event.type = namespaces.shift(); + // See if we can take a shortcut and just use innerHTML + } else if ( typeof value === "string" && !rnocache.test( value ) && + (jQuery.support.leadingWhitespace || !rleadingWhitespace.test( value )) && + !wrapMap[ (rtagName.exec( value ) || ["", ""])[1].toLowerCase() ] ) { - // Cache this now, all = true means, any handler - all = !namespaces.length && !event.exclusive; - - var namespace = RegExp("(^|\\.)" + namespaces.slice().sort().join(".*\\.") + "(\\.|$)"); + value = value.replace(rxhtmlTag, fcloseTag); - handlers = ( jQuery.data(this, "events") || {} )[event.type]; + try { + for ( var i = 0, l = this.length; i < l; i++ ) { + // Remove element nodes and prevent memory leaks + if ( this[i].nodeType === 1 ) { + jQuery.cleanData( this[i].getElementsByTagName("*") ); + this[i].innerHTML = value; + } + } - for ( var j in handlers ) { - var handler = handlers[j]; + // If using innerHTML throws an exception, use the fallback method + } catch(e) { + this.empty().append( value ); + } - // Filter the functions by class - if ( all || namespace.test(handler.type) ) { - // Pass in a reference to the handler function itself - // So that we can later remove it - event.handler = handler; - event.data = handler.data; + } else if ( jQuery.isFunction( value ) ) { + this.each(function(i){ + var self = jQuery(this), old = self.html(); + self.empty().append(function(){ + return value.call( this, i, old ); + }); + }); - var ret = handler.apply(this, arguments); + } else { + this.empty().append( value ); + } - if( ret !== undefined ){ - event.result = ret; - if ( ret === false ) { - event.preventDefault(); - event.stopPropagation(); - } - } + return this; + }, - if( event.isImmediatePropagationStopped() ) - break; + replaceWith: function( value ) { + if ( this[0] && this[0].parentNode ) { + // Make sure that the elements are removed from the DOM before they are inserted + // this can help fix replacing a parent with child elements + if ( jQuery.isFunction( value ) ) { + return this.each(function(i) { + var self = jQuery(this), old = self.html(); + self.replaceWith( value.call( this, i, old ) ); + }); + } + if ( typeof value !== "string" ) { + value = jQuery(value).detach(); } + + return this.each(function() { + var next = this.nextSibling, parent = this.parentNode; + + jQuery(this).remove(); + + if ( next ) { + jQuery(next).before( value ); + } else { + jQuery(parent).append( value ); + } + }); + } else { + return this.pushStack( jQuery(jQuery.isFunction(value) ? value() : value), "replaceWith", value ); } }, - props: "altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "), + detach: function( selector ) { + return this.remove( selector, true ); + }, - fix: function(event) { - if ( event[expando] ) - return event; + domManip: function( args, table, callback ) { + var results, first, value = args[0], scripts = [], fragment, parent; - // store a copy of the original event object - // and "clone" to set read-only properties - var originalEvent = event; - event = jQuery.Event( originalEvent ); + // We can't cloneNode fragments that contain checked, in WebKit + if ( !jQuery.support.checkClone && arguments.length === 3 && typeof value === "string" && rchecked.test( value ) ) { + return this.each(function() { + jQuery(this).domManip( args, table, callback, true ); + }); + } - for ( var i = this.props.length, prop; i; ){ - prop = this.props[ --i ]; - event[ prop ] = originalEvent[ prop ]; + if ( jQuery.isFunction(value) ) { + return this.each(function(i) { + var self = jQuery(this); + args[0] = value.call(this, i, table ? self.html() : undefined); + self.domManip( args, table, callback ); + }); } - // Fix target property, if necessary - if ( !event.target ) - event.target = event.srcElement || document; // Fixes #1925 where srcElement might not be defined either + if ( this[0] ) { + parent = value && value.parentNode; + + // If we're in a fragment, just use that instead of building a new one + if ( jQuery.support.parentNode && parent && parent.nodeType === 11 && parent.childNodes.length === this.length ) { + results = { fragment: parent }; - // check if target is a textnode (safari) - if ( event.target.nodeType == 3 ) - event.target = event.target.parentNode; + } else { + results = buildFragment( args, this, scripts ); + } + + fragment = results.fragment; + + if ( fragment.childNodes.length === 1 ) { + first = fragment = fragment.firstChild; + } else { + first = fragment.firstChild; + } - // Add relatedTarget, if necessary - if ( !event.relatedTarget && event.fromElement ) - event.relatedTarget = event.fromElement == event.target ? event.toElement : event.fromElement; + if ( first ) { + table = table && jQuery.nodeName( first, "tr" ); + + for ( var i = 0, l = this.length; i < l; i++ ) { + callback.call( + table ? + root(this[i], first) : + this[i], + i > 0 || results.cacheable || this.length > 1 ? + fragment.cloneNode(true) : + fragment + ); + } + } - // Calculate pageX/Y if missing and clientX/Y available - if ( event.pageX == null && event.clientX != null ) { - var doc = document.documentElement, body = document.body; - event.pageX = event.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc.clientLeft || 0); - event.pageY = event.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc.clientTop || 0); + if ( scripts.length ) { + jQuery.each( scripts, evalScript ); + } } - // Add which for key events - if ( !event.which && ((event.charCode || event.charCode === 0) ? event.charCode : event.keyCode) ) - event.which = event.charCode || event.keyCode; + return this; - // Add metaKey to non-Mac browsers (use ctrl for PC's and Meta for Macs) - if ( !event.metaKey && event.ctrlKey ) - event.metaKey = event.ctrlKey; + function root( elem, cur ) { + return jQuery.nodeName(elem, "table") ? + (elem.getElementsByTagName("tbody")[0] || + elem.appendChild(elem.ownerDocument.createElement("tbody"))) : + elem; + } + } +}); + +function cloneCopyEvent(orig, ret) { + var i = 0; - // Add which for click: 1 == left; 2 == middle; 3 == right - // Note: button is not normalized, so don't use it - if ( !event.which && event.button ) - event.which = (event.button & 1 ? 1 : ( event.button & 2 ? 3 : ( event.button & 4 ? 2 : 0 ) )); + ret.each(function() { + if ( this.nodeName !== (orig[i] && orig[i].nodeName) ) { + return; + } - return event; - }, + var oldData = jQuery.data( orig[i++] ), curData = jQuery.data( this, oldData ), events = oldData && oldData.events; - proxy: function( fn, proxy ){ - proxy = proxy || function(){ return fn.apply(this, arguments); }; - // Set the guid of unique handler to the same of original handler, so it can be removed - proxy.guid = fn.guid = fn.guid || proxy.guid || this.guid++; - // So proxy can be declared as an argument - return proxy; - }, + if ( events ) { + delete curData.handle; + curData.events = {}; - special: { - ready: { - // Make sure the ready event is setup - setup: bindReady, - teardown: function() {} + for ( var type in events ) { + for ( var handler in events[ type ] ) { + jQuery.event.add( this, type, events[ type ][ handler ], events[ type ][ handler ].data ); + } + } } - }, - - specialAll: { - live: { - setup: function( selector, namespaces ){ - jQuery.event.add( this, namespaces[0], liveHandler ); - }, - teardown: function( namespaces ){ - if ( namespaces.length ) { - var remove = 0, name = RegExp("(^|\\.)" + namespaces[0] + "(\\.|$)"); - - jQuery.each( (jQuery.data(this, "events").live || {}), function(){ - if ( name.test(this.type) ) - remove++; - }); - - if ( remove < 1 ) - jQuery.event.remove( this, namespaces[0], liveHandler ); - } + }); +} + +function buildFragment( args, nodes, scripts ) { + var fragment, cacheable, cacheresults, + doc = (nodes && nodes[0] ? nodes[0].ownerDocument || nodes[0] : document); + + // Only cache "small" (1/2 KB) strings that are associated with the main document + // Cloning options loses the selected state, so don't cache them + // IE 6 doesn't like it when you put <object> or <embed> elements in a fragment + // Also, WebKit does not clone 'checked' attributes on cloneNode, so don't cache + if ( args.length === 1 && typeof args[0] === "string" && args[0].length < 512 && doc === document && + !rnocache.test( args[0] ) && (jQuery.support.checkClone || !rchecked.test( args[0] )) ) { + + cacheable = true; + cacheresults = jQuery.fragments[ args[0] ]; + if ( cacheresults ) { + if ( cacheresults !== 1 ) { + fragment = cacheresults; } } } -}; -jQuery.Event = function( src ){ - // Allow instantiation without the 'new' keyword - if( !this.preventDefault ) - return new jQuery.Event(src); - - // Event object - if( src && src.type ){ - this.originalEvent = src; - this.type = src.type; - // Event type - }else - this.type = src; + if ( !fragment ) { + fragment = doc.createDocumentFragment(); + jQuery.clean( args, doc, fragment, scripts ); + } - // timeStamp is buggy for some events on Firefox(#3843) - // So we won't rely on the native value - this.timeStamp = now(); - - // Mark it as fixed - this[expando] = true; -}; + if ( cacheable ) { + jQuery.fragments[ args[0] ] = cacheresults ? fragment : 1; + } -function returnFalse(){ - return false; -} -function returnTrue(){ - return true; + return { fragment: fragment, cacheable: cacheable }; } -// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding -// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html -jQuery.Event.prototype = { - preventDefault: function() { - this.isDefaultPrevented = returnTrue; - - var e = this.originalEvent; - if( !e ) - return; - // if preventDefault exists run it on the original event - if (e.preventDefault) - e.preventDefault(); - // otherwise set the returnValue property of the original event to false (IE) - e.returnValue = false; - }, - stopPropagation: function() { - this.isPropagationStopped = returnTrue; +jQuery.fragments = {}; - var e = this.originalEvent; - if( !e ) - return; - // if stopPropagation exists run it on the original event - if (e.stopPropagation) - e.stopPropagation(); - // otherwise set the cancelBubble property of the original event to true (IE) - e.cancelBubble = true; - }, - stopImmediatePropagation:function(){ - this.isImmediatePropagationStopped = returnTrue; - this.stopPropagation(); - }, - isDefaultPrevented: returnFalse, - isPropagationStopped: returnFalse, - isImmediatePropagationStopped: returnFalse -}; -// Checks if an event happened on an element within another element -// Used in jQuery.event.special.mouseenter and mouseleave handlers -var withinElement = function(event) { - // Check if mouse(over|out) are still within the same parent element - var parent = event.relatedTarget; - // Traverse up the tree - while ( parent && parent != this ) - try { parent = parent.parentNode; } - catch(e) { parent = this; } - - if( parent != this ){ - // set the correct event type - event.type = event.data; - // handle event if we actually just moused on to a non sub-element - jQuery.event.handle.apply( this, arguments ); - } -}; - -jQuery.each({ - mouseover: 'mouseenter', - mouseout: 'mouseleave' -}, function( orig, fix ){ - jQuery.event.special[ fix ] = { - setup: function(){ - jQuery.event.add( this, orig, withinElement, fix ); - }, - teardown: function(){ - jQuery.event.remove( this, orig, withinElement ); +jQuery.each({ + appendTo: "append", + prependTo: "prepend", + insertBefore: "before", + insertAfter: "after", + replaceAll: "replaceWith" +}, function( name, original ) { + jQuery.fn[ name ] = function( selector ) { + var ret = [], insert = jQuery( selector ), + parent = this.length === 1 && this[0].parentNode; + + if ( parent && parent.nodeType === 11 && parent.childNodes.length === 1 && insert.length === 1 ) { + insert[ original ]( this[0] ); + return this; + + } else { + for ( var i = 0, l = insert.length; i < l; i++ ) { + var elems = (i > 0 ? this.clone(true) : this).get(); + jQuery.fn[ original ].apply( jQuery(insert[i]), elems ); + ret = ret.concat( elems ); + } + + return this.pushStack( ret, name, insert.selector ); } - }; + }; }); -jQuery.fn.extend({ - bind: function( type, data, fn ) { - return type == "unload" ? this.one(type, data, fn) : this.each(function(){ - jQuery.event.add( this, type, fn || data, fn && data ); - }); - }, +jQuery.extend({ + clean: function( elems, context, fragment, scripts ) { + context = context || document; + + // !context.createElement fails in IE with an error but returns typeof 'object' + if ( typeof context.createElement === "undefined" ) { + context = context.ownerDocument || context[0] && context[0].ownerDocument || document; + } + + var ret = []; + + for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) { + if ( typeof elem === "number" ) { + elem += ""; + } + + if ( !elem ) { + continue; + } + + // Convert html string into DOM nodes + if ( typeof elem === "string" && !rhtml.test( elem ) ) { + elem = context.createTextNode( elem ); - one: function( type, data, fn ) { - var one = jQuery.event.proxy( fn || data, function(event) { - jQuery(this).unbind(event, one); - return (fn || data).apply( this, arguments ); - }); - return this.each(function(){ - jQuery.event.add( this, type, one, fn && data); - }); - }, + } else if ( typeof elem === "string" ) { + // Fix "XHTML"-style tags in all browsers + elem = elem.replace(rxhtmlTag, fcloseTag); - unbind: function( type, fn ) { - return this.each(function(){ - jQuery.event.remove( this, type, fn ); - }); - }, + // Trim whitespace, otherwise indexOf won't work as expected + var tag = (rtagName.exec( elem ) || ["", ""])[1].toLowerCase(), + wrap = wrapMap[ tag ] || wrapMap._default, + depth = wrap[0], + div = context.createElement("div"); - trigger: function( type, data ) { - return this.each(function(){ - jQuery.event.trigger( type, data, this ); - }); - }, + // Go to html and back, then peel off extra wrappers + div.innerHTML = wrap[1] + elem + wrap[2]; - triggerHandler: function( type, data ) { - if( this[0] ){ - var event = jQuery.Event(type); - event.preventDefault(); - event.stopPropagation(); - jQuery.event.trigger( event, data, this[0] ); - return event.result; - } - }, + // Move to the right depth + while ( depth-- ) { + div = div.lastChild; + } - toggle: function( fn ) { - // Save reference to arguments for access in closure - var args = arguments, i = 1; + // Remove IE's autoinserted <tbody> from table fragments + if ( !jQuery.support.tbody ) { - // link all the functions, so any of them can unbind this click handler - while( i < args.length ) - jQuery.event.proxy( fn, args[i++] ); + // String was a <table>, *may* have spurious <tbody> + var hasBody = rtbody.test(elem), + tbody = tag === "table" && !hasBody ? + div.firstChild && div.firstChild.childNodes : - return this.click( jQuery.event.proxy( fn, function(event) { - // Figure out which function to execute - this.lastToggle = ( this.lastToggle || 0 ) % i; + // String was a bare <thead> or <tfoot> + wrap[1] === "<table>" && !hasBody ? + div.childNodes : + []; - // Make sure that clicks stop - event.preventDefault(); + for ( var j = tbody.length - 1; j >= 0 ; --j ) { + if ( jQuery.nodeName( tbody[ j ], "tbody" ) && !tbody[ j ].childNodes.length ) { + tbody[ j ].parentNode.removeChild( tbody[ j ] ); + } + } - // and execute the function - return args[ this.lastToggle++ ].apply( this, arguments ) || false; - })); - }, + } - hover: function(fnOver, fnOut) { - return this.mouseenter(fnOver).mouseleave(fnOut); - }, + // IE completely kills leading whitespace when innerHTML is used + if ( !jQuery.support.leadingWhitespace && rleadingWhitespace.test( elem ) ) { + div.insertBefore( context.createTextNode( rleadingWhitespace.exec(elem)[0] ), div.firstChild ); + } - ready: function(fn) { - // Attach the listeners - bindReady(); + elem = div.childNodes; + } - // If the DOM is already ready - if ( jQuery.isReady ) - // Execute the function immediately - fn.call( document, jQuery ); + if ( elem.nodeType ) { + ret.push( elem ); + } else { + ret = jQuery.merge( ret, elem ); + } + } - // Otherwise, remember the function for later - else - // Add the function to the wait list - jQuery.readyList.push( fn ); + if ( fragment ) { + for ( var i = 0; ret[i]; i++ ) { + if ( scripts && jQuery.nodeName( ret[i], "script" ) && (!ret[i].type || ret[i].type.toLowerCase() === "text/javascript") ) { + scripts.push( ret[i].parentNode ? ret[i].parentNode.removeChild( ret[i] ) : ret[i] ); + + } else { + if ( ret[i].nodeType === 1 ) { + ret.splice.apply( ret, [i + 1, 0].concat(jQuery.makeArray(ret[i].getElementsByTagName("script"))) ); + } + fragment.appendChild( ret[i] ); + } + } + } - return this; + return ret; }, - live: function( type, fn ){ - var proxy = jQuery.event.proxy( fn ); - proxy.guid += this.selector + type; + cleanData: function( elems ) { + var data, id, cache = jQuery.cache, + special = jQuery.event.special, + deleteExpando = jQuery.support.deleteExpando; + + for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) { + id = elem[ jQuery.expando ]; + + if ( id ) { + data = cache[ id ]; + + if ( data.events ) { + for ( var type in data.events ) { + if ( special[ type ] ) { + jQuery.event.remove( elem, type ); - jQuery(document).bind( liveConvert(type, this.selector), this.selector, proxy ); + } else { + removeEvent( elem, type, data.handle ); + } + } + } + + if ( deleteExpando ) { + delete elem[ jQuery.expando ]; - return this; - }, - - die: function( type, fn ){ - jQuery(document).unbind( liveConvert(type, this.selector), fn ? { guid: fn.guid + this.selector + type } : null ); - return this; + } else if ( elem.removeAttribute ) { + elem.removeAttribute( jQuery.expando ); + } + + delete cache[ id ]; + } + } } }); +// exclude the following css properties to add px +var rexclude = /z-?index|font-?weight|opacity|zoom|line-?height/i, + ralpha = /alpha\([^)]*\)/, + ropacity = /opacity=([^)]*)/, + rfloat = /float/i, + rdashAlpha = /-([a-z])/ig, + rupper = /([A-Z])/g, + rnumpx = /^-?\d+(?:px)?$/i, + rnum = /^-?\d/, -function liveHandler( event ){ - var check = RegExp("(^|\\.)" + event.type + "(\\.|$)"), - stop = true, - elems = []; + cssShow = { position: "absolute", visibility: "hidden", display:"block" }, + cssWidth = [ "Left", "Right" ], + cssHeight = [ "Top", "Bottom" ], + + // cache check for defaultView.getComputedStyle + getComputedStyle = document.defaultView && document.defaultView.getComputedStyle, + // normalize float css property + styleFloat = jQuery.support.cssFloat ? "cssFloat" : "styleFloat", + fcamelCase = function( all, letter ) { + return letter.toUpperCase(); + }; - jQuery.each(jQuery.data(this, "events").live || [], function(i, fn){ - if ( check.test(fn.type) ) { - var elem = jQuery(event.target).closest(fn.data)[0]; - if ( elem ) - elems.push({ elem: elem, fn: fn }); +jQuery.fn.css = function( name, value ) { + return access( this, name, value, true, function( elem, name, value ) { + if ( value === undefined ) { + return jQuery.curCSS( elem, name ); + } + + if ( typeof value === "number" && !rexclude.test(name) ) { + value += "px"; } - }); - elems.sort(function(a,b) { - return jQuery.data(a.elem, "closest") - jQuery.data(b.elem, "closest"); + jQuery.style( elem, name, value ); }); - - jQuery.each(elems, function(){ - if ( this.fn.call(this.elem, event, this.fn.data) === false ) - return (stop = false); - }); +}; - return stop; -} +jQuery.extend({ + style: function( elem, name, value ) { + // don't set styles on text and comment nodes + if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 ) { + return undefined; + } -function liveConvert(type, selector){ - return ["live", type, selector.replace(/\./g, "`").replace(/ /g, "|")].join("."); -} + // ignore negative width and height values #1599 + if ( (name === "width" || name === "height") && parseFloat(value) < 0 ) { + value = undefined; + } -jQuery.extend({ - isReady: false, - readyList: [], - // Handle when the DOM is ready - ready: function() { - // Make sure that the DOM is not already loaded - if ( !jQuery.isReady ) { - // Remember that the DOM is ready - jQuery.isReady = true; + var style = elem.style || elem, set = value !== undefined; - // If there are functions bound, to execute - if ( jQuery.readyList ) { - // Execute all of them - jQuery.each( jQuery.readyList, function(){ - this.call( document, jQuery ); + // IE uses filters for opacity + if ( !jQuery.support.opacity && name === "opacity" ) { + if ( set ) { + // IE has trouble with opacity if it does not have layout + // Force it by setting the zoom level + style.zoom = 1; + + // Set the alpha filter to set the opacity + var opacity = parseInt( value, 10 ) + "" === "NaN" ? "" : "alpha(opacity=" + value * 100 + ")"; + var filter = style.filter || jQuery.curCSS( elem, "filter" ) || ""; + style.filter = ralpha.test(filter) ? filter.replace(ralpha, opacity) : opacity; + } + + return style.filter && style.filter.indexOf("opacity=") >= 0 ? + (parseFloat( ropacity.exec(style.filter)[1] ) / 100) + "": + ""; + } + + // Make sure we're using the right name for getting the float value + if ( rfloat.test( name ) ) { + name = styleFloat; + } + + name = name.replace(rdashAlpha, fcamelCase); + + if ( set ) { + style[ name ] = value; + } + + return style[ name ]; + }, + + css: function( elem, name, force, extra ) { + if ( name === "width" || name === "height" ) { + var val, props = cssShow, which = name === "width" ? cssWidth : cssHeight; + + function getWH() { + val = name === "width" ? elem.offsetWidth : elem.offsetHeight; + + if ( extra === "border" ) { + return; + } + + jQuery.each( which, function() { + if ( !extra ) { + val -= parseFloat(jQuery.curCSS( elem, "padding" + this, true)) || 0; + } + + if ( extra === "margin" ) { + val += parseFloat(jQuery.curCSS( elem, "margin" + this, true)) || 0; + } else { + val -= parseFloat(jQuery.curCSS( elem, "border" + this + "Width", true)) || 0; + } }); + } - // Reset the list of functions - jQuery.readyList = null; + if ( elem.offsetWidth !== 0 ) { + getWH(); + } else { + jQuery.swap( elem, props, getWH ); } - // Trigger any bound ready events - jQuery(document).triggerHandler("ready"); + return Math.max(0, Math.round(val)); + } + + return jQuery.curCSS( elem, name, force ); + }, + + curCSS: function( elem, name, force ) { + var ret, style = elem.style, filter; + + // IE uses filters for opacity + if ( !jQuery.support.opacity && name === "opacity" && elem.currentStyle ) { + ret = ropacity.test(elem.currentStyle.filter || "") ? + (parseFloat(RegExp.$1) / 100) + "" : + ""; + + return ret === "" ? + "1" : + ret; } - } -}); -var readyBound = false; + // Make sure we're using the right name for getting the float value + if ( rfloat.test( name ) ) { + name = styleFloat; + } -function bindReady(){ - if ( readyBound ) return; - readyBound = true; + if ( !force && style && style[ name ] ) { + ret = style[ name ]; - // Mozilla, Opera and webkit nightlies currently support this event - if ( document.addEventListener ) { - // Use the handy event callback - document.addEventListener( "DOMContentLoaded", function(){ - document.removeEventListener( "DOMContentLoaded", arguments.callee, false ); - jQuery.ready(); - }, false ); + } else if ( getComputedStyle ) { - // If IE event model is used - } else if ( document.attachEvent ) { - // ensure firing before onload, - // maybe late but safe also for iframes - document.attachEvent("onreadystatechange", function(){ - if ( document.readyState === "complete" ) { - document.detachEvent( "onreadystatechange", arguments.callee ); - jQuery.ready(); + // Only "float" is needed here + if ( rfloat.test( name ) ) { + name = "float"; } - }); - // If IE and not an iframe - // continually check to see if the document is ready - if ( document.documentElement.doScroll && window == window.top ) (function(){ - if ( jQuery.isReady ) return; + name = name.replace( rupper, "-$1" ).toLowerCase(); + + var defaultView = elem.ownerDocument.defaultView; - try { - // If IE is used, use the trick by Diego Perini - // http://javascript.nwbox.com/IEContentLoaded/ - document.documentElement.doScroll("left"); - } catch( error ) { - setTimeout( arguments.callee, 0 ); - return; + if ( !defaultView ) { + return null; } - // and execute any waiting functions - jQuery.ready(); - })(); - } + var computedStyle = defaultView.getComputedStyle( elem, null ); + + if ( computedStyle ) { + ret = computedStyle.getPropertyValue( name ); + } - // A fallback to window.onload, that will always work - jQuery.event.add( window, "load", jQuery.ready ); -} + // We should always get a number back from opacity + if ( name === "opacity" && ret === "" ) { + ret = "1"; + } -jQuery.each( ("blur,focus,load,resize,scroll,unload,click,dblclick," + - "mousedown,mouseup,mousemove,mouseover,mouseout,mouseenter,mouseleave," + - "change,select,submit,keydown,keypress,keyup,error").split(","), function(i, name){ + } else if ( elem.currentStyle ) { + var camelCase = name.replace(rdashAlpha, fcamelCase); - // Handle event binding - jQuery.fn[name] = function(fn){ - return fn ? this.bind(name, fn) : this.trigger(name); - }; -}); + ret = elem.currentStyle[ name ] || elem.currentStyle[ camelCase ]; -// Prevent memory leaks in IE -// And prevent errors on refresh with events like mouseover in other browsers -// Window isn't included so as not to unbind existing unload events -jQuery( window ).bind( 'unload', function(){ - for ( var id in jQuery.cache ) - // Skip the window - if ( id != 1 && jQuery.cache[ id ].handle ) - jQuery.event.remove( jQuery.cache[ id ].handle.elem ); -}); -(function(){ + // From the awesome hack by Dean Edwards + // http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291 - jQuery.support = {}; + // If we're not dealing with a regular pixel number + // but a number that has a weird ending, we need to convert it to pixels + if ( !rnumpx.test( ret ) && rnum.test( ret ) ) { + // Remember the original values + var left = style.left, rsLeft = elem.runtimeStyle.left; - var root = document.documentElement, - script = document.createElement("script"), - div = document.createElement("div"), - id = "script" + (new Date).getTime(); + // Put in the new values to get a computed value out + elem.runtimeStyle.left = elem.currentStyle.left; + style.left = camelCase === "fontSize" ? "1em" : (ret || 0); + ret = style.pixelLeft + "px"; - div.style.display = "none"; - div.innerHTML = ' <link/><table></table><a href="/a" style="color:red;float:left;opacity:.5;">a</a><select><option>text</option></select><object><param/></object>'; + // Revert the changed values + style.left = left; + elem.runtimeStyle.left = rsLeft; + } + } - var all = div.getElementsByTagName("*"), - a = div.getElementsByTagName("a")[0]; + return ret; + }, - // Can't get basic test support - if ( !all || !all.length || !a ) { - return; - } + // A method for quickly swapping in/out CSS properties to get correct calculations + swap: function( elem, options, callback ) { + var old = {}; - jQuery.support = { - // IE strips leading whitespace when .innerHTML is used - leadingWhitespace: div.firstChild.nodeType == 3, - - // Make sure that tbody elements aren't automatically inserted - // IE will insert them into empty tables - tbody: !div.getElementsByTagName("tbody").length, - - // Make sure that you can get all elements in an <object> element - // IE 7 always returns no results - objectAll: !!div.getElementsByTagName("object")[0] - .getElementsByTagName("*").length, - - // Make sure that link elements get serialized correctly by innerHTML - // This requires a wrapper element in IE - htmlSerialize: !!div.getElementsByTagName("link").length, - - // Get the style information from getAttribute - // (IE uses .cssText insted) - style: /red/.test( a.getAttribute("style") ), - - // Make sure that URLs aren't manipulated - // (IE normalizes it by default) - hrefNormalized: a.getAttribute("href") === "/a", - - // Make sure that element opacity exists - // (IE uses filter instead) - opacity: a.style.opacity === "0.5", - - // Verify style float existence - // (IE uses styleFloat instead of cssFloat) - cssFloat: !!a.style.cssFloat, + // Remember the old values, and insert the new ones + for ( var name in options ) { + old[ name ] = elem.style[ name ]; + elem.style[ name ] = options[ name ]; + } - // Will be defined later - scriptEval: false, - noCloneEvent: true, - boxModel: null - }; - - script.type = "text/javascript"; - try { - script.appendChild( document.createTextNode( "window." + id + "=1;" ) ); - } catch(e){} + callback.call( elem ); - root.insertBefore( script, root.firstChild ); - - // Make sure that the execution of code works by injecting a script - // tag with appendChild/createTextNode - // (IE doesn't support this, fails, and uses .text instead) - if ( window[ id ] ) { - jQuery.support.scriptEval = true; - delete window[ id ]; + // Revert the old values + for ( var name in options ) { + elem.style[ name ] = old[ name ]; + } } +}); - root.removeChild( script ); +if ( jQuery.expr && jQuery.expr.filters ) { + jQuery.expr.filters.hidden = function( elem ) { + var width = elem.offsetWidth, height = elem.offsetHeight, + skip = elem.nodeName.toLowerCase() === "tr"; - if ( div.attachEvent && div.fireEvent ) { - div.attachEvent("onclick", function(){ - // Cloning a node shouldn't copy over any - // bound event handlers (IE does this) - jQuery.support.noCloneEvent = false; - div.detachEvent("onclick", arguments.callee); - }); - div.cloneNode(true).fireEvent("onclick"); - } + return width === 0 && height === 0 && !skip ? + true : + width > 0 && height > 0 && !skip ? + false : + jQuery.curCSS(elem, "display") === "none"; + }; - // Figure out if the W3C box model works as expected - // document.body must exist before we can do this - jQuery(function(){ - var div = document.createElement("div"); - div.style.width = div.style.paddingLeft = "1px"; + jQuery.expr.filters.visible = function( elem ) { + return !jQuery.expr.filters.hidden( elem ); + }; +} +var jsc = now(), + rscript = /<script(.|\s)*?\/script>/gi, + rselectTextarea = /select|textarea/i, + rinput = /color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week/i, + jsre = /=\?(&|$)/, + rquery = /\?/, + rts = /(\?|&)_=.*?(&|$)/, + rurl = /^(\w+:)?\/\/([^\/?#]+)/, + r20 = /%20/g, - document.body.appendChild( div ); - jQuery.boxModel = jQuery.support.boxModel = div.offsetWidth === 2; - document.body.removeChild( div ).style.display = 'none'; - }); -})(); + // Keep a copy of the old load method + _load = jQuery.fn.load; -var styleFloat = jQuery.support.cssFloat ? "cssFloat" : "styleFloat"; - -jQuery.props = { - "for": "htmlFor", - "class": "className", - "float": styleFloat, - cssFloat: styleFloat, - styleFloat: styleFloat, - readonly: "readOnly", - maxlength: "maxLength", - cellspacing: "cellSpacing", - rowspan: "rowSpan", - tabindex: "tabIndex" -}; jQuery.fn.extend({ - // Keep a copy of the old load - _load: jQuery.fn.load, - load: function( url, params, callback ) { - if ( typeof url !== "string" ) - return this._load( url ); + if ( typeof url !== "string" ) { + return _load.call( this, url ); + + // Don't do a request if no elements are being requested + } else if ( !this.length ) { + return this; + } var off = url.indexOf(" "); if ( off >= 0 ) {@@ -3241,7 +4801,7 @@ // Default to a GET request
var type = "GET"; // If the second parameter was provided - if ( params ) + if ( params ) { // If it's a function if ( jQuery.isFunction( params ) ) { // We assume that it's the callback@@ -3249,10 +4809,11 @@ callback = params;
params = null; // Otherwise, build a param string - } else if( typeof params === "object" ) { - params = jQuery.param( params ); + } else if ( typeof params === "object" ) { + params = jQuery.param( params, jQuery.ajaxSettings.traditional ); type = "POST"; } + } var self = this;@@ -3262,27 +4823,30 @@ url: url,
type: type, dataType: "html", data: params, - complete: function(res, status){ + complete: function( res, status ) { // If successful, inject the HTML into all the matched elements - if ( status == "success" || status == "notmodified" ) + if ( status === "success" || status === "notmodified" ) { // See if a selector was specified self.html( selector ? // Create a dummy div to hold the results - jQuery("<div/>") + jQuery("<div />") // inject the contents of the document in, removing the scripts // to avoid any 'Permission Denied' errors in IE - .append(res.responseText.replace(/<script(.|\s)*?\/script>/g, "")) + .append(res.responseText.replace(rscript, "")) // Locate the specified elements .find(selector) : // If not, just inject the full result res.responseText ); + } - if( callback ) + if ( callback ) { self.each( callback, [res.responseText, status, res] ); + } } }); + return this; },@@ -3290,40 +4854,41 @@ serialize: function() {
return jQuery.param(this.serializeArray()); }, serializeArray: function() { - return this.map(function(){ + return this.map(function() { return this.elements ? jQuery.makeArray(this.elements) : this; }) - .filter(function(){ + .filter(function() { return this.name && !this.disabled && - (this.checked || /select|textarea/i.test(this.nodeName) || - /text|hidden|password|search/i.test(this.type)); + (this.checked || rselectTextarea.test(this.nodeName) || + rinput.test(this.type)); }) - .map(function(i, elem){ + .map(function( i, elem ) { var val = jQuery(this).val(); - return val == null ? null : + + return val == null ? + null : jQuery.isArray(val) ? - jQuery.map( val, function(val, i){ - return {name: elem.name, value: val}; + jQuery.map( val, function( val, i ) { + return { name: elem.name, value: val }; }) : - {name: elem.name, value: val}; + { name: elem.name, value: val }; }).get(); } }); // Attach a bunch of functions for handling common AJAX events -jQuery.each( "ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","), function(i,o){ - jQuery.fn[o] = function(f){ +jQuery.each( "ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "), function( i, o ) { + jQuery.fn[o] = function( f ) { return this.bind(o, f); }; }); -var jsc = now(); - jQuery.extend({ - + get: function( url, data, callback, type ) { - // shift arguments if data argument was ommited + // shift arguments if data argument was omited if ( jQuery.isFunction( data ) ) { + type = type || callback; callback = data; data = null; }@@ -3346,7 +4911,9 @@ return jQuery.get(url, data, callback, "json");
}, post: function( url, data, callback, type ) { + // shift arguments if data argument was omited if ( jQuery.isFunction( data ) ) { + type = type || callback; callback = data; data = {}; }@@ -3376,13 +4943,21 @@ timeout: 0,
data: null, username: null, password: null, + traditional: false, */ // Create the request object; Microsoft failed to properly - // implement the XMLHttpRequest in IE7, so we use the ActiveXObject when it is available + // implement the XMLHttpRequest in IE7 (can't request local files), + // so we use the ActiveXObject when it is available // This function can be overriden by calling jQuery.ajaxSetup - xhr:function(){ - return window.ActiveXObject ? new ActiveXObject("Microsoft.XMLHTTP") : new XMLHttpRequest(); - }, + xhr: window.XMLHttpRequest && (window.location.protocol !== "file:" || !window.ActiveXObject) ? + function() { + return new window.XMLHttpRequest(); + } : + function() { + try { + return new window.ActiveXObject("Microsoft.XMLHTTP"); + } catch(e) {} + }, accepts: { xml: "application/xml, text/xml", html: "text/html",@@ -3395,36 +4970,41 @@ },
// Last-Modified header cache for next request lastModified: {}, - - ajax: function( s ) { - // Extend the settings, but re-extend 's' so that it can be - // checked again later (in the test suite, specifically) - s = jQuery.extend(true, s, jQuery.extend(true, {}, jQuery.ajaxSettings, s)); + etag: {}, - var jsonp, jsre = /=\?(&|$)/g, status, data, + ajax: function( origSettings ) { + var s = jQuery.extend(true, {}, jQuery.ajaxSettings, origSettings); + + var jsonp, status, data, + callbackContext = origSettings && origSettings.context || s, type = s.type.toUpperCase(); // convert data if not already a string - if ( s.data && s.processData && typeof s.data !== "string" ) - s.data = jQuery.param(s.data); + if ( s.data && s.processData && typeof s.data !== "string" ) { + s.data = jQuery.param( s.data, s.traditional ); + } // Handle JSONP Parameter Callbacks - if ( s.dataType == "jsonp" ) { - if ( type == "GET" ) { - if ( !s.url.match(jsre) ) - s.url += (s.url.match(/\?/) ? "&" : "?") + (s.jsonp || "callback") + "=?"; - } else if ( !s.data || !s.data.match(jsre) ) + if ( s.dataType === "jsonp" ) { + if ( type === "GET" ) { + if ( !jsre.test( s.url ) ) { + s.url += (rquery.test( s.url ) ? "&" : "?") + (s.jsonp || "callback") + "=?"; + } + } else if ( !s.data || !jsre.test(s.data) ) { s.data = (s.data ? s.data + "&" : "") + (s.jsonp || "callback") + "=?"; + } s.dataType = "json"; } // Build temporary JSONP function - if ( s.dataType == "json" && (s.data && s.data.match(jsre) || s.url.match(jsre)) ) { - jsonp = "jsonp" + jsc++; + if ( s.dataType === "json" && (s.data && jsre.test(s.data) || jsre.test(s.url)) ) { + jsonp = s.jsonpCallback || ("jsonp" + jsc++); // Replace the =? sequence both in the query string and the data - if ( s.data ) + if ( s.data ) { s.data = (s.data + "").replace(jsre, "=" + jsonp + "$1"); + } + s.url = s.url.replace(jsre, "=" + jsonp + "$1"); // We need to make sure@@ -3432,75 +5012,85 @@ // that a JSONP style response is executed properly
s.dataType = "script"; // Handle JSONP-style loading - window[ jsonp ] = function(tmp){ + window[ jsonp ] = window[ jsonp ] || function( tmp ) { data = tmp; success(); complete(); // Garbage collect window[ jsonp ] = undefined; - try{ delete window[ jsonp ]; } catch(e){} - if ( head ) + + try { + delete window[ jsonp ]; + } catch(e) {} + + if ( head ) { head.removeChild( script ); + } }; } - if ( s.dataType == "script" && s.cache == null ) + if ( s.dataType === "script" && s.cache === null ) { s.cache = false; + } - if ( s.cache === false && type == "GET" ) { + if ( s.cache === false && type === "GET" ) { var ts = now(); + // try replacing _= if it is there - var ret = s.url.replace(/(\?|&)_=.*?(&|$)/, "$1_=" + ts + "$2"); + var ret = s.url.replace(rts, "$1_=" + ts + "$2"); + // if nothing was replaced, add timestamp to the end - s.url = ret + ((ret == s.url) ? (s.url.match(/\?/) ? "&" : "?") + "_=" + ts : ""); + s.url = ret + ((ret === s.url) ? (rquery.test(s.url) ? "&" : "?") + "_=" + ts : ""); } // If data is available, append data to url for get requests - if ( s.data && type == "GET" ) { - s.url += (s.url.match(/\?/) ? "&" : "?") + s.data; - - // IE likes to send both get and post data, prevent this - s.data = null; + if ( s.data && type === "GET" ) { + s.url += (rquery.test(s.url) ? "&" : "?") + s.data; } // Watch for a new set of requests - if ( s.global && ! jQuery.active++ ) + if ( s.global && ! jQuery.active++ ) { jQuery.event.trigger( "ajaxStart" ); + } // Matches an absolute URL, and saves the domain - var parts = /^(\w+:)?\/\/([^\/?#]+)/.exec( s.url ); + var parts = rurl.exec( s.url ), + remote = parts && (parts[1] && parts[1] !== location.protocol || parts[2] !== location.host); // If we're requesting a remote document // and trying to load JSON or Script with a GET - if ( s.dataType == "script" && type == "GET" && parts - && ( parts[1] && parts[1] != location.protocol || parts[2] != location.host )){ - - var head = document.getElementsByTagName("head")[0]; + if ( s.dataType === "script" && type === "GET" && remote ) { + var head = document.getElementsByTagName("head")[0] || document.documentElement; var script = document.createElement("script"); script.src = s.url; - if (s.scriptCharset) + if ( s.scriptCharset ) { script.charset = s.scriptCharset; + } // Handle Script loading if ( !jsonp ) { var done = false; // Attach handlers for all browsers - script.onload = script.onreadystatechange = function(){ + script.onload = script.onreadystatechange = function() { if ( !done && (!this.readyState || - this.readyState == "loaded" || this.readyState == "complete") ) { + this.readyState === "loaded" || this.readyState === "complete") ) { done = true; success(); complete(); // Handle memory leak in IE script.onload = script.onreadystatechange = null; - head.removeChild( script ); + if ( head && script.parentNode ) { + head.removeChild( script ); + } } }; } - head.appendChild(script); + // Use insertBefore instead of appendChild to circumvent an IE6 bug. + // This arises when a base node is used (#2709 and #4378). + head.insertBefore( script, head.firstChild ); // We handle everything using the script element injection return undefined;@@ -3510,159 +5100,198 @@ var requestDone = false;
// Create the request object var xhr = s.xhr(); + + if ( !xhr ) { + return; + } // Open the socket // Passing null username, generates a login popup on Opera (#2865) - if( s.username ) + if ( s.username ) { xhr.open(type, s.url, s.async, s.username, s.password); - else + } else { xhr.open(type, s.url, s.async); + } // Need an extra try/catch for cross domain requests in Firefox 3 try { // Set the correct header, if data is being sent - if ( s.data ) + if ( s.data || origSettings && origSettings.contentType ) { xhr.setRequestHeader("Content-Type", s.contentType); + } - // Set the If-Modified-Since header, if ifModified mode. - if ( s.ifModified ) - xhr.setRequestHeader("If-Modified-Since", - jQuery.lastModified[s.url] || "Thu, 01 Jan 1970 00:00:00 GMT" ); + // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode. + if ( s.ifModified ) { + if ( jQuery.lastModified[s.url] ) { + xhr.setRequestHeader("If-Modified-Since", jQuery.lastModified[s.url]); + } + + if ( jQuery.etag[s.url] ) { + xhr.setRequestHeader("If-None-Match", jQuery.etag[s.url]); + } + } // Set header so the called script knows that it's an XMLHttpRequest - xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest"); + // Only send the header if it's not a remote XHR + if ( !remote ) { + xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest"); + } // Set the Accepts header for the server, depending on the dataType xhr.setRequestHeader("Accept", s.dataType && s.accepts[ s.dataType ] ? s.accepts[ s.dataType ] + ", */*" : s.accepts._default ); - } catch(e){} + } catch(e) {} // Allow custom headers/mimetypes and early abort - if ( s.beforeSend && s.beforeSend(xhr, s) === false ) { + if ( s.beforeSend && s.beforeSend.call(callbackContext, xhr, s) === false ) { // Handle the global AJAX counter - if ( s.global && ! --jQuery.active ) + if ( s.global && ! --jQuery.active ) { jQuery.event.trigger( "ajaxStop" ); + } + // close opended socket xhr.abort(); return false; } - if ( s.global ) - jQuery.event.trigger("ajaxSend", [xhr, s]); + if ( s.global ) { + trigger("ajaxSend", [xhr, s]); + } // Wait for a response to come back - var onreadystatechange = function(isTimeout){ - // The request was aborted, clear the interval and decrement jQuery.active - if (xhr.readyState == 0) { - if (ival) { - // clear poll interval - clearInterval(ival); - ival = null; - // Handle the global AJAX counter - if ( s.global && ! --jQuery.active ) - jQuery.event.trigger( "ajaxStop" ); + var onreadystatechange = xhr.onreadystatechange = function( isTimeout ) { + // The request was aborted + if ( !xhr || xhr.readyState === 0 || isTimeout === "abort" ) { + // Opera doesn't call onreadystatechange before this point + // so we simulate the call + if ( !requestDone ) { + complete(); + } + + requestDone = true; + if ( xhr ) { + xhr.onreadystatechange = jQuery.noop; } + // The transfer is complete and the data is available, or the request timed out - } else if ( !requestDone && xhr && (xhr.readyState == 4 || isTimeout == "timeout") ) { + } else if ( !requestDone && xhr && (xhr.readyState === 4 || isTimeout === "timeout") ) { requestDone = true; + xhr.onreadystatechange = jQuery.noop; - // clear poll interval - if (ival) { - clearInterval(ival); - ival = null; - } + status = isTimeout === "timeout" ? + "timeout" : + !jQuery.httpSuccess( xhr ) ? + "error" : + s.ifModified && jQuery.httpNotModified( xhr, s.url ) ? + "notmodified" : + "success"; - status = isTimeout == "timeout" ? "timeout" : - !jQuery.httpSuccess( xhr ) ? "error" : - s.ifModified && jQuery.httpNotModified( xhr, s.url ) ? "notmodified" : - "success"; + var errMsg; - if ( status == "success" ) { + if ( status === "success" ) { // Watch for, and catch, XML document parse errors try { // process the data (runs the xml through httpData regardless of callback) data = jQuery.httpData( xhr, s.dataType, s ); - } catch(e) { + } catch(err) { status = "parsererror"; + errMsg = err; } } // Make sure that the request was successful or notmodified - if ( status == "success" ) { - // Cache Last-Modified header, if ifModified mode. - var modRes; - try { - modRes = xhr.getResponseHeader("Last-Modified"); - } catch(e) {} // swallow exception thrown by FF if header is not available - - if ( s.ifModified && modRes ) - jQuery.lastModified[s.url] = modRes; - + if ( status === "success" || status === "notmodified" ) { // JSONP handles its own success callback - if ( !jsonp ) + if ( !jsonp ) { success(); - } else - jQuery.handleError(s, xhr, status); + } + } else { + jQuery.handleError(s, xhr, status, errMsg); + } // Fire the complete handlers complete(); - if ( isTimeout ) + if ( isTimeout === "timeout" ) { xhr.abort(); + } // Stop memory leaks - if ( s.async ) + if ( s.async ) { xhr = null; + } } }; - if ( s.async ) { - // don't attach the handler to the request, just poll it instead - var ival = setInterval(onreadystatechange, 13); + // Override the abort handler, if we can (IE doesn't allow it, but that's OK) + // Opera doesn't fire onreadystatechange at all on abort + try { + var oldAbort = xhr.abort; + xhr.abort = function() { + if ( xhr ) { + oldAbort.call( xhr ); + } + + onreadystatechange( "abort" ); + }; + } catch(e) { } - // Timeout checker - if ( s.timeout > 0 ) - setTimeout(function(){ - // Check to see if the request is still happening - if ( xhr && !requestDone ) - onreadystatechange( "timeout" ); - }, s.timeout); + // Timeout checker + if ( s.async && s.timeout > 0 ) { + setTimeout(function() { + // Check to see if the request is still happening + if ( xhr && !requestDone ) { + onreadystatechange( "timeout" ); + } + }, s.timeout); } // Send the data try { - xhr.send(s.data); + xhr.send( type === "POST" || type === "PUT" || type === "DELETE" ? s.data : null ); } catch(e) { jQuery.handleError(s, xhr, null, e); + // Fire the complete handlers + complete(); } // firefox 1.5 doesn't fire statechange for sync requests - if ( !s.async ) + if ( !s.async ) { onreadystatechange(); + } - function success(){ + function success() { // If a local callback was specified, fire it and pass it the data - if ( s.success ) - s.success( data, status ); + if ( s.success ) { + s.success.call( callbackContext, data, status, xhr ); + } // Fire the global callback - if ( s.global ) - jQuery.event.trigger( "ajaxSuccess", [xhr, s] ); + if ( s.global ) { + trigger( "ajaxSuccess", [xhr, s] ); + } } - function complete(){ + function complete() { // Process result - if ( s.complete ) - s.complete(xhr, status); + if ( s.complete ) { + s.complete.call( callbackContext, xhr, status); + } // The request was completed - if ( s.global ) - jQuery.event.trigger( "ajaxComplete", [xhr, s] ); + if ( s.global ) { + trigger( "ajaxComplete", [xhr, s] ); + } // Handle the global AJAX counter - if ( s.global && ! --jQuery.active ) + if ( s.global && ! --jQuery.active ) { jQuery.event.trigger( "ajaxStop" ); + } + } + + function trigger(type, args) { + (s.context ? jQuery(s.context) : jQuery.event).trigger(type, args); } // return XMLHttpRequest to allow aborting the request etc.@@ -3671,11 +5300,14 @@ },
handleError: function( s, xhr, status, e ) { // If a local callback was specified, fire it - if ( s.error ) s.error( xhr, status, e ); + if ( s.error ) { + s.error.call( s.context || s, xhr, status, e ); + } // Fire the global callback - if ( s.global ) - jQuery.event.trigger( "ajaxError", [xhr, s, e] ); + if ( s.global ) { + (s.context ? jQuery(s.context) : jQuery.event).trigger( "ajaxError", [xhr, s, e] ); + } }, // Counter for holding the number of active queries@@ -3685,86 +5317,131 @@ // Determines if an XMLHttpRequest was successful or not
httpSuccess: function( xhr ) { try { // IE error sometimes returns 1223 when it should be 204 so treat it as success, see #1450 - return !xhr.status && location.protocol == "file:" || - ( xhr.status >= 200 && xhr.status < 300 ) || xhr.status == 304 || xhr.status == 1223; - } catch(e){} + return !xhr.status && location.protocol === "file:" || + // Opera returns 0 when status is 304 + ( xhr.status >= 200 && xhr.status < 300 ) || + xhr.status === 304 || xhr.status === 1223 || xhr.status === 0; + } catch(e) {} + return false; }, // Determines if an XMLHttpRequest returns NotModified httpNotModified: function( xhr, url ) { - try { - var xhrRes = xhr.getResponseHeader("Last-Modified"); + var lastModified = xhr.getResponseHeader("Last-Modified"), + etag = xhr.getResponseHeader("Etag"); + + if ( lastModified ) { + jQuery.lastModified[url] = lastModified; + } + + if ( etag ) { + jQuery.etag[url] = etag; + } - // Firefox always returns 200. check Last-Modified date - return xhr.status == 304 || xhrRes == jQuery.lastModified[url]; - } catch(e){} - return false; + // Opera returns 0 when status is 304 + return xhr.status === 304 || xhr.status === 0; }, httpData: function( xhr, type, s ) { - var ct = xhr.getResponseHeader("content-type"), - xml = type == "xml" || !type && ct && ct.indexOf("xml") >= 0, + var ct = xhr.getResponseHeader("content-type") || "", + xml = type === "xml" || !type && ct.indexOf("xml") >= 0, data = xml ? xhr.responseXML : xhr.responseText; - if ( xml && data.documentElement.tagName == "parsererror" ) - throw "parsererror"; - + if ( xml && data.documentElement.nodeName === "parsererror" ) { + jQuery.error( "parsererror" ); + } + // Allow a pre-filtering function to sanitize the response - // s != null is checked to keep backwards compatibility - if( s && s.dataFilter ) + // s is checked to keep backwards compatibility + if ( s && s.dataFilter ) { data = s.dataFilter( data, type ); + } // The filter can actually parse the response - if( typeof data === "string" ){ + if ( typeof data === "string" ) { + // Get the JavaScript object, if JSON is used. + if ( type === "json" || !type && ct.indexOf("json") >= 0 ) { + data = jQuery.parseJSON( data ); // If the type is "script", eval it in global context - if ( type == "script" ) + } else if ( type === "script" || !type && ct.indexOf("javascript") >= 0 ) { jQuery.globalEval( data ); - - // Get the JavaScript object, if JSON is used. - if ( type == "json" ) - data = window["eval"]("(" + data + ")"); + } } - + return data; }, // Serialize an array of form elements or a set of // key/values into a query string - param: function( a ) { - var s = [ ]; - - function add( key, value ){ - s[ s.length ] = encodeURIComponent(key) + '=' + encodeURIComponent(value); - }; - - // If an array was passed in, assume that it is an array - // of form elements - if ( jQuery.isArray(a) || a.jquery ) + param: function( a, traditional ) { + var s = []; + + // Set traditional to true for jQuery <= 1.3.2 behavior. + if ( traditional === undefined ) { + traditional = jQuery.ajaxSettings.traditional; + } + + // If an array was passed in, assume that it is an array of form elements. + if ( jQuery.isArray(a) || a.jquery ) { // Serialize the form elements - jQuery.each( a, function(){ + jQuery.each( a, function() { add( this.name, this.value ); }); - - // Otherwise, assume that it's an object of key/value pairs - else - // Serialize the key/values - for ( var j in a ) - // If the value is an array then the key names need to be repeated - if ( jQuery.isArray(a[j]) ) - jQuery.each( a[j], function(){ - add( j, this ); - }); - else - add( j, jQuery.isFunction(a[j]) ? a[j]() : a[j] ); + + } else { + // If traditional, encode the "old" way (the way 1.3.2 or older + // did it), otherwise encode params recursively. + for ( var prefix in a ) { + buildParams( prefix, a[prefix] ); + } + } // Return the resulting serialization - return s.join("&").replace(/%20/g, "+"); - } + return s.join("&").replace(r20, "+"); + function buildParams( prefix, obj ) { + if ( jQuery.isArray(obj) ) { + // Serialize array item. + jQuery.each( obj, function( i, v ) { + if ( traditional || /\[\]$/.test( prefix ) ) { + // Treat each array item as a scalar. + add( prefix, v ); + } else { + // If array item is non-scalar (array or object), encode its + // numeric index to resolve deserialization ambiguity issues. + // Note that rack (as of 1.0.0) can't currently deserialize + // nested arrays properly, and attempting to do so may cause + // a server error. Possible fixes are to modify rack's + // deserialization algorithm or to provide an option or flag + // to force array serialization to be shallow. + buildParams( prefix + "[" + ( typeof v === "object" || jQuery.isArray(v) ? i : "" ) + "]", v ); + } + }); + + } else if ( !traditional && obj != null && typeof obj === "object" ) { + // Serialize object item. + jQuery.each( obj, function( k, v ) { + buildParams( prefix + "[" + k + "]", v ); + }); + + } else { + // Serialize scalar item. + add( prefix, obj ); + } + } + + function add( key, value ) { + // If value is a function, invoke it and return its value + value = jQuery.isFunction(value) ? value() : value; + s[ s.length ] = encodeURIComponent(key) + "=" + encodeURIComponent(value); + } + } }); var elemdisplay = {}, + rfxtypes = /toggle|show|hide/, + rfxnum = /^([+-]=)?([\d+-.]+)(.*)$/, timerId, fxAttrs = [ // height animations@@ -3775,69 +5452,67 @@ // opacity animations
[ "opacity" ] ]; -function genFx( type, num ){ - var obj = {}; - jQuery.each( fxAttrs.concat.apply([], fxAttrs.slice(0,num)), function(){ - obj[ this ] = type; - }); - return obj; -} - jQuery.fn.extend({ - show: function(speed,callback){ - if ( speed ) { + show: function( speed, callback ) { + if ( speed || speed === 0) { return this.animate( genFx("show", 3), speed, callback); + } else { - for ( var i = 0, l = this.length; i < l; i++ ){ + for ( var i = 0, l = this.length; i < l; i++ ) { var old = jQuery.data(this[i], "olddisplay"); - + this[i].style.display = old || ""; - + if ( jQuery.css(this[i], "display") === "none" ) { - var tagName = this[i].tagName, display; - - if ( elemdisplay[ tagName ] ) { - display = elemdisplay[ tagName ]; + var nodeName = this[i].nodeName, display; + + if ( elemdisplay[ nodeName ] ) { + display = elemdisplay[ nodeName ]; + } else { - var elem = jQuery("<" + tagName + " />").appendTo("body"); - + var elem = jQuery("<" + nodeName + " />").appendTo("body"); + display = elem.css("display"); - if ( display === "none" ) + + if ( display === "none" ) { display = "block"; - + } + elem.remove(); - - elemdisplay[ tagName ] = display; + + elemdisplay[ nodeName ] = display; } - + jQuery.data(this[i], "olddisplay", display); } } // Set the display of the elements in a second loop // to avoid the constant reflow - for ( var i = 0, l = this.length; i < l; i++ ){ - this[i].style.display = jQuery.data(this[i], "olddisplay") || ""; + for ( var j = 0, k = this.length; j < k; j++ ) { + this[j].style.display = jQuery.data(this[j], "olddisplay") || ""; } - + return this; } }, - hide: function(speed,callback){ - if ( speed ) { + hide: function( speed, callback ) { + if ( speed || speed === 0 ) { return this.animate( genFx("hide", 3), speed, callback); + } else { - for ( var i = 0, l = this.length; i < l; i++ ){ + for ( var i = 0, l = this.length; i < l; i++ ) { var old = jQuery.data(this[i], "olddisplay"); - if ( !old && old !== "none" ) + if ( !old && old !== "none" ) { jQuery.data(this[i], "olddisplay", jQuery.css(this[i], "display")); + } } // Set the display of the elements in a second loop // to avoid the constant reflow - for ( var i = 0, l = this.length; i < l; i++ ){ - this[i].style.display = "none"; + for ( var j = 0, k = this.length; j < k; j++ ) { + this[j].style.display = "none"; } return this;@@ -3847,77 +5522,107 @@
// Save the old toggle function _toggle: jQuery.fn.toggle, - toggle: function( fn, fn2 ){ + toggle: function( fn, fn2 ) { var bool = typeof fn === "boolean"; - return jQuery.isFunction(fn) && jQuery.isFunction(fn2) ? - this._toggle.apply( this, arguments ) : - fn == null || bool ? - this.each(function(){ - var state = bool ? fn : jQuery(this).is(":hidden"); - jQuery(this)[ state ? "show" : "hide" ](); - }) : - this.animate(genFx("toggle", 3), fn, fn2); + if ( jQuery.isFunction(fn) && jQuery.isFunction(fn2) ) { + this._toggle.apply( this, arguments ); + + } else if ( fn == null || bool ) { + this.each(function() { + var state = bool ? fn : jQuery(this).is(":hidden"); + jQuery(this)[ state ? "show" : "hide" ](); + }); + + } else { + this.animate(genFx("toggle", 3), fn, fn2); + } + + return this; }, - fadeTo: function(speed,to,callback){ - return this.animate({opacity: to}, speed, callback); + fadeTo: function( speed, to, callback ) { + return this.filter(":hidden").css("opacity", 0).show().end() + .animate({opacity: to}, speed, callback); }, animate: function( prop, speed, easing, callback ) { var optall = jQuery.speed(speed, easing, callback); - return this[ optall.queue === false ? "each" : "queue" ](function(){ - + if ( jQuery.isEmptyObject( prop ) ) { + return this.each( optall.complete ); + } + + return this[ optall.queue === false ? "each" : "queue" ](function() { var opt = jQuery.extend({}, optall), p, - hidden = this.nodeType == 1 && jQuery(this).is(":hidden"), + hidden = this.nodeType === 1 && jQuery(this).is(":hidden"), self = this; - + for ( p in prop ) { - if ( prop[p] == "hide" && hidden || prop[p] == "show" && !hidden ) + var name = p.replace(rdashAlpha, fcamelCase); + + if ( p !== name ) { + prop[ name ] = prop[ p ]; + delete prop[ p ]; + p = name; + } + + if ( prop[p] === "hide" && hidden || prop[p] === "show" && !hidden ) { return opt.complete.call(this); + } - if ( ( p == "height" || p == "width" ) && this.style ) { + if ( ( p === "height" || p === "width" ) && this.style ) { // Store display property opt.display = jQuery.css(this, "display"); // Make sure that nothing sneaks out opt.overflow = this.style.overflow; } + + if ( jQuery.isArray( prop[p] ) ) { + // Create (if needed) and add to specialEasing + (opt.specialEasing = opt.specialEasing || {})[p] = prop[p][1]; + prop[p] = prop[p][0]; + } } - if ( opt.overflow != null ) + if ( opt.overflow != null ) { this.style.overflow = "hidden"; + } opt.curAnim = jQuery.extend({}, prop); - jQuery.each( prop, function(name, val){ + jQuery.each( prop, function( name, val ) { var e = new jQuery.fx( self, opt, name ); - if ( /toggle|show|hide/.test(val) ) - e[ val == "toggle" ? hidden ? "show" : "hide" : val ]( prop ); - else { - var parts = val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/), + if ( rfxtypes.test(val) ) { + e[ val === "toggle" ? hidden ? "show" : "hide" : val ]( prop ); + + } else { + var parts = rfxnum.exec(val), start = e.cur(true) || 0; if ( parts ) { - var end = parseFloat(parts[2]), + var end = parseFloat( parts[2] ), unit = parts[3] || "px"; // We need to compute starting value - if ( unit != "px" ) { + if ( unit !== "px" ) { self.style[ name ] = (end || 1) + unit; start = ((end || 1) / e.cur(true)) * start; self.style[ name ] = start + unit; } // If a +=/-= token was provided, we're doing a relative animation - if ( parts[1] ) - end = ((parts[1] == "-=" ? -1 : 1) * end) + start; + if ( parts[1] ) { + end = ((parts[1] === "-=" ? -1 : 1) * end) + start; + } e.custom( start, end, unit ); - } else + + } else { e.custom( start, val, "" ); + } } });@@ -3926,26 +5631,31 @@ return true;
}); }, - stop: function(clearQueue, gotoEnd){ + stop: function( clearQueue, gotoEnd ) { var timers = jQuery.timers; - if (clearQueue) + if ( clearQueue ) { this.queue([]); + } - this.each(function(){ + this.each(function() { // go in reverse order so anything added to the queue during the loop is ignored - for ( var i = timers.length - 1; i >= 0; i-- ) - if ( timers[i].elem == this ) { - if (gotoEnd) + for ( var i = timers.length - 1; i >= 0; i-- ) { + if ( timers[i].elem === this ) { + if (gotoEnd) { // force the next step to be the last timers[i](true); + } + timers.splice(i, 1); } + } }); // start the next in the queue if the last step wasn't forced - if (!gotoEnd) + if ( !gotoEnd ) { this.dequeue(); + } return this; }@@ -3959,16 +5669,15 @@ slideUp: genFx("hide", 1),
slideToggle: genFx("toggle", 1), fadeIn: { opacity: "show" }, fadeOut: { opacity: "hide" } -}, function( name, props ){ - jQuery.fn[ name ] = function( speed, callback ){ +}, function( name, props ) { + jQuery.fn[ name ] = function( speed, callback ) { return this.animate( props, speed, callback ); }; }); jQuery.extend({ - - speed: function(speed, easing, fn) { - var opt = typeof speed === "object" ? speed : { + speed: function( speed, easing, fn ) { + var opt = speed && typeof speed === "object" ? speed : { complete: fn || !fn && easing || jQuery.isFunction( speed ) && speed, duration: speed,@@ -3980,11 +5689,13 @@ jQuery.fx.speeds[opt.duration] || jQuery.fx.speeds._default;
// Queueing opt.old = opt.complete; - opt.complete = function(){ - if ( opt.queue !== false ) + opt.complete = function() { + if ( opt.queue !== false ) { jQuery(this).dequeue(); - if ( jQuery.isFunction( opt.old ) ) + } + if ( jQuery.isFunction( opt.old ) ) { opt.old.call( this ); + } }; return opt;@@ -4001,42 +5712,45 @@ },
timers: [], - fx: function( elem, options, prop ){ + fx: function( elem, options, prop ) { this.options = options; this.elem = elem; this.prop = prop; - if ( !options.orig ) + if ( !options.orig ) { options.orig = {}; + } } }); jQuery.fx.prototype = { - // Simple function for setting a style value - update: function(){ - if ( this.options.step ) + update: function() { + if ( this.options.step ) { this.options.step.call( this.elem, this.now, this ); + } (jQuery.fx.step[this.prop] || jQuery.fx.step._default)( this ); // Set display property to block for height/width animations - if ( ( this.prop == "height" || this.prop == "width" ) && this.elem.style ) + if ( ( this.prop === "height" || this.prop === "width" ) && this.elem.style ) { this.elem.style.display = "block"; + } }, // Get the current size - cur: function(force){ - if ( this.elem[this.prop] != null && (!this.elem.style || this.elem.style[this.prop] == null) ) + cur: function( force ) { + if ( this.elem[this.prop] != null && (!this.elem.style || this.elem.style[this.prop] == null) ) { return this.elem[ this.prop ]; + } var r = parseFloat(jQuery.css(this.elem, this.prop, force)); return r && r > -10000 ? r : parseFloat(jQuery.curCSS(this.elem, this.prop)) || 0; }, // Start an animation from one number to another - custom: function(from, to, unit){ + custom: function( from, to, unit ) { this.startTime = now(); this.start = from; this.end = to;@@ -4045,47 +5759,36 @@ this.now = this.start;
this.pos = this.state = 0; var self = this; - function t(gotoEnd){ + function t( gotoEnd ) { return self.step(gotoEnd); } t.elem = this.elem; if ( t() && jQuery.timers.push(t) && !timerId ) { - timerId = setInterval(function(){ - var timers = jQuery.timers; - - for ( var i = 0; i < timers.length; i++ ) - if ( !timers[i]() ) - timers.splice(i--, 1); - - if ( !timers.length ) { - clearInterval( timerId ); - timerId = undefined; - } - }, 13); + timerId = setInterval(jQuery.fx.tick, 13); } }, // Simple 'show' function - show: function(){ + show: function() { // Remember where we started, so that we can go back to it later - this.options.orig[this.prop] = jQuery.attr( this.elem.style, this.prop ); + this.options.orig[this.prop] = jQuery.style( this.elem, this.prop ); this.options.show = true; // Begin the animation // Make sure that we start at a small width/height to avoid any // flash of content - this.custom(this.prop == "width" || this.prop == "height" ? 1 : 0, this.cur()); + this.custom(this.prop === "width" || this.prop === "height" ? 1 : 0, this.cur()); // Start by showing the element - jQuery(this.elem).show(); + jQuery( this.elem ).show(); }, // Simple 'hide' function - hide: function(){ + hide: function() { // Remember where we started, so that we can go back to it later - this.options.orig[this.prop] = jQuery.attr( this.elem.style, this.prop ); + this.options.orig[this.prop] = jQuery.style( this.elem, this.prop ); this.options.hide = true; // Begin the animation@@ -4093,8 +5796,8 @@ this.custom(this.cur(), 0);
}, // Each step of an animation - step: function(gotoEnd){ - var t = now(); + step: function( gotoEnd ) { + var t = now(), done = true; if ( gotoEnd || t >= this.options.duration + this.startTime ) { this.now = this.end;@@ -4103,10 +5806,11 @@ this.update();
this.options.curAnim[ this.prop ] = true; - var done = true; - for ( var i in this.options.curAnim ) - if ( this.options.curAnim[i] !== true ) + for ( var i in this.options.curAnim ) { + if ( this.options.curAnim[i] !== true ) { done = false; + } + } if ( done ) { if ( this.options.display != null ) {@@ -4114,31 +5818,40 @@ // Reset the overflow
this.elem.style.overflow = this.options.overflow; // Reset the display - this.elem.style.display = this.options.display; - if ( jQuery.css(this.elem, "display") == "none" ) + var old = jQuery.data(this.elem, "olddisplay"); + this.elem.style.display = old ? old : this.options.display; + + if ( jQuery.css(this.elem, "display") === "none" ) { this.elem.style.display = "block"; + } } // Hide the element if the "hide" operation was done - if ( this.options.hide ) + if ( this.options.hide ) { jQuery(this.elem).hide(); + } // Reset the properties, if the item has been hidden or shown - if ( this.options.hide || this.options.show ) - for ( var p in this.options.curAnim ) - jQuery.attr(this.elem.style, p, this.options.orig[p]); - + if ( this.options.hide || this.options.show ) { + for ( var p in this.options.curAnim ) { + jQuery.style(this.elem, p, this.options.orig[p]); + } + } + // Execute the complete function this.options.complete.call( this.elem ); } return false; + } else { var n = t - this.startTime; this.state = n / this.options.duration; // Perform the easing function, defaults to swing - this.pos = jQuery.easing[this.options.easing || (jQuery.easing.swing ? "swing" : "linear")](this.state, n, 0, 1, this.options.duration); + var specialEasing = this.options.specialEasing && this.options.specialEasing[this.prop]; + var defaultEasing = this.options.easing || (jQuery.easing.swing ? "swing" : "linear"); + this.pos = jQuery.easing[specialEasing || defaultEasing](this.state, n, 0, 1, this.options.duration); this.now = this.start + ((this.end - this.start) * this.pos); // Perform the next step of the animation@@ -4147,232 +5860,381 @@ }
return true; } - }; jQuery.extend( jQuery.fx, { - speeds:{ + tick: function() { + var timers = jQuery.timers; + + for ( var i = 0; i < timers.length; i++ ) { + if ( !timers[i]() ) { + timers.splice(i--, 1); + } + } + + if ( !timers.length ) { + jQuery.fx.stop(); + } + }, + + stop: function() { + clearInterval( timerId ); + timerId = null; + }, + + speeds: { slow: 600, fast: 200, // Default speed _default: 400 }, + step: { - - opacity: function(fx){ - jQuery.attr(fx.elem.style, "opacity", fx.now); + opacity: function( fx ) { + jQuery.style(fx.elem, "opacity", fx.now); }, - _default: function(fx){ - if ( fx.elem.style && fx.elem.style[ fx.prop ] != null ) - fx.elem.style[ fx.prop ] = fx.now + fx.unit; - else + _default: function( fx ) { + if ( fx.elem.style && fx.elem.style[ fx.prop ] != null ) { + fx.elem.style[ fx.prop ] = (fx.prop === "width" || fx.prop === "height" ? Math.max(0, fx.now) : fx.now) + fx.unit; + } else { fx.elem[ fx.prop ] = fx.now; + } } } }); -if ( document.documentElement["getBoundingClientRect"] ) - jQuery.fn.offset = function() { - if ( !this[0] ) return { top: 0, left: 0 }; - if ( this[0] === this[0].ownerDocument.body ) return jQuery.offset.bodyOffset( this[0] ); - var box = this[0].getBoundingClientRect(), doc = this[0].ownerDocument, body = doc.body, docElem = doc.documentElement, + +if ( jQuery.expr && jQuery.expr.filters ) { + jQuery.expr.filters.animated = function( elem ) { + return jQuery.grep(jQuery.timers, function( fn ) { + return elem === fn.elem; + }).length; + }; +} + +function genFx( type, num ) { + var obj = {}; + + jQuery.each( fxAttrs.concat.apply([], fxAttrs.slice(0,num)), function() { + obj[ this ] = type; + }); + + return obj; +} +if ( "getBoundingClientRect" in document.documentElement ) { + jQuery.fn.offset = function( options ) { + var elem = this[0]; + + if ( options ) { + return this.each(function( i ) { + jQuery.offset.setOffset( this, options, i ); + }); + } + + if ( !elem || !elem.ownerDocument ) { + return null; + } + + if ( elem === elem.ownerDocument.body ) { + return jQuery.offset.bodyOffset( elem ); + } + + var box = elem.getBoundingClientRect(), doc = elem.ownerDocument, body = doc.body, docElem = doc.documentElement, clientTop = docElem.clientTop || body.clientTop || 0, clientLeft = docElem.clientLeft || body.clientLeft || 0, - top = box.top + (self.pageYOffset || jQuery.boxModel && docElem.scrollTop || body.scrollTop ) - clientTop, - left = box.left + (self.pageXOffset || jQuery.boxModel && docElem.scrollLeft || body.scrollLeft) - clientLeft; + top = box.top + (self.pageYOffset || jQuery.support.boxModel && docElem.scrollTop || body.scrollTop ) - clientTop, + left = box.left + (self.pageXOffset || jQuery.support.boxModel && docElem.scrollLeft || body.scrollLeft) - clientLeft; + return { top: top, left: left }; }; -else - jQuery.fn.offset = function() { - if ( !this[0] ) return { top: 0, left: 0 }; - if ( this[0] === this[0].ownerDocument.body ) return jQuery.offset.bodyOffset( this[0] ); - jQuery.offset.initialized || jQuery.offset.initialize(); + +} else { + jQuery.fn.offset = function( options ) { + var elem = this[0]; + + if ( options ) { + return this.each(function( i ) { + jQuery.offset.setOffset( this, options, i ); + }); + } + + if ( !elem || !elem.ownerDocument ) { + return null; + } + + if ( elem === elem.ownerDocument.body ) { + return jQuery.offset.bodyOffset( elem ); + } + + jQuery.offset.initialize(); - var elem = this[0], offsetParent = elem.offsetParent, prevOffsetParent = elem, + var offsetParent = elem.offsetParent, prevOffsetParent = elem, doc = elem.ownerDocument, computedStyle, docElem = doc.documentElement, body = doc.body, defaultView = doc.defaultView, - prevComputedStyle = defaultView.getComputedStyle(elem, null), + prevComputedStyle = defaultView ? defaultView.getComputedStyle( elem, null ) : elem.currentStyle, top = elem.offsetTop, left = elem.offsetLeft; while ( (elem = elem.parentNode) && elem !== body && elem !== docElem ) { - computedStyle = defaultView.getComputedStyle(elem, null); - top -= elem.scrollTop, left -= elem.scrollLeft; + if ( jQuery.offset.supportsFixedPosition && prevComputedStyle.position === "fixed" ) { + break; + } + + computedStyle = defaultView ? defaultView.getComputedStyle(elem, null) : elem.currentStyle; + top -= elem.scrollTop; + left -= elem.scrollLeft; + if ( elem === offsetParent ) { - top += elem.offsetTop, left += elem.offsetLeft; - if ( jQuery.offset.doesNotAddBorder && !(jQuery.offset.doesAddBorderForTableAndCells && /^t(able|d|h)$/i.test(elem.tagName)) ) - top += parseInt( computedStyle.borderTopWidth, 10) || 0, - left += parseInt( computedStyle.borderLeftWidth, 10) || 0; + top += elem.offsetTop; + left += elem.offsetLeft; + + if ( jQuery.offset.doesNotAddBorder && !(jQuery.offset.doesAddBorderForTableAndCells && /^t(able|d|h)$/i.test(elem.nodeName)) ) { + top += parseFloat( computedStyle.borderTopWidth ) || 0; + left += parseFloat( computedStyle.borderLeftWidth ) || 0; + } + prevOffsetParent = offsetParent, offsetParent = elem.offsetParent; } - if ( jQuery.offset.subtractsBorderForOverflowNotVisible && computedStyle.overflow !== "visible" ) - top += parseInt( computedStyle.borderTopWidth, 10) || 0, - left += parseInt( computedStyle.borderLeftWidth, 10) || 0; + + if ( jQuery.offset.subtractsBorderForOverflowNotVisible && computedStyle.overflow !== "visible" ) { + top += parseFloat( computedStyle.borderTopWidth ) || 0; + left += parseFloat( computedStyle.borderLeftWidth ) || 0; + } + prevComputedStyle = computedStyle; } - if ( prevComputedStyle.position === "relative" || prevComputedStyle.position === "static" ) - top += body.offsetTop, + if ( prevComputedStyle.position === "relative" || prevComputedStyle.position === "static" ) { + top += body.offsetTop; left += body.offsetLeft; + } - if ( prevComputedStyle.position === "fixed" ) - top += Math.max(docElem.scrollTop, body.scrollTop), - left += Math.max(docElem.scrollLeft, body.scrollLeft); + if ( jQuery.offset.supportsFixedPosition && prevComputedStyle.position === "fixed" ) { + top += Math.max( docElem.scrollTop, body.scrollTop ); + left += Math.max( docElem.scrollLeft, body.scrollLeft ); + } return { top: top, left: left }; }; +} jQuery.offset = { initialize: function() { - if ( this.initialized ) return; - var body = document.body, container = document.createElement('div'), innerDiv, checkDiv, table, td, rules, prop, bodyMarginTop = body.style.marginTop, - html = '<div style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;"><div></div></div><table style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;" cellpadding="0" cellspacing="0"><tr><td></td></tr></table>'; + var body = document.body, container = document.createElement("div"), innerDiv, checkDiv, table, td, bodyMarginTop = parseFloat( jQuery.curCSS(body, "marginTop", true) ) || 0, + html = "<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>"; - rules = { position: 'absolute', top: 0, left: 0, margin: 0, border: 0, width: '1px', height: '1px', visibility: 'hidden' }; - for ( prop in rules ) container.style[prop] = rules[prop]; + jQuery.extend( container.style, { position: "absolute", top: 0, left: 0, margin: 0, border: 0, width: "1px", height: "1px", visibility: "hidden" } ); container.innerHTML = html; - body.insertBefore(container, body.firstChild); - innerDiv = container.firstChild, checkDiv = innerDiv.firstChild, td = innerDiv.nextSibling.firstChild.firstChild; + body.insertBefore( container, body.firstChild ); + innerDiv = container.firstChild; + checkDiv = innerDiv.firstChild; + td = innerDiv.nextSibling.firstChild.firstChild; this.doesNotAddBorder = (checkDiv.offsetTop !== 5); this.doesAddBorderForTableAndCells = (td.offsetTop === 5); - innerDiv.style.overflow = 'hidden', innerDiv.style.position = 'relative'; + checkDiv.style.position = "fixed", checkDiv.style.top = "20px"; + // safari subtracts parent border width here which is 5px + this.supportsFixedPosition = (checkDiv.offsetTop === 20 || checkDiv.offsetTop === 15); + checkDiv.style.position = checkDiv.style.top = ""; + + innerDiv.style.overflow = "hidden", innerDiv.style.position = "relative"; this.subtractsBorderForOverflowNotVisible = (checkDiv.offsetTop === -5); - body.style.marginTop = '1px'; - this.doesNotIncludeMarginInBodyOffset = (body.offsetTop === 0); - body.style.marginTop = bodyMarginTop; + this.doesNotIncludeMarginInBodyOffset = (body.offsetTop !== bodyMarginTop); - body.removeChild(container); - this.initialized = true; + body.removeChild( container ); + body = container = innerDiv = checkDiv = table = td = null; + jQuery.offset.initialize = jQuery.noop; }, - bodyOffset: function(body) { - jQuery.offset.initialized || jQuery.offset.initialize(); + bodyOffset: function( body ) { var top = body.offsetTop, left = body.offsetLeft; - if ( jQuery.offset.doesNotIncludeMarginInBodyOffset ) - top += parseInt( jQuery.curCSS(body, 'marginTop', true), 10 ) || 0, - left += parseInt( jQuery.curCSS(body, 'marginLeft', true), 10 ) || 0; + + jQuery.offset.initialize(); + + if ( jQuery.offset.doesNotIncludeMarginInBodyOffset ) { + top += parseFloat( jQuery.curCSS(body, "marginTop", true) ) || 0; + left += parseFloat( jQuery.curCSS(body, "marginLeft", true) ) || 0; + } + return { top: top, left: left }; + }, + + setOffset: function( elem, options, i ) { + // set position first, in-case top/left are set even on static elem + if ( /static/.test( jQuery.curCSS( elem, "position" ) ) ) { + elem.style.position = "relative"; + } + var curElem = jQuery( elem ), + curOffset = curElem.offset(), + curTop = parseInt( jQuery.curCSS( elem, "top", true ), 10 ) || 0, + curLeft = parseInt( jQuery.curCSS( elem, "left", true ), 10 ) || 0; + + if ( jQuery.isFunction( options ) ) { + options = options.call( elem, i, curOffset ); + } + + var props = { + top: (options.top - curOffset.top) + curTop, + left: (options.left - curOffset.left) + curLeft + }; + + if ( "using" in options ) { + options.using.call( elem, props ); + } else { + curElem.css( props ); + } } }; jQuery.fn.extend({ position: function() { - var left = 0, top = 0, results; + if ( !this[0] ) { + return null; + } - if ( this[0] ) { - // Get *real* offsetParent - var offsetParent = this.offsetParent(), + var elem = this[0], - // Get correct offsets - offset = this.offset(), - parentOffset = /^body|html$/i.test(offsetParent[0].tagName) ? { top: 0, left: 0 } : offsetParent.offset(); + // Get *real* offsetParent + offsetParent = this.offsetParent(), - // Subtract element margins - // note: when an element has margin: auto the offsetLeft and marginLeft - // are the same in Safari causing offset.left to incorrectly be 0 - offset.top -= num( this, 'marginTop' ); - offset.left -= num( this, 'marginLeft' ); + // Get correct offsets + offset = this.offset(), + parentOffset = /^body|html$/i.test(offsetParent[0].nodeName) ? { top: 0, left: 0 } : offsetParent.offset(); - // Add offsetParent borders - parentOffset.top += num( offsetParent, 'borderTopWidth' ); - parentOffset.left += num( offsetParent, 'borderLeftWidth' ); + // Subtract element margins + // note: when an element has margin: auto the offsetLeft and marginLeft + // are the same in Safari causing offset.left to incorrectly be 0 + offset.top -= parseFloat( jQuery.curCSS(elem, "marginTop", true) ) || 0; + offset.left -= parseFloat( jQuery.curCSS(elem, "marginLeft", true) ) || 0; - // Subtract the two offsets - results = { - top: offset.top - parentOffset.top, - left: offset.left - parentOffset.left - }; - } + // Add offsetParent borders + parentOffset.top += parseFloat( jQuery.curCSS(offsetParent[0], "borderTopWidth", true) ) || 0; + parentOffset.left += parseFloat( jQuery.curCSS(offsetParent[0], "borderLeftWidth", true) ) || 0; - return results; + // Subtract the two offsets + return { + top: offset.top - parentOffset.top, + left: offset.left - parentOffset.left + }; }, offsetParent: function() { - var offsetParent = this[0].offsetParent || document.body; - while ( offsetParent && (!/^body|html$/i.test(offsetParent.tagName) && jQuery.css(offsetParent, 'position') == 'static') ) - offsetParent = offsetParent.offsetParent; - return jQuery(offsetParent); + return this.map(function() { + var offsetParent = this.offsetParent || document.body; + while ( offsetParent && (!/^body|html$/i.test(offsetParent.nodeName) && jQuery.css(offsetParent, "position") === "static") ) { + offsetParent = offsetParent.offsetParent; + } + return offsetParent; + }); } }); // Create scrollLeft and scrollTop methods -jQuery.each( ['Left', 'Top'], function(i, name) { - var method = 'scroll' + name; - +jQuery.each( ["Left", "Top"], function( i, name ) { + var method = "scroll" + name; + jQuery.fn[ method ] = function(val) { - if (!this[0]) return null; + var elem = this[0], win; + + if ( !elem ) { + return null; + } + + if ( val !== undefined ) { + // Set the scroll offset + return this.each(function() { + win = getWindow( this ); - return val !== undefined ? + if ( win ) { + win.scrollTo( + !i ? val : jQuery(win).scrollLeft(), + i ? val : jQuery(win).scrollTop() + ); - // Set the scroll offset - this.each(function() { - this == window || this == document ? - window.scrollTo( - !i ? val : jQuery(window).scrollLeft(), - i ? val : jQuery(window).scrollTop() - ) : + } else { this[ method ] = val; - }) : + } + }); + } else { + win = getWindow( elem ); // Return the scroll offset - this[0] == window || this[0] == document ? - self[ i ? 'pageYOffset' : 'pageXOffset' ] || - jQuery.boxModel && document.documentElement[ method ] || - document.body[ method ] : - this[0][ method ]; + return win ? ("pageXOffset" in win) ? win[ i ? "pageYOffset" : "pageXOffset" ] : + jQuery.support.boxModel && win.document.documentElement[ method ] || + win.document.body[ method ] : + elem[ method ]; + } }; }); + +function getWindow( elem ) { + return ("scrollTo" in elem && elem.document) ? + elem : + elem.nodeType === 9 ? + elem.defaultView || elem.parentWindow : + false; +} // Create innerHeight, innerWidth, outerHeight and outerWidth methods -jQuery.each([ "Height", "Width" ], function(i, name){ +jQuery.each([ "Height", "Width" ], function( i, name ) { - var tl = i ? "Left" : "Top", // top or left - br = i ? "Right" : "Bottom", // bottom or right - lower = name.toLowerCase(); + var type = name.toLowerCase(); // innerHeight and innerWidth - jQuery.fn["inner" + name] = function(){ + jQuery.fn["inner" + name] = function() { return this[0] ? - jQuery.css( this[0], lower, false, "padding" ) : + jQuery.css( this[0], type, false, "padding" ) : null; }; // outerHeight and outerWidth - jQuery.fn["outer" + name] = function(margin) { + jQuery.fn["outer" + name] = function( margin ) { return this[0] ? - jQuery.css( this[0], lower, false, margin ? "margin" : "border" ) : + jQuery.css( this[0], type, false, margin ? "margin" : "border" ) : null; }; - - var type = name.toLowerCase(); jQuery.fn[ type ] = function( size ) { // Get window width or height - return this[0] == window ? + var elem = this[0]; + if ( !elem ) { + return size == null ? null : this; + } + + if ( jQuery.isFunction( size ) ) { + return this.each(function( i ) { + var self = jQuery( this ); + self[ type ]( size.call( this, i, self[ type ]() ) ); + }); + } + + return ("scrollTo" in elem && elem.document) ? // does it walk and quack like a window? // Everyone else use document.documentElement or document.body depending on Quirks vs Standards mode - document.compatMode == "CSS1Compat" && document.documentElement[ "client" + name ] || - document.body[ "client" + name ] : + elem.document.compatMode === "CSS1Compat" && elem.document.documentElement[ "client" + name ] || + elem.document.body[ "client" + name ] : // Get document width or height - this[0] == document ? + (elem.nodeType === 9) ? // is it a document // Either scroll[Width/Height] or offset[Width/Height], whichever is greater Math.max( - document.documentElement["client" + name], - document.body["scroll" + name], document.documentElement["scroll" + name], - document.body["offset" + name], document.documentElement["offset" + name] + elem.documentElement["client" + name], + elem.body["scroll" + name], elem.documentElement["scroll" + name], + elem.body["offset" + name], elem.documentElement["offset" + name] ) : // Get or set width or height on the element size === undefined ? // Get width or height on the element - (this.length ? jQuery.css( this[0], type ) : null) : + jQuery.css( elem, type ) : // Set the width or height on the element (default to pixels if value is unitless) this.css( type, typeof size === "string" ? size : size + "px" ); }; }); -})(); +// Expose jQuery to the global object +window.jQuery = window.$ = jQuery; + +})(window);
@@ -1,5 +1,3 @@
------ ------ google.load('search', '1', {nocss: 1}); function OnLoad() {@@ -23,4 +21,4 @@
searchControl.draw(document.getElementById("search_results"), draw_options); } -google.setOnLoadCallback(OnLoad); +google.setOnLoadCallback(OnLoad);
@@ -9,8 +9,13 @@
You can't really ask or pay to be on this page, what you _can_ do is make your site interesting enough that I'll feel obliged to list it here. I don't really visit any of these web sites often, I normally read their feeds regularly in "Google Reader":http://www.google.com/reader, so they are categorized according to the Google Reader folders I use. <script type="text/javascript" src="http://www.google.com/reader/ui/publisher-en.js"></script> -<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/14176324761214556276/label/Blogs?callback=GRC_p(%7Bc%3A%22-%22%2Ct%3A%22Blogs%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> -<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/14176324761214556276/label/News?callback=GRC_p(%7Bc%3A%22-%22%2Ct%3A%22News%20Sites%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> -<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/14176324761214556276/label/Programming?callback=GRC_p(%7Bc%3A%22-%22%2Ct%3A%22Programming%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> -<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/14176324761214556276/label/Ruby?callback=GRC_p(%7Bc%3A%22-%22%2Ct%3A%22Ruby%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> -<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/14176324761214556276/label/Software?callback=GRC_p(%7Bc%3A%22-%22%2Ct%3A%22Software%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> +<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/17885544216336877607/label/Blogs?callback=GRC_p(%7Bc%3A%22blue%22%2Ct%3A%22Blogs%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> +<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/17885544216336877607/label/News?callback=GRC_p(%7Bc%3A%22blue%22%2Ct%3A%22News%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> +<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/17885544216336877607/label/Comics?callback=GRC_p(%7Bc%3A%22blue%22%2Ct%3A%22Comics%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> +<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/17885544216336877607/label/Programming?callback=GRC_p(%7Bc%3A%22blue%22%2Ct%3A%22Programming%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> +<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/17885544216336877607/label/Ruby?callback=GRC_p(%7Bc%3A%22blue%22%2Ct%3A%22Ruby%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> +<script type="text/javascript" src="http://www.google.com/reader/public/javascript-sub/user/17885544216336877607/label/Software?callback=GRC_p(%7Bc%3A%22blue%22%2Ct%3A%22Software%22%2Cb%3A%22true%22%7D)%3Bnew%20GRC"></script> + + + +
@@ -1,14 +0,0 @@
------ -:type: page -:permalink: other -:title: "Other" ------ -!>/images/theme/heraldry/gryphon.png! - -This is a repository for other pages and sections that are somehow unrelated to the rest of the web site. In other words, anything that is not an "article":/archives/ or a "project":/projects/ goes here so that it doesn't get lost. - -- "Links":/links/ := A collection of useful links to other web sites that I consider interesting, to some degree. -- "Holidays":/holidays/ := Information on my family house in the countryside near Bogliasco, Genoa (IT); available for rent. - - -
@@ -3,16 +3,11 @@ permalink: projects
title: Projects type: page ----- -!>/images/theme/heraldry/dragon.png! - -<span class="dropcap">T</span>his page lists all my _projects_. Except for a few cases, they normally are: +This page lists all my _projects_. Except for a few cases, they normally are: * open source * programming-related * developed using the "Ruby programming language":http://www.ruby-lang.org * hosted on "GitHub":http://www.github.com/h3rald - -<div class="spacer-50"></div> -<div class="spacer-50"></div> - "H3RALD Web Site":/h3rald/ := This very web site, in its 8th incarnation. H3RALD.com has been operative since 2004 and through the years its backend changed from being pure vanilla HTML, to server-side PHP (Prado and CakePHP) to Ruby (Rails, Nanoc). - "Glyph":/glyph/ := A _Rapid Document Authoring Framework_ written in Ruby that can be used to create and manage books and articles.
@@ -3,7 +3,8 @@ permalink: rawline
filters_pre: - erb - redcloth -title: "Project: RawLine" +title: "RawLine" +subtitle: A pure-ruby alternative to ReadLine type: project github: rawline links:@@ -22,8 +23,6 @@ * Basic line editing operations
* Word completion * History Management * Custom key/key sequences bindings - -<br style="clear:both" /> h3. Installation
@@ -0,0 +1,51 @@
+.code { + -webkit-border-radius: 5px; + -moz-border-radius: 5px; + border-radius: 5px; + background-color: #222; + font-family: 'Courier New', 'Terminal', monospace; + color: #E6E0DB; + padding: 20px; + overflow: auto; + font-size: 12px; + margin: 20px 0 20px 0; + pre { + line-height: 1.2em; + margin: 0px; + padding: 0px; } + .no { + font-weight: bold; + color: #595959; + } + .an { + color: #E7BE69; } + .c { + color: #BC9358; + font-style: italic; } + .ch { + color: #509E4F; } + .cl, .co { + color: #FFF; } + .fl { + color: #A4C260; } + .fu { + color: #FFC56D; } + .gv { + color: #D0CFFE; } + .i { + color: #A4C260; } + .il {} + .iv { + color: #D0CFFE; } + .pp { + color: #E7BE69; } + .r { + color: #CB7832; } + .rx, .s { + color: #A4C260; } + .sy { + color: #6C9CBD; } + .ta { + color: #E7BE69; } + .pc { + color: #6C9CBD; } }
@@ -0,0 +1,411 @@
+/* Content */ + +article > header { + h1 { + @include standard-font; + font-weight: bold; + color: #000; + line-height: 1.1em; + padding-top: 0.2em; + text-align:left; + height: 60%; + a { + color: #000; + text-decoration: none; + } + } + h2 { + @include standard-font; + font-weight: normal; + font-style: italic; + color: #000; + line-height: 1.1em; + height: 20%; + text-align:left; + } +} + +@mixin toolbar { + border-bottom: 1px solid $light-gray; + width: 100%; + text-align: left; + font-size: 0.8em; + line-height: 1.2em; +} + + +article > header > p.pubdate { + @include toolbar; +} +article > header > p.toolbar { + @include toolbar; + margin-top: 20px; + time { + font-style: italic; + } + .tools { + float: right; + margin-top: -20px; + a { + float: left; + display: block; + margin: 0 2px; + img { + opacity: 0.6; + @include ease-in(opacity); + &:hover { + opacity: 1; + } + } + } + } +} +article > header .author { + text-align: right; + font-size: 0.8em; + float: right; + margin-top: -10px; +} + +article.page > section { + padding-top: 0.5em; + clear: both; +} + +article > section { + clear: right; +} + +article > header > nav.tags { + margin-top: -5px; + padding: 2px 0 3px 0; + text-align: left; + float: left; +} + +article > header > nav.tags > a { + margin: 2px 8px 2px 0px; + font-style: italic; + background-color: #CED1EB; + @include border-radius(3px); + padding: 1px 3px; + @include ease-in(background-color); +} +article > header > nav.tags > a:hover { + background-color: #E0E3FF; +} + + +/* Headers */ + +#main-content > article h1, +article.page > header h1 { + font-size: 2.8em; +} + +#secondary-content > article h1, +#main-content > section > article h1, +#body-text section header h1, +#body-text h2 { + font-size: 2em; +} + +#main-content > article h2, +#secondary-content > section > article h1, +article.page > header h2, +#body-text section section header h1, +#body-text h3 { + font-size: 1.6em; +} + +#main-content > section > article h2, +#body-text section section section header h1, +#body-text h5 { + font-size: 1.3em; +} + +#secondary-content > article h2, +#body-text section section section section header h1, +#body-text h4 { + font-size: 1.4em; +} + +#secondary-content > section > article h2, +#body-text section section section section section header h1, +#body-text h6 { + font-size: 1.1em; +} + +/* Text */ + +article { + font-size: 93%; + header > p { font-size: 90%; } +} + +#body-text { + margin-top: 2.5em; + h1, h2, h3, h4, h5, h6 { + clear: both; + padding-top: 1.5em; + margin-bottom: 0.8em; + border-bottom: 1px solid $light-gray; + width: 100%; + } + img { + margin: 1em; + } + .right, img[style="float:right;"] { + margin: 1em 0 1em 1em; + } + .left, img[style="float:left;"] { + margin: 1em 1em 1em 0; + } + blockquote { + font-style: italic; + color: #8F6B17; + } +} + +article p { + margin: 0.6em 0; +} + +article.feature { + border: 1px solid $light-gray; + padding: 10px; + header p { + margin: 0; + font-weight: bold; + text-align: right; + color: $light-gray; + } + h1, h2 { + text-align: center; + } + h2 { + margin-bottom:10px; + } +} + +/* Lists */ + +#body-text ul, ol { + margin-left: 2em; +} + +ol.toc, ol.toc ol { + list-style-type: none; +} + +dl { + margin: 2em 0; + dt { + margin: 1em 0 0.3em 0; + font-size: 120%; + } + dd { + margin-left: 2em; + } +} + + +/* Tables */ + +#body-text table { + border-collapse: collapse; + @include border-radius(5px); + th { + font-size: 110%; + text-align: center; + font-weight: bold; + background: #fafafa; + } + tr, th, td { + border: 1px solid $light-gray; + } + td { + padding: 5px; + } + +} + +table#timeline, table#taglist { + th, tr, td { + border: none; + } +} + +/* Glyph Book */ + +section.glyph-book > nav { + text-align: center; + margin: 2em auto; + a { + margin: 0 1em; + text-size: 120%; + font-weight: bold; + } +} + +section.glyph-index h1.toc-header { + display: none; +} + +/* TOC */ + +#auto-toc { + #toc-title { + border-bottom: none; + font-size: 1.2em; + font-style: italic; + } + ol { + margin-left: 0; + li { + list-style-type: none; + } + } + float: right; + margin: 1em 0 1.5em 1.5em; + padding: 0.5em; + border: 1px solid $light-gray; +} + +.toc-top-link { + font-weight: normal; +} + +/* Legacy Comments */ + +#legacy-comments { + margin: 0 10px; +} + +.lc-header{ + margin: 20px 0 10px 0; + padding: 3px; + background: #F7F7F7; + color: #333; + line-height: normal; + height: auto; + font-weight: bold; + border: 1px solid rgba(0,0,0,.08); + @include border-radius(3px); +} +.lc-body { + margin: 0 10px; + font-size: 0.93em; +} + +/* Projects */ + +#github { + border: 1px solid $light-gray; + padding: 5px; + margin-left: 5px; + float: right; + width: 400px; + .commit-date { + font-style: italic; + } + a { + font-size: 90%; + font-weight: bold; + } +} + +.project-links { + width: 500px; + border: 1px solid $light-gray; + margin-bottom: 10px; + padding: 0 5px; + text-align: center; + a { + font-weight: bold; + } +} + +/* Contact form */ + +#body-text { + form.fsForm { + width: 400px; + } + table.fsTable, + tr.fsRow, + tr.fsRowTop, + tr.fsSpacerRow, + td.fsRowOpen, + td.fsRowClose, + td.fsRowBody, + td.fsCell { + border: none; + @include standard-font; + } + tr.fsRowTop, tr.fsSpacerRow { + display: none; + } +} + + +/* Classes */ + +.clear-left { + clear: left; +} +.clear-right { + clear: right; +} +.clear { + clear:both; +} + +.img-right { + float: right; + margin: 10px 0 10px 10px; +} +.img-left { + float: right; + margin: 10px 10px 10px 0; +} + +.right { + float: right; +} + +.left { + float: left; +} + +.center { + margin: auto; + text-align: center; +} + +.border-left { + border-left: 1px solid $light-gray; +} +.border-right { + border-right: 1px solid $light-gray; +} + +/* Elements */ + +a { + color: $light-blue; + text-decoration: none; + @include ease-in(color); + outline: none; +} + +a:hover { + color: $dark-blue; + text-decoration: underline; +} + +.toc-top-link { + font-size: 80%; + font-weight: bold; + padding: 3px; +}
@@ -0,0 +1,45 @@
+/* Definitions */ + +$light-gray: #cacaca; +$dark-gray: #333; +$light-blue: #007BC4; +$dark-blue: #005B91; + +@mixin standard-font { + font-family: 'Gentium', 'Palatino', 'Bookman', 'Georgia', 'Times'; + line-height: 1.3em; +} + +@mixin ease-in($property) { + -webkit-transition: $property 0.25s ease-in; + -moz-transition: $property 0.25s ease-in; + -o-transition: $property 0.25s ease-in; + transition: $property 0.25s ease-in; +} + +@mixin border-radius($size) { + -webkit-border-radius: $size; + -moz-border-radius: $size; + border-radius: $size; +} + +@mixin hover-image($width, $height) { + width: $width; + height: $height; + position: relative; + img.hover { opacity: 0; } + &:hover img.hover { opacity: 1; } + img.default { opacity: 1; } + &:hover img.default { opacity: 0; } + img { + width: $width; + height: $height; + left: 0px; + top: 0px; + position: absolute; + -webkit-transition: opacity 0.25s linear; + -moz-transition: opacity 0.25s linear; + -o-transition: opacity 0.25s linear; + transition: opacity 0.25s linear; + } +}
@@ -0,0 +1,29 @@
+#gallery { + padding: 1em; + width: 750px; + ul { + list-style: none; + li { + float: left; + margin-left: 2px; + padding-left: 0; + } + img { + border: 5px solid #dedede; + } + a:hover { + color: white; + img { + border: 5px solid #cccccc ; + color: white; + } + } + a { border-bottom: none; } + } +} +#fancy_content { + a { border-bottom: none; } +} +#fancy_title td, #fancy_title tr, #fancy_title table { + border: none; +}
@@ -0,0 +1,245 @@
+html, body { + height: 100%; } + +div#fancy_overlay { + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + background-color: #666666; + display: none; + z-index: 30; } + +* html div#fancy_overlay { + position: absolute; + height: 580px; } + +div { + &#fancy_wrap { + text-align: left; } + &#fancy_loading { + position: absolute; + height: 40px; + width: 40px; + cursor: pointer; + display: none; + overflow: hidden; + background: transparent; + z-index: 100; + div { + position: absolute; + top: 0; + left: 0; + width: 40px; + height: 480px; + background: transparent url("/images/fancybox/fancy_progress.png") no-repeat; } } + &#fancy_loading_overlay { + position: absolute; + background-color: white; + z-index: 30; } + &#fancy_loading_icon { + position: absolute; + background: url("/images/fancybox/fancy_loading.gif") no-repeat; + z-index: 35; + width: 16px; + height: 16px; } + &#fancy_outer { + position: absolute; + top: 0; + left: 0; + z-index: 90; + padding: 18px 18px 33px 18px; + margin: 0; + overflow: hidden; + background: transparent; + display: none; } + &#fancy_inner { + position: relative; + width: 100%; + height: 100%; + border: 1px solid #bbbbbb; + background: white; } + &#fancy_content { + margin: 0; + z-index: 100; + position: absolute; } + &#fancy_div { + background: black; + color: white; + height: 100%; + width: 100%; + z-index: 100; } } + +img#fancy_img { + position: absolute; + top: 0; + left: 0; + border: 0; + padding: 0; + margin: 0; + z-index: 100; + width: 100%; + height: 100%; } + +div#fancy_close { + position: absolute; + top: -12px; + right: -15px; + height: 30px; + width: 30px; + background: url("/images/fancybox/fancy_closebox.png") top left no-repeat; + cursor: pointer; + z-index: 181; + display: none; } + +#fancy_frame { + position: relative; + width: 100%; + height: 100%; + display: none; } + +#fancy_ajax { + width: 100%; + height: 100%; + overflow: auto; } + +a { + &#fancy_left, &#fancy_right { + position: absolute; + bottom: 0px; + height: 100%; + width: 35%; + cursor: pointer; + z-index: 111; + display: none; + outline: none; } + &#fancy_left { + left: 0px; } + &#fancy_right { + right: 0px; } } + +span { + &.fancy_ico { + position: absolute; + top: 50%; + margin-top: -15px; + width: 30px; + height: 30px; + z-index: 112; + cursor: pointer; + display: block; } + &#fancy_left_ico { + left: -9999px; + background: transparent url("/images/fancybox/fancy_left.png") no-repeat; } + &#fancy_right_ico { + right: -9999px; + background: transparent url("/images/fancybox/fancy_right.png") no-repeat; } } + +a { + &#fancy_left:hover, &#fancy_right:hover { + visibility: visible; } + &#fancy_left:hover span { + left: 20px; } + &#fancy_right:hover span { + right: 20px; } } + +.fancy_bigIframe { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background: transparent; } + +div { + &#fancy_bg { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 70; + border: 0; + padding: 0; + margin: 0; } + &.fancy_bg { + position: absolute; + display: block; + z-index: 70; + border: 0; + padding: 0; + margin: 0; } + &.fancy_bg_n { + top: -18px; + width: 100%; + height: 18px; + background: transparent url("/images/fancybox/fancy_shadow_n.png") repeat-x; } + &.fancy_bg_ne { + top: -18px; + right: -13px; + width: 13px; + height: 18px; + background: transparent url("/images/fancybox/fancy_shadow_ne.png") no-repeat; } + &.fancy_bg_e { + right: -13px; + height: 100%; + width: 13px; + background: transparent url("/images/fancybox/fancy_shadow_e.png") repeat-y; } + &.fancy_bg_se { + bottom: -18px; + right: -13px; + width: 13px; + height: 18px; + background: transparent url("/images/fancybox/fancy_shadow_se.png") no-repeat; } + &.fancy_bg_s { + bottom: -18px; + width: 100%; + height: 18px; + background: transparent url("/images/fancybox/fancy_shadow_s.png") repeat-x; } + &.fancy_bg_sw { + bottom: -18px; + left: -13px; + width: 13px; + height: 18px; + background: transparent url("/images/fancybox/fancy_shadow_sw.png") no-repeat; } + &.fancy_bg_w { + left: -13px; + height: 100%; + width: 13px; + background: transparent url("/images/fancybox/fancy_shadow_w.png") repeat-y; } + &.fancy_bg_nw { + top: -18px; + left: -13px; + width: 13px; + height: 18px; + background: transparent url("/images/fancybox/fancy_shadow_nw.png") no-repeat; } + &#fancy_title { + position: absolute; + bottom: -33px; + left: 0; + width: 100%; + z-index: 100; + display: none; + div { + color: white; + font: bold 12px Arial; + padding-bottom: 3px; } + table { + margin: 0 auto; + td { + padding: 0; + vertical-align: middle; } } } } + +td { + &#fancy_title_left { + height: 32px; + width: 15px; + background: transparent url(/images/fancybox/fancy_title_left.png) repeat-x; } + &#fancy_title_main { + height: 32px; + background: transparent url(/images/fancybox/fancy_title_main.png) repeat-x; } + &#fancy_title_right { + height: 32px; + width: 15px; + background: transparent url(/images/fancybox/fancy_title_right.png) repeat-x; } }
@@ -0,0 +1,27 @@
+/* Fonts */ + +@font-face { + font-family: 'Gentium'; + src: url('../fonts/GenBkBasR.ttf') format('truetype'); + font-weight: normal; + font-style: normal; +} + +@font-face { + font-family: 'Gentium'; + src: url('../fonts/GenBkBasI.ttf') format('truetype'); + font-weight: normal; + font-style: italic; +} +@font-face { + font-family: 'Gentium'; + src: url('../fonts/GenBkBasB.ttf') format('truetype'); + font-weight: bold; + font-style: normal; +} +@font-face { + font-family: 'Gentium'; + src: url('../fonts/GenBkBasBI.ttf') format('truetype'); + font-weight: bold; + font-style: italic; +}
@@ -0,0 +1,228 @@
+/* Layout */ + +body { + @include standard-font; + background: #000; +} + +#container { + width: 960px; + margin: 20px auto; + padding: 5px; + color: $dark-gray; + background: #fff; + @include border-radius(10px); +} + +/* Navigation */ + +#container > nav.home { + display: block; + height: 1.5em; + margin: 1em auto auto auto; + width: 940px; + text-align: center; + font-size: 0.9em; + a { + margin: 0 3px; + } +} + +#container > header { + padding-top: 10px; + margin: auto; + width: 940px; + text-align: center; + &.home { + height: 60px; + border-bottom: 2px solid $dark-blue; + nav.left { + width: 234px; + height: 60px; + margin-top: -6px; + } + nav.right { + width: 234px; + height: 60px; + margin-top: -6px; + } + h1 { + float: left; + margin-left: 110px; + height: 56px; + @include hover-image(251px, 56px); + } + time { + clear: both; + display: block; + font-size: 0.8em; + font-weight: bold; + width: 940px; + text-align: center; + padding-top: 0.5em; + } + form { + float: right; + margin-top: -50px; + } + } + &.page { + height: 42px; + border-bottom: 1px solid $dark-blue; + nav.section { + float: right; + margin-top: 10px; + font-size: 30px; + } + nav.home-link { + float: left; + @include hover-image(179px, 40px); + } + } +} + +#container > footer { + clear: both; + text-align: center; + padding: 10px; + font-size: 0.8em; + a { + margin: 0 3px; + } + section.ads { + height: 90px; + } +} + +#topbar { + margin: auto; + margin-top: 20px; + height: 92px; + text-align: right; + width: 940px; + border: 1px solid $light-gray; +} + +#social { + margin-top: 20px; + float: left; + li { float:left;} + a { + margin: 0 20px; + img { + opacity: 0.6; + vertical-align: middle; + @include ease-in(opacity); + &:hover { + opacity: 1; + } + } + } +} + +#sharing-buttons { + clear:both; + margin: 20px auto; + text-align: center; +} + + + +/* Main */ + +#main-content { + margin: 0.5em 0; + width: 555px; + text-align: justify; + border-right: 1px solid $light-gray; +} + +#main-content { + padding: 0 5px; +} + +#main-content > article { + padding: 0 5px; +} + +#main-content > section { + margin-top: 5px; + padding: 0 5px; +} +#main-content > section.right { +} + +#main-content > section.left { + width: 280px; +} + +#main-content > section.right { + width: 240px; + padding-left: 10px; +} + +/* Secondary */ + +#secondary-content { + padding: 0 5px; + width:380px; + text-align: justify; +} + +#secondary-content > article { + padding: 0 5px; + &.feature { + margin: 0 5px; + } +} + +#secondary-content > section { + margin-top: 5px; + padding: 0 5px; + width: 170px; +} + +#secondary-content > section.left { + padding-right: 10px; +} + +#secondary-content > section.right { +} + +article.page { + padding: 10px; + text-align: justify; +} + + +/* Columns */ + +.three-columns { + -moz-column-count: 3; + -moz-column-gap: 20px; + -webkit-column-count: 3; + -webkit-column-gap: 20px; + column-count: 3; + column-gap: 20px; +} + +.two-columns { + -moz-column-count: 2; + -moz-column-gap: 20px; + -webkit-column-count: 2; + -webkit-column-gap: 20px; + column-count: 2; + column-gap: 20px; +} + +/* Archives */ + +#taglist, #timeline { + margin: 2em auto; + text-align: center; + td { + margin: 10px; + text-align: left; + width: 180px; + } +}
@@ -0,0 +1,93 @@
+/* Twitter */ +.twtr-tweet-text, .twtr-hd, .twtr-join-conv { + @include standard-font; +} + +.twtr-tweet-text { + font-size: 1.2em; +} +.twtr-timestamp, .twtr-reply { + font-size: 1.4em; + font-style: italic; +} + +/* Google Custom Search */ + +#search { + margin: 10px; + padding: 10px; + height: 50px; + border: 1px solid $light-gray; + width: 270px; + float: right; +} + + +.gsc-resultsHeader, .gs-visibleUrl, .gsc-trailing-more-results, .gs-watermark { + display: none; +} + +#search_results { + width: 940px; + clear: both; + text-align: justify; + padding: 10px; +} +.gsc-result { + padding: 0.5em 0; +} + +table.gsc-search-box { + margin: auto; +} + +.gsc-search-box { + border: none; + td { + border: none; + } +} + +.gsc-input { + width: 200px; +} + +.gsc-branding { + color: black; + font-style: italic; + font-size: 70%; + border: none; + margin: auto; + padding: 0; +} + +td.gsc-branding-img { + text-align: left; +} + +.gsc-cursor-page { + display: inline; + padding-right: 7px; + &:hover { + cursor: pointer; + } +} +.gsc-cursor-current-page { + font-weight: bold; + +} + +/* Disqus */ + +#disqus_thread { + margin: 0 10px; + #dsq-content { + font-size: 0.93em; + .dsq-request-user-name small, .dsq-subscribe small, .dsq-sharing-options span small { + font-size: 0.8em; + } + .dsq-comment-body { + margin: 0 10px; + } + } +}
@@ -0,0 +1,102 @@
+/* +html5doctor.com Reset Stylesheet +v1.6 +Last Updated: 2010-08-18 +Author: Richard Clark - http://richclarkdesign.com +Twitter: @rich_clark +*/ + +html, body, div, span, object, iframe, +h1, h2, h3, h4, h5, h6, p, blockquote, pre, +abbr, address, cite, code, +del, dfn, em, img, ins, kbd, q, samp, +small, strong, sub, sup, var, +b, i, +dl, dt, dd, ol, ul, li, +fieldset, form, label, legend, +table, caption, tbody, tfoot, thead, tr, th, td, +article, aside, canvas, details, figcaption, figure, +footer, header, hgroup, menu, nav, section, summary, +time, mark, audio, video { + margin:0; + padding:0; + border:0; + outline:0; + font-size:100%; + vertical-align:baseline; + background:transparent; +} + +body { + line-height:1; +} + +article,aside,details,figcaption,figure, +footer,header,hgroup,menu,nav,section { + display:block; +} + +nav ul { + list-style:none; +} + +blockquote, q { + quotes:none; +} + +blockquote:before, blockquote:after, +q:before, q:after { + content:''; + content:none; +} + +a { + margin:0; + padding:0; + font-size:100%; + vertical-align:baseline; + background:transparent; +} + +/* change colours to suit your needs */ +ins { + background-color:#ff9; + color:#000; + text-decoration:none; +} + +/* change colours to suit your needs */ +mark { + background-color:#ff9; + color:#000; + font-style:italic; + font-weight:bold; +} + +del { + text-decoration: line-through; +} + +abbr[title], dfn[title] { + border-bottom:1px dotted inherit; + cursor:help; +} + +table { + border-collapse:collapse; + border-spacing:0; +} + +/* change border colour to suit your needs */ +hr { + display:block; + height:1px; + border:0; + border-top:1px solid #cccccc; + margin:1em 0; + padding:0; +} + +input, select { + vertical-align:middle; +}
@@ -0,0 +1,8 @@
+@import "_definitions.scss"; +@import "_fonts.scss"; +@import "_layout.scss"; +@import "_content.scss"; +@import "_fancybox.scss"; +@import "_fancybox-gallery.scss"; +@import "_vendor.scss"; +@import "_code.scss";
@@ -1,30 +0,0 @@
------ -filter: erb ------ -<script type="text/javascript"> - var dzone_url = "<%= url_for @item %>"; - var dzone_title = "<%= @item[:title]%>"; - var dzone_blurb = "<%= @item[:summary] if @item[:summary] %>"; - var dzone_style = '2'; - var digg_url = "<%= url_for @item %>"; - var digg_skin = 'compact'; - var digg_window = 'new'; - var tweetmeme_style = 'compact'; - function delicious_counter(data) { - var posts = data[0].total_posts; - if (!posts) return; - var text = posts+" bookmarks"; - if (posts == 1) { text = posts+" bookmark" }; - document.getElementById('delcounter').innerHTML = text; - } -</script> -<ul class="article-buttons"> - <li><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js"></script></li> - <li><script type="text/javascript" src="http://www.reddit.com/button.js?t=1"></script></li> - <li><script type="text/javascript" src="http://widgets.dzone.com/links/widgets/zoneit.js"></script> </li> - <li><script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script></li> - <li><a href="http://www.stumbleupon.com/submit?url=<%= url_for @item %>"> <img border=0 src="http://cdn.stumble-upon.com/images/120x20_su_gray.gif" alt=""></a></li> - <li> - <span id="delcounter">0 bookmarks</span><img src="http://static.delicious.com/img/delicious.small.gif" /><a href="http://delicious.com/post?url=<%= url_for @item %>&title=<%= @item[:title]%>">Save</a> - </li> -</ul>
@@ -0,0 +1,21 @@
+----- +filter: erb +----- +<% + author = @item[:author] || "Fabio Cevasco" + intro = @extended ? @item[:intro].to_s+"\n\n"+@item[:extended_intro].to_s : @item[:intro] +%><article id="a_<%= @item[:permalink] %>"> + <header> + <h1><a href="<%= @item.identifier %>"><%= @item[:title]%></a></h1> + <% unless @item[:subtitle].blank? then %> + <h2><%= @item[:subtitle] %></h2> + <% end %> + <p class="pubdate"><time datetime="<%= @item[:date].strftime("%Y-%d-%d") %>" pubdate="pubdate"><%= @item[:date].strftime("%A, %B %d %Y") %></time></p> + <p class="author">By <em><%= author %></em></p> + </header> + <section class="<%= @classes %>"> + <%= RedCloth.new(intro.to_s).to_html %> + <p><a class="more" href="<%= @item.identifier%>">» <strong>Read More</strong></a></p> + </section> +</article> +
@@ -1,9 +0,0 @@
------ -filter: erb ------ -<div class="article-item"> - <h4><a href="/articles/<%= @article.attributes[:permalink]%>/"><%= @article.attributes[:title]%></a></h4><% unless (@article.attributes[:tags].empty?) then %> - <%= render 'article_meta', :article => @article %> - <% end %><% if (@article.attributes[:summary] && !@no_summary) then %><div class="article-summary"><%= @article.attributes[:summary] %> - </div><% end %> -</div>
@@ -1,7 +0,0 @@
------ -filter: erb ------ -<ul class="article-meta"> - <li>Composed on <span class="date"><%= @article.attributes[:date].strftime("%A, %d %B %Y") %></span></li> - <li>Archived in <%= tags_for(@article) %></li> -</ul>
@@ -1,16 +1,15 @@
----- filter: erb ----- -<div id="comments"> - <%= render 'legacy_comments' if @item[:comments] && @item[:comments].length > 0 %> -<script> -var idcomments_acct = '7a8e41c4b06641909304090b010e8009'; -var idcomments_post_id; -var idcomments_post_url; -</script> -<span id="IDCommentsPostTitle" style="display:none"></span> -<div id="intensedebate"> - <script type='text/javascript' src='http://www.intensedebate.com/js/genericCommentWrapperV2.js'></script> -</div> -</div> +<section id="disqus_thread"></section> + <script type="text/javascript"> + var disqus_identifier = "<% @item[:permalink]%>"; + var disqus_developer = true; + (function() { + var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; + dsq.src = 'http://h3rald.disqus.com/embed.js'; + (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); + })(); + </script> + <noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript=h3rald">comments powered by Disqus.</a></noscript>
@@ -1,19 +1,19 @@
----- filter: erb ----- -<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> +<!DOCTYPE html> +<html lang="en"> <head> <title><%= @item[:title] %> - H3RALD</title> <% if @item[:feed_url] then %> - <link rel="alternate" type="application/rss+xml" title="H3RALD - <%= @item[:feed_title]%>" href="<%= @item[:feed_url]%>" /> + <link rel="alternate" type="application/rss+xml" title="H3RALD - <%= @item[:feed_title]%>" href="<%= @item[:feed_url]%>" /> <% else %> - <% if @item[:feed] then %> - <link rel="alternate" type="application/rss+xml" title="H3RALD - <%= @item[:feed_title]%>" href="<%= @item[:feed]%>rss/" /> - <link rel="alternate" type="application/atom+xml" title="H3RALD - <%= @item[:feed_title]%>" href="<%= @item[:feed]%>atom/" /> - <% end %> + <% if @item[:feed] then %> + <link rel="alternate" type="application/rss+xml" title="H3RALD - <%= @item[:feed_title]%>" href="<%= @item[:feed]%>rss/" /> + <link rel="alternate" type="application/atom+xml" title="H3RALD - <%= @item[:feed_title]%>" href="<%= @item[:feed]%>atom/" /> + <% end %> <% end %> + <meta charset="utf-8" /> <meta name="author" content="Fabio Cevasco" /> <meta name="copyright" content="Fabio Cevasco" /> <meta name="robots" content="all, follow" />@@ -23,179 +23,131 @@ <meta name="target_country" content="en-us" />
<meta name="country" content="United States" /> <meta name="description" content="H3RALD - Fabio Cevasco's Web Site" /> <% - min_keywords = "h3rald, fabio cevasco, " - default = "ruby, rails technical writing, reviews, software, browsers, articles, traveling, books, genova" - case @item[:type] - when 'article' then - keywords = min_keywords+@item[:tags].join(', ') - when 'project' then - keywords = @item[:permalink] == 'h3rald' ? "fabio cevasco, "+@item[:permalink] : min_keywords+@item[:permalink] - else - keywords = min_keywords+default - end + min_keywords = "h3rald, fabio cevasco, " + default = "ruby, rails technical writing, reviews, software, browsers, articles, traveling, books, genova" + case @item[:type] + when 'article' then + keywords = min_keywords+@item[:tags].join(', ') + when 'project' then + keywords = @item[:permalink] == 'h3rald' ? "fabio cevasco, "+@item[:permalink] : min_keywords+@item[:permalink] + else + keywords = min_keywords+default + end %> <meta name="keywords" content="<%= keywords %>" /> - <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" /> - <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> + <link rel="shortcut icon" href="/favicon.png" type="image/png" /> <meta content="44.388041;9.073248" name="ICBM" /> - <link href="/css/main.css" media="all" rel="stylesheet" type="text/css" /> + <link rel="stylesheet" type="text/css" href="/styles/html5reset.css" /> + <link rel="stylesheet" type="text/css" href="/styles/style.css" /> + + <!--[if lte IE 8]> + <script src="/js/html5.js" type="text/javascript"></script> + <![endif]--> </head> <body> - <div id="wrapper"> - <a href="http://github.com/h3rald/h3rald"><img style="position: absolute; top: 0; right: 0; border: 0;" src="http://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub" /></a> - <div id="header"> - <!--[if lte IE 6]> - <div id="ie-warning"> - This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More...</a>] - </div> - <![endif]--> - <!-- HEADER START --> - <div id="header-container"> - <div id="header-left"> - <h1><span class="logo"></span><a id="logo" href="/" title="H3RALD"></a></h1> - </div> - <div id="header-right"> - <ul id="navigation"> - <% ['archives', 'projects', 'about', 'other'].each do |l| %> - <li><span class="preload nav-<%= l%>"></span><a id="nav-<%= l%>" href="/<%= l %>/" title="<%= l.upcase %>"></a></li> - <% end %> - </ul> - </div> - </div> - </div> - <!-- HEADER END --> - <div class="ribbon"> - </div> - <!-- MAIN START --> - <div id="main"> - <!-- CONTAINER START --> - <div id="container"> - <!-- CONTENT START --> - <div id="content" class="clearfix<%= (@item[:permalink] == 'home') ? ' home' : ' standard' %>"> -<div id="page-links"> - <span><script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=6e34d60c-b14e-4c19-9b2f-7c35a9f0ab09&type=website&linkfg=%23a4282d"></script></span> - <% if @item[:feed] then %> - <span><a href="<%= @item[:feed_url] || @item[:feed]+"rss/" %>" type="application/rss+xml" rel="alternate"><img src="/images/theme/feed.png" alt="#"/>RSS Feed</a></span> - <% end %> - <% if @item[:pdf] then %> - <span><a href="<%= @item.identifier.chop %>.pdf" ><img src="/images/theme/pdf.png" alt="#"/>Download PDF</a></span> - <% end %> - <span><a href="http://github.com/h3rald/h3rald/raw/master/<%= @item[:file].path %>?iframe" class="fancybox"><img src="/images/theme/source.png" alt="#"/>View Source</a></span> - </div> + <!--[if lte IE 6]> + <div id="ie-warning"> + This site is not compatible with Internet Explorer 6 or lower. You should consider using a more modern browser for a better – and <em>safer</em> – web experience. [<a href="http://browsehappy.com/browsers/">Read More »</a>] + </div> + <![endif]--> - <h2><%= @item[:title] %></h2> - <% case @item[:type] - when 'article' then%> - <div id="content-header"> - <%= render 'article_meta', :article => @item %> - </div> - <% end %> - <hr /> - <div id="content-body"> - <% if @item[:toc] then %> - <div id="toc"> - <span id="toctitle">Table of Contents</span> - <ol></ol> - </div> - <% end %> - <%= yield %> - </div> - <div id="content-footer"> - <div class="share"> - <script type="text/javascript"><!-- -google_ad_client = "pub-2871497824158668"; -/* 728x90, h3rald 8.0 */ -google_ad_slot = "0081634732"; -google_ad_width = 728; -google_ad_height = 90; -//--> - </script> - <script type="text/javascript" -src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> - </script> - </div> - <%= render 'article_buttons' if @item[:type] == 'article' %> - </div> - </div> - <!-- CONTENT END --> - </div> - <!-- CONTAINER END --> - </div> - <div class="ribbon"></div> - <!-- MAIN END --> - <div id="border-bottom"> - <% if @item[:type] == 'article' then %> - <%= render 'comments' %> - <% else %> - <%= render 'services' %> + <section id="container"> + <% if @item[:permalink] == 'home' then %> + <%= render 'home_header' %> + <%= yield %> + <%= render 'buttons', :item => @item %> + <% else %> + <%= render 'page_header', :item => @item %> + <article class="page"> + <%= render 'page_meta', :item => @item %> + <section id="body-text" class="hyphenate"> + <% if @item[:toc] then %> + <aside id="auto-toc"> + <span id="toc-title">Table of Contents</span> + <ol></ol> + </aside> + <% end %> + <%= yield %> + <%= render 'buttons', :item => @item %> + </section> + </article> + <% if @item[:type] == 'article' %> + <%= render 'legacy_comments', :item => @item if @item[:comments] %> + <%= render 'comments', :item => @item %> <% end %> - </div> - <div class="clearfooter"></div> - </div> <!-- WRAPPER END --> - <div id="footer"> - <div id="footer-container"> - <div class="footer-div"> - H3RALD Web Site v8.0.0 <em>"xStatic"</em> — © 2004-<%= Time.new.strftime("%Y") %> <strong>Fabio Cevasco</strong> — <a class="link" href="http://creativecommons.org/licenses/by-nc-nd/3.0/us/">Some rights reserved</a> | <a href="http://validator.w3.org/check?uri=referer" class="link">XHTML 1.1</a> | <a href="http://jigsaw.w3.org/css-validator/validator?uri=<%= url_for @item %>" class="link">CSS 2.1</a> - </div> - </div> <!-- END FOOTER CONTAINER--> - </div> <!-- END FOOTER --> - <!-- Start Google Analytics --> + <% end %> + <footer> + <section class="ads"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 728x90, created 9/10/10 */ + google_ad_slot = "3963343166"; + google_ad_width = 728; + google_ad_height = 90; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </section> + <section> + <nav> + <a href="/about/">ABOUT</a>|<a href="/contact/">CONTACT</a> + </nav> + <p>H3RALD Web Site v8.1 — © 2010 — <em>Fabio Cevasco</em></p> + </section> + </footer> + </section><!-- #container end --> + <script src="http://www.google.com/jsapi?key=ABQIAAAAr6RY1Z6dchG_sX9WDLSy3xRlq2n1sm52B5HDRR5tm6o8XM18FhR56xHNNH6CsX86uN5VoTrglpyOyQ" type="text/javascript"></script> + <!-- <script src="/js/jquery.js" type="text/javascript"></script> --> + <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> + <script src="/js/jquery-timeago.js" type="text/javascript"></script> + <script src="/js/jquery-easing.js" type="text/javascript"></script> + <script src="/js/jquery-fancybox.js" type="text/javascript"></script> + <script src="/js/jquery-toc.js" type="text/javascript"></script> + <script src="/js/date.js" type="text/javascript"></script> + <script src="/js/feeds.js" type="text/javascript"></script> + <script src="/js/search.js" type="text/javascript"></script> + <script src="/js/hyphenator.min.js" type="text/javascript"></script> + <script src="/js/init.js" type="text/javascript"></script> + <% if @item[:type] == 'article' %> <script type="text/javascript"> - - var _gaq = _gaq || []; - _gaq.push(['_setAccount', 'UA-287139-1']); - _gaq.push(['_trackPageview']); - - (function() { - var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; - ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; - var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); - })(); - - </script> - <!-- End Google Analytics --> - <!-- Start of StatCounter Code --> - <script type="text/javascript"> - var sc_project=6193656; - var sc_invisible=1; - var sc_security="57f7ee2a"; - </script> - <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> - <!-- End of StatCounter Code --> - <script src="http://www.google.com/jsapi?key=ABQIAAAA6h3j8Jri5D_da53UPbEbThRlq2n1sm52B5HDRR5tm6o8XM18FhTKn3v155RpPeD0kWnWG81QEhhifQ" type="text/javascript"></script> - <% if @site.config[:dev] = true then %> - <script src="/js/jquery.js" type="text/javascript"></script> - <script src="/js/jquery-timeago.js" type="text/javascript"></script> - <script src="/js/jquery-easing.js" type="text/javascript"></script> - <script src="/js/jquery-fancybox.js" type="text/javascript"></script> - <script src="/js/jquery-toc.js" type="text/javascript"></script> - <script src="/js/date.js" type="text/javascript"></script> - <script src="/js/feeds.js" type="text/javascript"></script> - <script src="/js/search.js" type="text/javascript"></script> - <script src="/js/init.js" type="text/javascript"></script> - <% else %> - <script src="/js/compressed.js" type="text/javascript"></script> - <% end %> - <% if @item[:type] != 'article' then %> - <script type="text/javascript"> - $(document).ready(function() { - display_opinions(7); - display_tweets(7); - display_bookmarks(7); - }); -</script> - <% end %> - <% if @item[:type] == 'article' then %> - <script src="http://badges.del.icio.us/feeds/json/url/data?url=<%= url_for @item %>&callback=delicious_counter"></script> - <% end %> - <% if @item[:github] then %> - <script type="text/javascript"> +var disqus_shortname = 'h3rald'; +(function () { + var s = document.createElement('script'); s.async = true; + s.src = 'http://disqus.com/forums/h3rald/count.js'; + (document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s); +}()); + </script> + <% end %> + <% if @item[:github] then %> + <script type="text/javascript"> $(document).ready(function() { display_commits(5, '<%= @item[:github] %>'); }); -</script> - <% end %> - </body> - </html> + </script> + <% end %> + <!-- Start Google Analytics --> + <script type="text/javascript"> + var _gaq = _gaq || []; + _gaq.push(['_setAccount', 'UA-18587377-1']); + _gaq.push(['_trackPageview']); + + (function() { + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); + })(); + </script> + <!-- End Google Analytics --> + <!-- Start of StatCounter Code --> + <script type="text/javascript"> + var sc_project=6193656; + var sc_invisible=1; + var sc_security="57f7ee2a"; + </script> + <script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js"></script> + <!-- End of StatCounter Code --> +</body> +</html>
@@ -0,0 +1,43 @@
+----- +filter: erb +----- +<nav class="home"> +<%= ['projects', 'links'].map{|l| %{<a href="/#{l}/"><strong>#{l.upcase}</strong></a>} }.join("|") + "|" + +['review', 'ruby', 'opensource', 'productivity', 'writing', 'software'].map{|l| %{<a href="/tags/#{l}/" rel="tag">#{l.upcase}</a>} }.join("|") + +%{|<a href="/archives/" rel="archives">» <strong>MORE</strong></a> } %> +</nav> +<header class="home"> + <nav class="left"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 234x60, created 9/5/10 */ + google_ad_slot = "5027018393"; + google_ad_width = 234; + google_ad_height = 60; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </nav> + <h1> + <a href="/"> + <img src="/images/h3rald.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </h1> + <nav class="right"> + <script type="text/javascript"><!-- + google_ad_client = "pub-2871497824158668"; + /* 234x60, created 9/10/10 */ + google_ad_slot = "7316796658"; + google_ad_width = 234; + google_ad_height = 60; + //--> + </script> + <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> + </script> + </nav> + <time></time> +</header>
@@ -5,10 +5,10 @@ -----
<div id="legacy-comments"> <h3>Legacy Comments</h3> <p> - <em>These comments were imported automatically from an old version of this web site. Scroll <a href="#idc-container-parent">down</a> for the newest stuff.</em> + <em>These comments were imported automatically from an old version of this web site. Scroll <a href="#dsq-content">down</a> for the newest stuff.</em> </p> <% @item[:comments].each do |c| %> - <div id="comment-<%=c[:id]%>" class="legacy-comment"> + <div id="comment-<%=c[:id]%>" class="legacy-comment "> <div class="lc-header"><%= (c[:url].empty?) ? c[:author] : %{<a href="#{c[:url]}">#{c[:author]}</a>} %></div> <div class="lc-body"> <%= RedCloth.new(c[:body]).to_html %>
@@ -0,0 +1,31 @@
+----- +filter: erb +----- +<% +link = nil +case +when @item[:section] then + section = @item[:section] + link = link_for_tag @item[:section].upcase, "/tags/" +when !@item[:tags].blank? then + link = link_for_tag @item[:tags][0].upcase, "/tags/" +when @item[:type] == 'project' then + link = %{<a href="/projects/" rel="archives">PROJECTS</a>} +else + link = %{<a href="/archives/" rel="archives">ARCHIVES</a>} +end +%><header class="page"> + <nav class="home-link"> + <a href="/"> + <img src="/images/h3rald_small.png" alt="H3RALD" class="default"/> + <![if !IE]> + <img src="/images/h3rald_hover_small.png" alt="H3RALD" class="hover"/> + <![endif]> + </a> + </nav> + <% if link then %> + <nav class="section"> + /<%= link %> + </nav> + <% end %> +</header>
@@ -0,0 +1,27 @@
+----- +filter: erb +----- +<% + author = @item[:author] || "Fabio Cevasco" + pdf = %{<a href="/articles/#{@item[:permalink]}.pdf"><img src="/images/icons/pdf.png" alt="PDF" /></a>} if @item[:pdf] + source_url = "http://github.com/h3rald/h3rald/raw/master/#{@item[:file].path}?iframe" + source = %{<a href="#{source_url}" class="fancybox"><img src="/images/icons/ruby.png" alt="SOURCE"/></a>} + tools = %{<span class="tools">#{source}#{pdf}</span>} +%><header> + <hgroup> + <h1><%= @item[:title] %></h1> + <% if !@item[:subtitle].blank? then %> + <h2><%= @item[:subtitle] %></h2> + <% end %> + </hgroup> + <% if @item[:type] == 'article' then %> + <p class="toolbar"> + <span class="pubdate"> + Published on <time datetime="<%= @item[:date].strftime("%Y-%d-%d") %>" pubdate="pubdate"><%= @item[:date].strftime("%A, %B %d %Y") %></time> + </span> + <%= tools if pdf %> + </p> + <nav class="tags"><%= tags_for(@item) %></nav> + <p class="author">By <em><%= author %></em></p> + <% end %> +</header>
@@ -1,5 +1,13 @@
----- filter: erb ----- -<div class="project-data right-column" >Project Status: <strong><%= @item.attributes[:status] %></strong><div class="project-version">Version: <strong><%= @item.attributes[:version]%></strong></div><div class="project-links">Links: <%= @item.attributes[:links].map{ |l| res=nil; l.each_pair{ |label, value| res = %{<a href="#{value}">#{label}</a>}}; res }.join(" · ") %></div><div id="github">Recent Activity:</div> -</div> +<div id="github"><strong>Recent Activity</strong></div> +<nav class="project-links"> + <%= @item.attributes[:links].map{ |l| + res=nil; l.each_pair{ |label, value| res = %{<a href="#{value}">#{label.to_s.upcase}</a>}}; res + }.join(" | ") %> +</nav> +<ul class="project-data"> + <li>Project Status: <strong><%= @item.attributes[:status] %></strong></li> + <li>Version: <strong><%= @item.attributes[:version]%></strong></li> +</ul>
@@ -1,21 +0,0 @@
------ -filter: erb ------ -<div id="services"> - <div class ="footer-left"> - <div id="backtype"> - <h3><span class="s-opinions preload"></span><a id="s-opinions" href="http://www.backtype.com/h3rald" title="Opinions"></a></h3> - </div> - </div> - <div class ="footer-center"> - <div id="twitter"> - <h3><span class="s-tweets preload"></span><a id="s-tweets" href="http://www.twitter.com/h3rald" title="Tweets"></a></h3> - </div> - </div> - <div class ="footer-right"> - <div id="delicious"> - <h3><span class="s-bookmarks preload"></span><a id="s-bookmarks" href="http://www.delicious.com/h3rald" title="Bookmarks"></a></h3> - </div> - </div> -</div> <!-- SERVICES END --> -
@@ -1,87 +0,0 @@
-## -# Wrapper for the Pygments command line tool, pygmentize. -# -# Pygments: http://pygments.org/ -# -# Assumes pygmentize is in the path. If not, set its location -# with Albino.bin = '/path/to/pygmentize' -# -# Use like so: -# -# @syntaxer = Albino.new('/some/file.rb', :ruby) -# puts @syntaxer.colorize -# -# This'll print out an HTMLized, Ruby-highlighted version -# of '/some/file.rb'. -# -# To use another formatter, pass it as the third argument: -# -# @syntaxer = Albino.new('/some/file.rb', :ruby, :bbcode) -# puts @syntaxer.colorize -# -# You can also use the #colorize class method: -# -# puts Albino.colorize('/some/file.rb', :ruby) -# -# Another also: you get a #to_s, for somewhat nicer use in Rails views. -# -# ... helper file ... -# def highlight(text) -# Albino.new(text, :ruby) -# end -# -# ... view file ... -# <%= highlight text %> -# -# The default lexer is 'text'. You need to specify a lexer yourself; -# because we are using STDIN there is no auto-detect. -# -# To see all lexers and formatters available, run `pygmentize -L`. -# -# Chris Wanstrath // chris@ozmm.org -# GitHub // http://github.com -# -require 'rubygems' -require 'open3' -require 'win32/open3' if RUBY_PLATFORM.match /win32/ - -class Albino - @@bin = 'pygmentize' - - def self.bin=(path) - @@bin = path - end - - def self.colorize(*args) - new(*args).colorize - end - - def initialize(target, lexer = :text, format = :html) - @target = File.exists?(target) ? File.read(target) : target rescue target - @options = { :l => lexer, :f => format, :O => 'encoding=utf-8' } - end - - def execute(command) - output = '' - Open3.popen3(command) do |stdin, stdout, stderr| - stdin.puts @target - stdin.close - output = stdout.read.strip - [stdout, stderr].each { |io| io.close } - end - output - end - - def colorize(options = {}) - html = execute(@@bin + convert_options(options)) - # Work around an RDiscount bug: http://gist.github.com/97682 - html.to_s.sub(%r{</pre></div>\Z}, "</pre>\n</div>") - end - alias_method :to_s, :colorize - - def convert_options(options = {}) - @options.merge(options).inject('') do |string, (flag, value)| - string + " -#{flag} #{value}" - end - end -end
@@ -1,4 +1,5 @@
-rw:[h3rald_article| +&:[G|Glyph] +rw:[h3rald.article| article[ @pubdate[$[document.date]] @head[@@ -19,7 +20,7 @@ }
</style> ] @pre-title[ - =>[http://www.h3rald.com/archives/|image[@width[25%]@height[25%]$[site.root]/images/theme/h3rald.svg]] + =>[http://www.h3rald.com/archives/|image[@width[25%]@height[25%]$[site.root]/images/logo.svg]] ] @post-title[ div[em[Originally published on =>[http://www.h3rald.com{{identifier}}|H3RALD.com]]]
@@ -0,0 +1,45 @@
+class Nanoc3::RuleContext + + require 'glyph' + + def glyph_config(item) + Glyph['document.intro'] = RedCloth.new("#{item[:intro]}\n\n#{item[:extended_intro]}").to_html + Glyph['document.date'] = item[:date].strftime "%A, %d %B %Y" + Glyph['document.title'] = item[:title] + Glyph['document.subtitle'] = item[:subtitle] + Glyph['document.author'] = "Fabio Cevasco" + Glyph['site.root'] = "" + Glyph.filter Glyph.file_load("#{Dir.pwd}/lib/data.glyph") + end + + def glyph_pdf_for(item) + Glyph['output.pdf.generator'] = "prince" + Glyph['document.output'] = 'pdf' + Glyph['site.root'] = ".." + f = Pathname.new "#{Dir.pwd}/output#{item.identifier.gsub(/\/$/, '')}.glyph" + f.parent.mkpath + doc = %{ + h3rald.article[ + @identifier[#{item.identifier}] + @content[section[#{item.raw_content}]] + ] + } + # Write the new raw file using Glyph's file_write method + Glyph.file_write f, doc + # Now compile the PDF (works if Prince is installed) + Glyph.compile f.to_s + begin + f.unlink + Pathname.new(f.to_s.gsub(/\.glyph$/, '.html')).unlink + rescue + end + end + + def glyph_article_for(item) + Glyph['document.output'] = 'html5' + filter :glyph + layout 'default' + Glyph.reset + end + +end
@@ -18,11 +18,11 @@ ts
end def tags_for(article) - article.attributes[:tags].map{|t| %{<a class="tag" href="/tags/#{t}/">#{t}</a>}}.join " · " + article.attributes[:tags].map{|t| %{<a class="tag" href="/tags/#{t}/">#{t}</a>}}.join end def link_for_tag(tag, base_url) - %[<a href="#{base_url}#{tag}/" rel="tag">#{tag}</a>] + %[<a href="#{base_url}#{tag.downcase}/" rel="tag">#{tag}</a>] end def tag_link_with_count(tag, count)@@ -30,7 +30,7 @@ %{#{link_for_tag(tag, '/tags/')} (#{count})}
end def sorted_site_tags - site_tags.sort{|a, b| a[1] <=> b[1]}.reverse + site_tags.sort{|a, b| a[0] <=> b[0]} end def articles_tagged_with(tag)@@ -151,6 +151,10 @@ def popular_articles(max=nil)
total = @site.items.select{|p| p.attributes[:date] && p.attributes[:type] == 'article' && p.attributes[:popular]}.sort{|a, b| a.attributes[:date] <=> b.attributes[:date]}.reverse max ||= total.length total[0..max-1] + end + + def by_permalink(articles, permalink) + articles.select{|a| a[:permalink] == permalink}[0] rescue nil end def articles_by_month
@@ -1,18 +1,15 @@
- # Monkey patch Nanoc::Helpers::Filtering +require 'coderay' module Nanoc3::Helpers::Filtering def highlight(syntax, &block) - # Seamlessly ripped off from the filter method... - # Capture block data = capture(&block) # Reconvert <% %> data.gsub! /<%/, '<%' data.gsub! /%>/, '%>' - # Filter captured data - filtered_data = "\n<notextile>"+Albino.colorize(data, syntax)+"</notextile>\n" rescue data - # Append filtered data to buffer + filtered_data = CodeRay.scan(data.strip, syntax).div(:line_numbers => :inline, :tab_width => 2, :css =>:class) + filtered_data = "<notextile>\n"+filtered_data+"\n</notextile>" buffer = eval('_erbout', block.binding) buffer << filtered_data end
@@ -99,12 +99,16 @@ raise RuntimeError, "Name not specified" unless args[:name]
raise RuntimeError, "Article name can only contain letters, numbers and dashes" unless args[:name].match /^[a-zA-Z0-9-]+$/ meta = {} meta[:permalink] = args[:name] - meta[:title] = "" - meta[:tags] = [] + meta[:title] = nil + meta[:subtitle] = nil + meta[:type] = 'article' + meta[:intro] = nil + meta[:extended_intro] = nil + meta[:tags] = nil meta[:date] = Time.now meta[:toc] = true - meta[:type] = 'article' - file = Pathname.new Dir.pwd/"content/articles/#{meta[:permalink]}.textile" + meta[:pdf] = true + file = Pathname.new Dir.pwd/"content/articles/#{meta[:permalink]}.glyph" raise "File '#{file}' already exists!" if file.exist? write_item file, meta, '' end@@ -131,8 +135,8 @@ meta[:github] = args[:name]
meta[:status] = "Active" meta[:version] = "0.1.0" meta[:type] = 'project' - meta[:links] = [{"Documentation" => "http://#{args[:name]}.rubyforge.org"}, - {"Download" => "http://rubyforge.org/projects/#{args[:name]}"}, + meta[:links] = [{"Documentation" => "http://rubydoc.info/gems/#{args[:name]}/#{meta[:version]}/frames"}, + {"Download" => "https://rubygems.org/gems/#{args[:name]}"}, {"Source" => "http://github.com/h3rald/#{args[:name]}/tree/master"}, {"Tracking" => "http://github.com/h3rald/#{args[:name]}/issues"}] contents = %{