Return-Path: X-Original-To: apmail-pdfbox-commits-archive@www.apache.org Delivered-To: apmail-pdfbox-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 22636100E6 for ; Tue, 7 May 2013 19:47:25 +0000 (UTC) Received: (qmail 48066 invoked by uid 500); 7 May 2013 19:47:25 -0000 Delivered-To: apmail-pdfbox-commits-archive@pdfbox.apache.org Received: (qmail 48048 invoked by uid 500); 7 May 2013 19:47:25 -0000 Mailing-List: contact commits-help@pdfbox.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@pdfbox.apache.org Delivered-To: mailing list commits@pdfbox.apache.org Received: (qmail 48041 invoked by uid 99); 7 May 2013 19:47:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 May 2013 19:47:25 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,WEIRD_QUOTING X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 May 2013 19:47:20 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id E4C412388B43 for ; Tue, 7 May 2013 19:46:17 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: svn commit: r861229 [16/19] - in /websites/staging/pdfbox/trunk/content: ./ FontAwesome/ FontAwesome/css/ FontAwesome/docs/ FontAwesome/docs/assets/ FontAwesome/docs/assets/css/ FontAwesome/docs/assets/font/ FontAwesome/docs/assets/ico/ FontAwesome/doc... Date: Tue, 07 May 2013 19:46:01 -0000 To: commits@pdfbox.apache.org From: buildbot@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130507194617.E4C412388B43@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Added: websites/staging/pdfbox/trunk/content/bootstrap/js/bootstrap.min.js ============================================================================== --- websites/staging/pdfbox/trunk/content/bootstrap/js/bootstrap.min.js (added) +++ websites/staging/pdfbox/trunk/content/bootstrap/js/bootstrap.min.js Tue May 7 19:45:58 2013 @@ -0,0 +1,6 @@ +/*! +* Bootstrap.js by @fat & @mdo +* Copyright 2012 Twitter, Inc. +* http://www.apache.org/licenses/LICENSE-2.0.txt +*/ +!function(e){"use strict";e(function(){e.support.transition=function(){var e=function(){var e=document.createElement("bootstrap"),t={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},n;for(n in t)if(e.style[n]!==undefined)return t[n]}();return e&&{end:e}}()})}(window.jQuery),!function(e){"use strict";var t='[data-dismiss="alert"]',n=function(n){e(n).on("click",t,this.close)};n.prototype.close=function(t){function s(){i.trigger("closed").remove()}var n=e(this),r=n.attr("data-target"),i;r||(r=n.attr("href"),r=r&&r.replace(/.*(?=#[^\s]*$)/,"")),i=e(r),t&&t.preventDefault(),i.length||(i=n.hasClass("alert")?n:n.parent()),i.trigger(t=e.Event("close"));if(t.isDefaultPrevented())return;i.removeClass("in"),e.support.transition&&i.hasClass("fade")?i.on(e.support.transition.end,s):s()};var r=e.fn.alert;e.fn.alert=function(t){return this.each(function(){var r=e(this),i=r.data("alert");i||r.data("a lert",i=new n(this)),typeof t=="string"&&i[t].call(r)})},e.fn.alert.Constructor=n,e.fn.alert.noConflict=function(){return e.fn.alert=r,this},e(document).on("click.alert.data-api",t,n.prototype.close)}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.options=e.extend({},e.fn.button.defaults,n)};t.prototype.setState=function(e){var t="disabled",n=this.$element,r=n.data(),i=n.is("input")?"val":"html";e+="Text",r.resetText||n.data("resetText",n[i]()),n[i](r[e]||this.options[e]),setTimeout(function(){e=="loadingText"?n.addClass(t).attr(t,t):n.removeClass(t).removeAttr(t)},0)},t.prototype.toggle=function(){var e=this.$element.closest('[data-toggle="buttons-radio"]');e&&e.find(".active").removeClass("active"),this.$element.toggleClass("active")};var n=e.fn.button;e.fn.button=function(n){return this.each(function(){var r=e(this),i=r.data("button"),s=typeof n=="object"&&n;i||r.data("button",i=new t(this,s)),n=="toggle"?i.toggle():n&&i.setState(n)}) },e.fn.button.defaults={loadingText:"loading..."},e.fn.button.Constructor=t,e.fn.button.noConflict=function(){return e.fn.button=n,this},e(document).on("click.button.data-api","[data-toggle^=button]",function(t){var n=e(t.target);n.hasClass("btn")||(n=n.closest(".btn")),n.button("toggle")})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.$indicators=this.$element.find(".carousel-indicators"),this.options=n,this.options.pause=="hover"&&this.$element.on("mouseenter",e.proxy(this.pause,this)).on("mouseleave",e.proxy(this.cycle,this))};t.prototype={cycle:function(t){return t||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(e.proxy(this.next,this),this.options.interval)),this},getActiveIndex:function(){return this.$active=this.$element.find(".item.active"),this.$items=this.$active.parent().children(),this.$items.index(this.$active)},to:function(t){var n=this.getActiv eIndex(),r=this;if(t>this.$items.length-1||t<0)return;return this.sliding?this.$element.one("slid",function(){r.to(t)}):n==t?this.pause().cycle():this.slide(t>n?"next":"prev",e(this.$items[t]))},pause:function(t){return t||(this.paused=!0),this.$element.find(".next, .prev").length&&e.support.transition.end&&(this.$element.trigger(e.support.transition.end),this.cycle(!0)),clearInterval(this.interval),this.interval=null,this},next:function(){if(this.sliding)return;return this.slide("next")},prev:function(){if(this.sliding)return;return this.slide("prev")},slide:function(t,n){var r=this.$element.find(".item.active"),i=n||r[t](),s=this.interval,o=t=="next"?"left":"right",u=t=="next"?"first":"last",a=this,f;this.sliding=!0,s&&this.pause(),i=i.length?i:this.$element.find(".item")[u](),f=e.Event("slide",{relatedTarget:i[0],direction:o});if(i.hasClass("active"))return;this.$indicators.length&&(this.$indicators.find(".active").removeClass("active"),this.$element.one("slid",function() {var t=e(a.$indicators.children()[a.getActiveIndex()]);t&&t.addClass("active")}));if(e.support.transition&&this.$element.hasClass("slide")){this.$element.trigger(f);if(f.isDefaultPrevented())return;i.addClass(t),i[0].offsetWidth,r.addClass(o),i.addClass(o),this.$element.one(e.support.transition.end,function(){i.removeClass([t,o].join(" ")).addClass("active"),r.removeClass(["active",o].join(" ")),a.sliding=!1,setTimeout(function(){a.$element.trigger("slid")},0)})}else{this.$element.trigger(f);if(f.isDefaultPrevented())return;r.removeClass("active"),i.addClass("active"),this.sliding=!1,this.$element.trigger("slid")}return s&&this.cycle(),this}};var n=e.fn.carousel;e.fn.carousel=function(n){return this.each(function(){var r=e(this),i=r.data("carousel"),s=e.extend({},e.fn.carousel.defaults,typeof n=="object"&&n),o=typeof n=="string"?n:s.slide;i||r.data("carousel",i=new t(this,s)),typeof n=="number"?i.to(n):o?i[o]():s.interval&&i.pause().cycle()})},e.fn.carousel.defaults={interva l:5e3,pause:"hover"},e.fn.carousel.Constructor=t,e.fn.carousel.noConflict=function(){return e.fn.carousel=n,this},e(document).on("click.carousel.data-api","[data-slide], [data-slide-to]",function(t){var n=e(this),r,i=e(n.attr("data-target")||(r=n.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,"")),s=e.extend({},i.data(),n.data()),o;i.carousel(s),(o=n.attr("data-slide-to"))&&i.data("carousel").pause().to(o).cycle(),t.preventDefault()})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.options=e.extend({},e.fn.collapse.defaults,n),this.options.parent&&(this.$parent=e(this.options.parent)),this.options.toggle&&this.toggle()};t.prototype={constructor:t,dimension:function(){var e=this.$element.hasClass("width");return e?"width":"height"},show:function(){var t,n,r,i;if(this.transitioning||this.$element.hasClass("in"))return;t=this.dimension(),n=e.camelCase(["scroll",t].join("-")),r=this.$parent&&this.$parent.find("> .accordion-group > .in");if(r&&r.l ength){i=r.data("collapse");if(i&&i.transitioning)return;r.collapse("hide"),i||r.data("collapse",null)}this.$element[t](0),this.transition("addClass",e.Event("show"),"shown"),e.support.transition&&this.$element[t](this.$element[0][n])},hide:function(){var t;if(this.transitioning||!this.$element.hasClass("in"))return;t=this.dimension(),this.reset(this.$element[t]()),this.transition("removeClass",e.Event("hide"),"hidden"),this.$element[t](0)},reset:function(e){var t=this.dimension();return this.$element.removeClass("collapse")[t](e||"auto")[0].offsetWidth,this.$element[e!==null?"addClass":"removeClass"]("collapse"),this},transition:function(t,n,r){var i=this,s=function(){n.type=="show"&&i.reset(),i.transitioning=0,i.$element.trigger(r)};this.$element.trigger(n);if(n.isDefaultPrevented())return;this.transitioning=1,this.$element[t]("in"),e.support.transition&&this.$element.hasClass("collapse")?this.$element.one(e.support.transition.end,s):s()},toggle:function(){this[this.$eleme nt.hasClass("in")?"hide":"show"]()}};var n=e.fn.collapse;e.fn.collapse=function(n){return this.each(function(){var r=e(this),i=r.data("collapse"),s=e.extend({},e.fn.collapse.defaults,r.data(),typeof n=="object"&&n);i||r.data("collapse",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.collapse.defaults={toggle:!0},e.fn.collapse.Constructor=t,e.fn.collapse.noConflict=function(){return e.fn.collapse=n,this},e(document).on("click.collapse.data-api","[data-toggle=collapse]",function(t){var n=e(this),r,i=n.attr("data-target")||t.preventDefault()||(r=n.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,""),s=e(i).data("collapse")?"toggle":n.data();n[e(i).hasClass("in")?"addClass":"removeClass"]("collapsed"),e(i).collapse(s)})}(window.jQuery),!function(e){"use strict";function r(){e(t).each(function(){i(e(this)).removeClass("open")})}function i(t){var n=t.attr("data-target"),r;n||(n=t.attr("href"),n=n&&/#/.test(n)&&n.replace(/.*(?=#[^\s]*$)/,"")),r=n&&e(n);if(!r||!r.length)r=t.parent();re turn r}var t="[data-toggle=dropdown]",n=function(t){var n=e(t).on("click.dropdown.data-api",this.toggle);e("html").on("click.dropdown.data-api",function(){n.parent().removeClass("open")})};n.prototype={constructor:n,toggle:function(t){var n=e(this),s,o;if(n.is(".disabled, :disabled"))return;return s=i(n),o=s.hasClass("open"),r(),o||s.toggleClass("open"),n.focus(),!1},keydown:function(n){var r,s,o,u,a,f;if(!/(38|40|27)/.test(n.keyCode))return;r=e(this),n.preventDefault(),n.stopPropagation();if(r.is(".disabled, :disabled"))return;u=i(r),a=u.hasClass("open");if(!a||a&&n.keyCode==27)return n.which==27&&u.find(t).focus(),r.click();s=e("[role=menu] li:not(.divider):visible a",u);if(!s.length)return;f=s.index(s.filter(":focus")),n.keyCode==38&&f>0&&f--,n.keyCode==40&&f').appendTo(document.body),this.$backdrop.click(this.options.backdrop=="static"?e.proxy(this.$element[0].focus,this.$element[0]):e.proxy(this.hide,this)),i&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in");if(!t)return;i?this.$backdrop.one(e.support.transition.end,t):t()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeC lass("in"),e.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one(e.support.transition.end,t):t()):t&&t()}};var n=e.fn.modal;e.fn.modal=function(n){return this.each(function(){var r=e(this),i=r.data("modal"),s=e.extend({},e.fn.modal.defaults,r.data(),typeof n=="object"&&n);i||r.data("modal",i=new t(this,s)),typeof n=="string"?i[n]():s.show&&i.show()})},e.fn.modal.defaults={backdrop:!0,keyboard:!0,show:!0},e.fn.modal.Constructor=t,e.fn.modal.noConflict=function(){return e.fn.modal=n,this},e(document).on("click.modal.data-api",'[data-toggle="modal"]',function(t){var n=e(this),r=n.attr("href"),i=e(n.attr("data-target")||r&&r.replace(/.*(?=#[^\s]+$)/,"")),s=i.data("modal")?"toggle":e.extend({remote:!/#/.test(r)&&r},i.data(),n.data());t.preventDefault(),i.modal(s).one("hide",function(){n.focus()})})}(window.jQuery),!function(e){"use strict";var t=function(e,t){this.init("tooltip",e,t)};t.prototype={constructor:t,init:function(t,n,r){var i,s,o,u,a;this.type=t,this .$element=e(n),this.options=this.getOptions(r),this.enabled=!0,o=this.options.trigger.split(" ");for(a=o.length;a--;)u=o[a],u=="click"?this.$element.on("click."+this.type,this.options.selector,e.proxy(this.toggle,this)):u!="manual"&&(i=u=="hover"?"mouseenter":"focus",s=u=="hover"?"mouseleave":"blur",this.$element.on(i+"."+this.type,this.options.selector,e.proxy(this.enter,this)),this.$element.on(s+"."+this.type,this.options.selector,e.proxy(this.leave,this)));this.options.selector?this._options=e.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(t){return t=e.extend({},e.fn[this.type].defaults,this.$element.data(),t),t.delay&&typeof t.delay=="number"&&(t.delay={show:t.delay,hide:t.delay}),t},enter:function(t){var n=e.fn[this.type].defaults,r={},i;this._options&&e.each(this._options,function(e,t){n[e]!=t&&(r[e]=t)},this),i=e(t.currentTarget)[this.type](r).data(this.type);if(!i.options.delay||!i.options.delay.show)return i.show();clear Timeout(this.timeout),i.hoverState="in",this.timeout=setTimeout(function(){i.hoverState=="in"&&i.show()},i.options.delay.show)},leave:function(t){var n=e(t.currentTarget)[this.type](this._options).data(this.type);this.timeout&&clearTimeout(this.timeout);if(!n.options.delay||!n.options.delay.hide)return n.hide();n.hoverState="out",this.timeout=setTimeout(function(){n.hoverState=="out"&&n.hide()},n.options.delay.hide)},show:function(){var t,n,r,i,s,o,u=e.Event("show");if(this.hasContent()&&this.enabled){this.$element.trigger(u);if(u.isDefaultPrevented())return;t=this.tip(),this.setContent(),this.options.animation&&t.addClass("fade"),s=typeof this.options.placement=="function"?this.options.placement.call(this,t[0],this.$element[0]):this.options.placement,t.detach().css({top:0,left:0,display:"block"}),this.options.container?t.appendTo(this.options.container):t.insertAfter(this.$element),n=this.getPosition(),r=t[0].offsetWidth,i=t[0].offsetHeight;switch(s){case"bottom":o={top:n.t op+n.height,left:n.left+n.width/2-r/2};break;case"top":o={top:n.top-i,left:n.left+n.width/2-r/2};break;case"left":o={top:n.top+n.height/2-i/2,left:n.left-r};break;case"right":o={top:n.top+n.height/2-i/2,left:n.left+n.width}}this.applyPlacement(o,s),this.$element.trigger("shown")}},applyPlacement:function(e,t){var n=this.tip(),r=n[0].offsetWidth,i=n[0].offsetHeight,s,o,u,a;n.offset(e).addClass(t).addClass("in"),s=n[0].offsetWidth,o=n[0].offsetHeight,t=="top"&&o!=i&&(e.top=e.top+i-o,a=!0),t=="bottom"||t=="top"?(u=0,e.left<0&&(u=e.left*-2,e.left=0,n.offset(e),s=n[0].offsetWidth,o=n[0].offsetHeight),this.replaceArrow(u-r+s,s,"left")):this.replaceArrow(o-i,o,"top"),a&&n.offset(e)},replaceArrow:function(e,t,n){this.arrow().css(n,e?50*(1-e/t)+"%":"")},setContent:function(){var e=this.tip(),t=this.getTitle();e.find(".tooltip-inner")[this.options.html?"html":"text"](t),e.removeClass("fade in top bottom left right")},hide:function(){function i(){var t=setTimeout(function(){n.off(e.sup port.transition.end).detach()},500);n.one(e.support.transition.end,function(){clearTimeout(t),n.detach()})}var t=this,n=this.tip(),r=e.Event("hide");this.$element.trigger(r);if(r.isDefaultPrevented())return;return n.removeClass("in"),e.support.transition&&this.$tip.hasClass("fade")?i():n.detach(),this.$element.trigger("hidden"),this},fixTitle:function(){var e=this.$element;(e.attr("title")||typeof e.attr("data-original-title")!="string")&&e.attr("data-original-title",e.attr("title")||"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(){var t=this.$element[0];return e.extend({},typeof t.getBoundingClientRect=="function"?t.getBoundingClientRect():{width:t.offsetWidth,height:t.offsetHeight},this.$element.offset())},getTitle:function(){var e,t=this.$element,n=this.options;return e=t.attr("data-original-title")||(typeof n.title=="function"?n.title.call(t[0]):n.title),e},tip:function(){return this.$tip=this.$tip||e(this.options.template)},arro w:function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(t){var n=t?e(t.currentTarget)[this.type](this._options).data(this.type):this;n.tip().hasClass("in")?n.hide():n.show()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}};var n=e.fn.tooltip;e.fn.tooltip=function(n){return this.each(function(){var r=e(this),i=r.data("tooltip"),s=typeof n=="object"&&n;i||r.data("tooltip",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.tooltip.Constructor=t,e.fn.tooltip.defaults={animation:!0,placement:"top",selector:!1,template:'
',trigger:"hover focus",title:"",delay:0,html:!1,container:!1},e.fn.tooltip .noConflict=function(){return e.fn.tooltip=n,this}}(window.jQuery),!function(e){"use strict";var t=function(e,t){this.init("popover",e,t)};t.prototype=e.extend({},e.fn.tooltip.Constructor.prototype,{constructor:t,setContent:function(){var e=this.tip(),t=this.getTitle(),n=this.getContent();e.find(".popover-title")[this.options.html?"html":"text"](t),e.find(".popover-content")[this.options.html?"html":"text"](n),e.removeClass("fade top bottom left right in")},hasContent:function(){return this.getTitle()||this.getContent()},getContent:function(){var e,t=this.$element,n=this.options;return e=(typeof n.content=="function"?n.content.call(t[0]):n.content)||t.attr("data-content"),e},tip:function(){return this.$tip||(this.$tip=e(this.options.template)),this.$tip},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}});var n=e.fn.popover;e.fn.popover=function(n){return this.each(function(){var r=e(this),i=r.data("popover"),s=typeof n=="object"&&n;i||r.data( "popover",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.popover.Constructor=t,e.fn.popover.defaults=e.extend({},e.fn.tooltip.defaults,{placement:"right",trigger:"click",content:"",template:'

'}),e.fn.popover.noConflict=function(){return e.fn.popover=n,this}}(window.jQuery),!function(e){"use strict";function t(t,n){var r=e.proxy(this.process,this),i=e(t).is("body")?e(window):e(t),s;this.options=e.extend({},e.fn.scrollspy.defaults,n),this.$scrollElement=i.on("scroll.scroll-spy.data-api",r),this.selector=(this.options.target||(s=e(t).attr("href"))&&s.replace(/.*(?=#[^\s]+$)/,"")||"")+" .nav li > a",this.$body=e("body"),this.refresh(),this.process()}t.prototype={constructor:t,refresh:function(){var t=this,n;this.offsets=e([]),this.targets=e([]),n=this.$body.find(this.selector).map(function(){var n=e(this),r=n.data("target")||n.attr("href"),i=/^#\w/.test(r)&& e(r);return i&&i.length&&[[i.position().top+(!e.isWindow(t.$scrollElement.get(0))&&t.$scrollElement.scrollTop()),r]]||null}).sort(function(e,t){return e[0]-t[0]}).each(function(){t.offsets.push(this[0]),t.targets.push(this[1])})},process:function(){var e=this.$scrollElement.scrollTop()+this.options.offset,t=this.$scrollElement[0].scrollHeight||this.$body[0].scrollHeight,n=t-this.$scrollElement.height(),r=this.offsets,i=this.targets,s=this.activeTarget,o;if(e>=n)return s!=(o=i.last()[0])&&this.activate(o);for(o=r.length;o--;)s!=i[o]&&e>=r[o]&&(!r[o+1]||e<=r[o+1])&&this.activate(i[o])},activate:function(t){var n,r;this.activeTarget=t,e(this.selector).parent(".active").removeClass("active"),r=this.selector+'[data-target="'+t+'"],'+this.selector+'[href="'+t+'"]',n=e(r).parent("li").addClass("active"),n.parent(".dropdown-menu").length&&(n=n.closest("li.dropdown").addClass("active")),n.trigger("activate")}};var n=e.fn.scrollspy;e.fn.scrollspy=function(n){return this.each(function( ){var r=e(this),i=r.data("scrollspy"),s=typeof n=="object"&&n;i||r.data("scrollspy",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.scrollspy.Constructor=t,e.fn.scrollspy.defaults={offset:10},e.fn.scrollspy.noConflict=function(){return e.fn.scrollspy=n,this},e(window).on("load",function(){e('[data-spy="scroll"]').each(function(){var t=e(this);t.scrollspy(t.data())})})}(window.jQuery),!function(e){"use strict";var t=function(t){this.element=e(t)};t.prototype={constructor:t,show:function(){var t=this.element,n=t.closest("ul:not(.dropdown-menu)"),r=t.attr("data-target"),i,s,o;r||(r=t.attr("href"),r=r&&r.replace(/.*(?=#[^\s]*$)/,""));if(t.parent("li").hasClass("active"))return;i=n.find(".active:last a")[0],o=e.Event("show",{relatedTarget:i}),t.trigger(o);if(o.isDefaultPrevented())return;s=e(r),this.activate(t.parent("li"),n),this.activate(s,s.parent(),function(){t.trigger({type:"shown",relatedTarget:i})})},activate:function(t,n,r){function o(){i.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),t.addClass("active"),s?(t[0].offsetWidth,t.addClass("in")):t.removeClass("fade"),t.parent(".dropdown-menu")&&t.closest("li.dropdown").addClass("active"),r&&r()}var i=n.find("> .active"),s=r&&e.support.transition&&i.hasClass("fade");s?i.one(e.support.transition.end,o):o(),i.removeClass("in")}};var n=e.fn.tab;e.fn.tab=function(n){return this.each(function(){var r=e(this),i=r.data("tab");i||r.data("tab",i=new t(this)),typeof n=="string"&&i[n]()})},e.fn.tab.Constructor=t,e.fn.tab.noConflict=function(){return e.fn.tab=n,this},e(document).on("click.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(t){t.preventDefault(),e(this).tab("show")})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.options=e.extend({},e.fn.typeahead.defaults,n),this.matcher=this.options.matcher||this.matcher,this.sorter=this.options.sorter||this.sorter,this.highlighter=this.options.highlighter||this.highl ighter,this.updater=this.options.updater||this.updater,this.source=this.options.source,this.$menu=e(this.options.menu),this.shown=!1,this.listen()};t.prototype={constructor:t,select:function(){var e=this.$menu.find(".active").attr("data-value");return this.$element.val(this.updater(e)).change(),this.hide()},updater:function(e){return e},show:function(){var t=e.extend({},this.$element.position(),{height:this.$element[0].offsetHeight});return this.$menu.insertAfter(this.$element).css({top:t.top+t.height,left:t.left}).show(),this.shown=!0,this},hide:function(){return this.$menu.hide(),this.shown=!1,this},lookup:function(t){var n;return this.query=this.$element.val(),!this.query||this.query.length"+t+""})},render:function(t){var n=this;return t=e(t).map(function(t,r){return t=e(n.options.item).attr("data-value",r),t.find("a").html(n.highlighter(r)),t[0]}),t.first().addClass("active"),this.$menu.html(t),this},next:function(t){var n=this.$menu.find(".active").removeClass("active"),r=n.next();r.length||(r=e(this.$menu.find("li")[0])),r.addClass("active")},prev:function(e){var t=this.$menu.find(".active").removeClass("active"),n=t.prev();n.length||(n=this.$menu.find("li").last()), n.addClass("active")},listen:function(){this.$element.on("focus",e.proxy(this.focus,this)).on("blur",e.proxy(this.blur,this)).on("keypress",e.proxy(this.keypress,this)).on("keyup",e.proxy(this.keyup,this)),this.eventSupported("keydown")&&this.$element.on("keydown",e.proxy(this.keydown,this)),this.$menu.on("click",e.proxy(this.click,this)).on("mouseenter","li",e.proxy(this.mouseenter,this)).on("mouseleave","li",e.proxy(this.mouseleave,this))},eventSupported:function(e){var t=e in this.$element;return t||(this.$element.setAttribute(e,"return;"),t=typeof this.$element[e]=="function"),t},move:function(e){if(!this.shown)return;switch(e.keyCode){case 9:case 13:case 27:e.preventDefault();break;case 38:e.preventDefault(),this.prev();break;case 40:e.preventDefault(),this.next()}e.stopPropagation()},keydown:function(t){this.suppressKeyPressRepeat=~e.inArray(t.keyCode,[40,38,9,13,27]),this.move(t)},keypress:function(e){if(this.suppressKeyPressRepeat)return;this.move(e)},keyup:function( e){switch(e.keyCode){case 40:case 38:case 16:case 17:case 18:break;case 9:case 13:if(!this.shown)return;this.select();break;case 27:if(!this.shown)return;this.hide();break;default:this.lookup()}e.stopPropagation(),e.preventDefault()},focus:function(e){this.focused=!0},blur:function(e){this.focused=!1,!this.mousedover&&this.shown&&this.hide()},click:function(e){e.stopPropagation(),e.preventDefault(),this.select(),this.$element.focus()},mouseenter:function(t){this.mousedover=!0,this.$menu.find(".active").removeClass("active"),e(t.currentTarget).addClass("active")},mouseleave:function(e){this.mousedover=!1,!this.focused&&this.shown&&this.hide()}};var n=e.fn.typeahead;e.fn.typeahead=function(n){return this.each(function(){var r=e(this),i=r.data("typeahead"),s=typeof n=="object"&&n;i||r.data("typeahead",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.typeahead.defaults={source:[],items:8,menu:'',item:'
  • ',minLeng th:1},e.fn.typeahead.Constructor=t,e.fn.typeahead.noConflict=function(){return e.fn.typeahead=n,this},e(document).on("focus.typeahead.data-api",'[data-provide="typeahead"]',function(t){var n=e(this);if(n.data("typeahead"))return;n.typeahead(n.data())})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.options=e.extend({},e.fn.affix.defaults,n),this.$window=e(window).on("scroll.affix.data-api",e.proxy(this.checkPosition,this)).on("click.affix.data-api",e.proxy(function(){setTimeout(e.proxy(this.checkPosition,this),1)},this)),this.$element=e(t),this.checkPosition()};t.prototype.checkPosition=function(){if(!this.$element.is(":visible"))return;var t=e(document).height(),n=this.$window.scrollTop(),r=this.$element.offset(),i=this.options.offset,s=i.bottom,o=i.top,u="affix affix-top affix-bottom",a;typeof i!="object"&&(s=o=i),typeof o=="function"&&(o=i.top()),typeof s=="function"&&(s=i.bottom()),a=this.unpin!=null&&n+this.unpin<=r.top?!1:s!=null&&r.top+this.$elemen t.height()>=t-s?"bottom":o!=null&&n<=o?"top":!1;if(this.affixed===a)return;this.affixed=a,this.unpin=a=="bottom"?r.top-n:null,this.$element.removeClass(u).addClass("affix"+(a?"-"+a:""))};var n=e.fn.affix;e.fn.affix=function(n){return this.each(function(){var r=e(this),i=r.data("affix"),s=typeof n=="object"&&n;i||r.data("affix",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.affix.Constructor=t,e.fn.affix.defaults={offset:0},e.fn.affix.noConflict=function(){return e.fn.affix=n,this},e(window).on("load",function(){e('[data-spy="affix"]').each(function(){var t=e(this),n=t.data();n.offset=n.offset||{},n.offsetBottom&&(n.offset.bottom=n.offsetBottom),n.offsetTop&&(n.offset.top=n.offsetTop),t.affix(n)})})}(window.jQuery); \ No newline at end of file Added: websites/staging/pdfbox/trunk/content/building.html ============================================================================== --- websites/staging/pdfbox/trunk/content/building.html (added) +++ websites/staging/pdfbox/trunk/content/building.html Tue May 7 19:45:58 2013 @@ -0,0 +1,224 @@ + + + + + + + Apache PDFBox | Building PDFBox + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    +
    + +
    +
    + +
    +

    Building PDFBox

    +

    Instructions

    +

    This page will describe how to build PDFBox. Most users should find the +binary releases adequate, but if you are contributing to PDFBox then you +will need to know how to properly build the project.

    +

    You can obtain the latest source of PDFBox from SVN, see the download +page for information about how to connect to SVN. The +instructions below should also work for a released/nightly distribution.

    +

    Starting with PDFBox 1.0.0, the default build system is based on Maven:

    +
      +
    1. Install Maven 2
    2. +
    3. Run "mvn clean install" from the PDFBox root
    4. +
    +

    The old Ant build is still available, and can be used especially for +building .NET binaries with IKVM:

    +
      +
    1. Install ANT. PDFBox currently uses 1.6.2 + but other versions probably work as well.
    2. +
    3. +

      (optional) Setup IKVM, if you want to build the .NET DLL version of + PDFBox.

      +
        +
      1. IKVM binaries
      2. +
      3. In the build.properties, set the ikvm.dir property:\ + ikvm.dir=C:\\javalib\\ikvm-12-07-2004\\ikvm
      4. +
      +
    4. +
    5. +

      Run "ant" from the root PDFBox directory. This will create the + .zip package distribution. See the build file for other ant targets.

      +
    6. +
    +

    NOTE: If you want to run PDFBox from an IDE them you will need to add +the 'Resources' directory to the project classpath in your IDE.

    +

    Running/Debugging PDFBox in Eclipse

    +

    In order to run PDFBox from within Eclipse there are a couple things +that need to be setup. Certain pieces of functionality require access to +the Resources folder. Here is an example of what you need to do to run +the ExtractText command line application.

    +
      +
    1. In Eclipse click on "run..." or "debug..."
    2. +
    3. In the tree on the left select "Java Application" and click "New"
    4. +
    5. Name it, select the correct project, and the main class
    6. +
    7. Select the "Arguments" tab and enter the command line arguments to + the app
    8. +
    9. Select the "Classpath" tab, the pdfbox project and jars should + already be added in the "User Entries"
    10. +
    11. Select the "User Entries" item and click the "Advanced" button
    12. +
    13. The "Add Folder" radio button should be selected, press ok
    14. +
    15. Select the root of the pdfbox project, this will make the + "Resources" folder available on the classpath.
    16. +
    +

    Applying Patches to other branches

    +

    In order to apply patches from 'trunk' to branches follow these steps

    +
      +
    • checkout the branch
    • +
    • cd to the branch directory
    • +
    • merge some changes from the trunk using "svn merge -cREV1,REV2,REV3... https://svn.apache.org/repos/asf/pdfbox/trunk"
    • +
    • commit the changes
    • +

    +
    +
    +
    + +
    +
    +
    + +
    + +
    +

    Copyright © 2013 The Apache Software Foundation, Licensed under the Apache License, Version 2.0.
    + Apache PDFBox, PDFBox, Apache, the Apache feather logo and the Apache PDFBox project logos are trademarks of The Apache Software Foundation.

    +
    +
    +
    + + + Added: websites/staging/pdfbox/trunk/content/codingconventions.html ============================================================================== --- websites/staging/pdfbox/trunk/content/codingconventions.html (added) +++ websites/staging/pdfbox/trunk/content/codingconventions.html Tue May 7 19:45:58 2013 @@ -0,0 +1,217 @@ + + + + + + + Apache PDFBox | Coding Conventions + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    +
    + +
    +
    + +
    +

    Coding Conventions

    +

    Introduction

    +

    To improve the readability and to ease maintenance of the PDFBox code there are a small +number of coding conventions.

    +

    Indentation

    +

    Use 4 spaces for indentation. No tabs!

    +

    Brackets

    +

    Place open braces on the line after the declaration, for example:

    +
    public class Foo extends Bar
    +{
    +    public static void main(String args[])
    +    {
    +        try
    +        {
    +            for (int i = 0; i < args.length; i++)
    +            {
    +                System.out.println(Integer.parseInt(args[i]));
    +            }
    +        }
    +        catch(NumberFormatException e)
    +        {
    +            e.printStackTrace();
    +        }
    +    }
    +}
    +
    + + +

    Line Wrapping

    +

    Wrap lines longer than 100 characters. For wrapped lines, either use an indent of 8 +characters or align with the expression at the same level on the previous line.

    +

    Declarations

    +

    Within a class or interface, definitions should be ordered as follows:

    +
      +
    • Class (static) variables
      +
    • +
    • Instance variables
      +
    • +
    • Constructors
      +
    • +
    • Methods
      +
    • +
    +

    Imports

    +

    Do not use package imports (for example import import java.util.*;)

    +

    Other

    +

    For other cases, we try to follow Sun's code conventions as much as possible.

    +

    For Eclipse Users

    +

    Eclipse users may download this preferences file: pdfbox-checkstyle-5.xml and import this into Eclipse. +(Window->Preferences, go to Java->Code Style->Formatter and click "Import..."). +Once you have done this you can reformat your code by using Source->Format (Ctrl+Shift+F).

    +

    Also note that Eclipse will automatically format your import statements appropriately when +you invoke Source -> Organize Imports (Ctrl+Shift+O).

    +
    +
    +
    + +
    +
    +
    + +
    + +
    +

    Copyright © 2013 The Apache Software Foundation, Licensed under the Apache License, Version 2.0.
    + Apache PDFBox, PDFBox, Apache, the Apache feather logo and the Apache PDFBox project logos are trademarks of The Apache Software Foundation.

    +
    +
    +
    + + + Added: websites/staging/pdfbox/trunk/content/commandline/index.html ============================================================================== --- websites/staging/pdfbox/trunk/content/commandline/index.html (added) +++ websites/staging/pdfbox/trunk/content/commandline/index.html Tue May 7 19:45:58 2013 @@ -0,0 +1,658 @@ + + + + + + + Apache PDFBox | Command Line Tools + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    +
    + +
    +
    + +
    +

    Command Line Tools

    +

    PDFBox comes with a series of command line utilities. They are available as Windows +binaries and as standard Java applications.

    +

    See the Dependencies page for instructions on how to set your classpath in order to run +PDFBox tools as Java applications.

    +

    In order to run them as window applications you will need to have the .NET framework +installed and add %PDFBOX_HOME%\bin to your path.

    +

    ConvertColorspace

    +

    This application will convert a PDF that uses one colorspace to another. For example, all +RGB colors to CMYK colors. +Currently this only supports changing text and vector graphics and does not convert images.

    +

    usage: java -jar pdfbox-app-x.y.z.jar org.apache.pdfbox.ConvertColorspace [OPTIONS] <inputfile> <outputfile>

    + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDescription
    -passwordThe password to the PDF document.
    -equivColor equivalent to use for conversion.
    inputfileThe PDF file to convert.
    outputfileThe file to save the converted document to. Must be different of input file
    +

    The format for the color equivalent described above is
    +Colorspace(values)=Colorspace(values)

    +

    RGB(255,0,0)=CMYK(0,99,100,0)

    +

    RGB are integers between 0 and 255

    +

    CMYK are integers between 0 and 100

    +

    This option can be used as many times as necessary.

    +

    Decrypt

    +

    This application will decrypt a PDF document.

    +

    NOTE: You must have the owner password to decrypt the document!

    +

    usage: java -jar pdfbox-app-x.y.z.jar Decrypt [OPTIONS] <inputfile> [outputfile]

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDescription
    -passwordPassword to the PDF or certificate in keystore.
    -keyStorePath to keystore that holds certificate to decrypt the document. This is only required if the document is encrypted with a certificate, otherwise only the password is required.
    -aliasThe alias to the certificate in the keystore.
    inputfileThe PDF file to decrypt.
    outputfileThe file to save the decrypted document to. If left blank then it will be the same as the input file.
    +

    Encrypt

    +

    This application will encrypt a PDF document.

    +

    usage: java -jar pdfbox-app-x.y.z.jar Encrypt [OPTIONS] <password> <inputfile>

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -OThe owner password to the PDF, ignored if -certFile is specified.
    -UThe user password to the PDF, ignored if -certFile is specified.
    -certFilePath to X.509 cert file.
    -canAssembletrueSet the assemble permission.
    -canExtractContenttrueSet the extraction permission.
    -canExtractForAccessibilitytrueSet the extraction permission.
    -canFillInFormtrueSet the fill in form permission.
    -canModifytrueSet the modify permission.
    -canModifyAnnotationstrueSet the modify annots permission.
    -canPrinttrueSet the print permission.
    -canPrintDegradedtrueSet the print degraded permission.
    -keyLength40The number of bits for the encryption key.
    inputfile>The PDF file to encrypt.
    outputfileThe file to save the encrypted document to. If left blank then it will be the same as the input file.
    +

    ExtractText

    +

    This application will extract all text from the given PDF document.

    +

    usage: java -jar pdfbox-app-x.y.z.jar ExtractText [OPTIONS] <inputfile> [Text file]

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -passwordThe password to the PDF document.
    -encodingdefault encodingThe encoding type of the text file, e.g. ISO-8859-1, UTF-8, UTF-16BE.
    -consolefalseSend text to console instead of file.
    -htmlfalseOutput in HTML format instead of raw text.
    -sortfalseSort the text before writing.
    -ignoreBeadsfalseDisables the separation by beads.
    -forcefalseEnables pdfbox to ignore corrupt objects.
    -debugfalseEnables debug output about the time consumption of every stage.
    -startPage1The first page to extract, one based.
    -endPageInteger.MAX_INTThe last page to extract, one based.
    -nonSeqfalseUse the new non sequential parser.
    +

    Overlay

    +

    This application will overlay one document with the content of another document

    +

    usage: java -jar pdfbox-app-x.y.z.jar Overlay <overlay.pdf> <document.pdf> <result.pdf>

    +

    If the overlay document contains more than one page the pages are overlayed to the document +on order e.g. if the document has 10 pages and the overlay contains 2 pages the order is Document: 1234567890 Overlay: 1212121212

    +

    PrintPDF

    +

    This application will send a pdf document to the printer.

    +

    You must have the correct permissions to print the document!

    + +

    usage: java -jar pdfbox-app-x.y.z.jar PrintPDF [OPTIONS] <inputfile>

    + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDescription
    -passwordThe password to decrypt the PDF.
    -silentPrintPrint the PDF without prompting for a printer.
    inputfileThe PDF file to print.
    +

    PDFDebugger

    +

    This application will take an existing PDF document and allows to analyze and inspect the internal structure

    +

    usage: java -jar pdfbox-app-x.y.z.jar PDFDebugger [inputfile]

    + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -passwordThe password to the PDF document.
    -nonSeqfalseUse the new non sequential parser.
    inputfilethe name of an optional PDF file to open.
    +

    PDFMerger

    +

    This application will take a list of pdf documents and merge them, saving the result in a new document.

    +

    usage: java -jar pdfbox-app-x.y.z.jar PDFMerger <Source PDF files (2 ..n)> <Target PDF file>

    +

    PDFReader

    +

    An application to read PDF documents. This will provide Acrobat Reader like functionality.

    +

    usage: java -jar pdfbox-app-x.y.z.jar PDFReader [PDF file]

    + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -passwordThe password to the PDF document.
    -nonSeqfalseUse the new non sequential parser.
    PDF filethe name of an optional PDF file to open
    +

    PDFSplit

    +

    This application will take an existing PDF document and split it into a number of other documents

    +

    usage: java -jar pdfbox-app-x.y.z.jar PDFSplit [OPTIONS] <PDF file>

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -passwordThe password to the PDF document.
    -splitNumber of pages of every splitted part of the pdf.
    -startPageThe page to start at.
    -endPageThe page to stop at.
    -nonSeqfalseUse the new non sequential parser.
    +

    Examples:

    +
      +
    • PDFSplit -split 2 sample_with_13_pages.pdf will split the pdf in pieces of 2 pages each except the last which will contain 1 page only.
    • +
    • PDFSplit -startPage 5 sample_with_13_pages.pdf will provide a pdf containing all pages of the source pdf starting at page 5
    • +
    • PDFSplit -startPage 5 -endPage 10 sample_with_13_pages.pdf will provide a pdf containing all pages from 5 to 10 of the source pdf
    • +
    • PDFSplit -split 2 -startPage 5 -endPage 10 sample_with_13_pages.pdf will provide 3 pdfs containing all pages from 5 to 10 of the source pdf 2 pages each
    • +
    +

    PDFToImage

    +

    This application will create an image for every page in the PDF document.

    +

    usage: java -jar pdfbox-app-x.y.z.jar PDFToImage [OPTIONS] <PDF file>

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -passwordThe password to the PDF document.
    -imageTypejpgThe image type to write to. Currently only jpg or png.
    -outputPrefixName of PDF documentThe prefix to the image file.
    -startPage1The first page to convert, one based.
    -endPageInteger.MAX_INTThe last page to convert, one based.
    -nonSeqfalseUse the new non sequential parser.
    +

    TextToPDF

    +

    This application will create a PDF document from a text file.

    +

    usage: java -jar pdfbox-app-x.y.z.jar TextToPDF [OPTIONS] <outputfile> <textfile>

    + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -standardFontHelveticaThe font to use for the text. Either this or -ttf should be specified but not both.
    -ttfThe TTF font to use for the text. Either this or -standardFont should be specified but not both.
    -fontSize10The size of the font to use.
    +

    The following font names can be used for the parameter standardFont:

    +
      +
    • Courier
    • +
    • Courier-Bold
    • +
    • Courier-Oblique
    • +
    • Courier-BoldOblique
    • +
    • Helvetica
    • +
    • Helvetica-Bold
    • +
    • Helvetica-Oblique
    • +
    • Helvetica-BoldOblique
    • +
    • Symbol
    • +
    • Times-Bold
    • +
    • Times-Roman
    • +
    • Times-Italic
    • +
    • Times-BoldItalic
    • +
    • ZapfDingbats
    • +
    +

    WriteDecodedDoc

    +

    An application to decompress PDF documents.

    +

    usage: java -jar pdfbox-app-x.y.z.jar WriteDecodedDoc <input-file> <output-file>

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Command Line ParameterDefaultDescription
    -passwordThe password to the PDF document.
    -nonSeqfalseUse the new non sequential parser.
    The PDF file to decompress
    The destination PDF file

    +
    +
    +
    + +
    +
    +
    + +
    + +
    +

    Copyright © 2013 The Apache Software Foundation, Licensed under the Apache License, Version 2.0.
    + Apache PDFBox, PDFBox, Apache, the Apache feather logo and the Apache PDFBox project logos are trademarks of The Apache Software Foundation.

    +
    +
    +
    + + + Added: websites/staging/pdfbox/trunk/content/cookbook/documentcreation.html ============================================================================== --- websites/staging/pdfbox/trunk/content/cookbook/documentcreation.html (added) +++ websites/staging/pdfbox/trunk/content/cookbook/documentcreation.html Tue May 7 19:45:58 2013 @@ -0,0 +1,210 @@ + + + + + + + Apache PDFBox | Cookbook - Document Creation + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    +
    + +
    +
    + +
    +

    Document Creation

    +

    Create a blank PDF

    +

    This small sample shows how to create a new PDF document using PDFBox.

    +
    // Create a new empty document
    +PDDocument document = new PDDocument();
    +
    +// Create a new blank page and add it to the document
    +PDPage blankPage = new PDPage();
    +document.addPage( blankPage );
    +
    +// Save the newly created document
    +document.save("BlankPage.pdf");
    +
    +// finally make sure that the document is properly
    +// closed.
    +document.close();
    +
    + + +

    Hello World using a PDF base font

    +

    This small sample shows how to create a new document and print the text "Hello World" using one of the PDF base fonts.

    +
    // Create a document and add a page to it
    +PDDocument document = new PDDocument();
    +PDPage page = new PDPage();
    +document.addPage( page );
    +
    +// Create a new font object selecting one of the PDF base fonts
    +PDFont font = PDType1Font.HELVETICA_BOLD;
    +
    +// Start a new content stream which will "hold" the to be created content
    +PDPageContentStream contentStream = new PDPageContentStream(document, page);
    +
    +// Define a text content stream using the selected font, moving the cursor and drawing the text "Hello World"
    +contentStream.beginText();
    +contentStream.setFont( font, 12 );
    +contentStream.moveTextPositionByAmount( 100, 700 );
    +contentStream.drawString( "Hello World" );
    +contentStream.endText();
    +
    +// Make sure that the content stream is closed:
    +contentStream.close();
    +
    +// Save the results and ensure that the document is properly closed:
    +document.save( "Hello World.pdf");
    +document.close();
    +

    +
    +
    +
    + + + + +