Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

for example,\hypersetup{colorlinks=false,frenchlinks=true,pdfborder={0 0 2}} makes the border 2 pixels, but what do the first two numbers do? I tried several values, but could see no difference.

share|improve this question
    
There is nothing on the manual about it. Perhaps Heiko han explain. Might simply be that this is just the syntax –  daleif May 5 at 12:47

1 Answer 1

up vote 6 down vote accepted

This is answered by the PDF specification (PDF 32000-1:2008):

Border

(Optional) An array specifying the characteristics of the annotation's border, which shall be drawn as a rounded rectangle.

(PDF 1.0) The array consists of three numbers defining the horizontal corner radius, vertical corner radius, and border width, all in default user space units. If the corner radii are 0, the border has square (not rounded) corners; if the border width is 0, no border is drawn.

(PDF 1.1) The array may have a fourth element, an optional dash array defining a pattern of dashes and gaps that shall be used in drawing the border. The dash array shall be specified in the same format as in the line dash pattern parameter of the graphics state (see 8.4.3.6, "Line Dash Pattern").

EXAMPLE A Border value of [ 0 0 1 [ 3 2 ] ] specifies a border 1 unit wide, with square corners, drawn with 3-unit dashes alternating with 2-unit gaps.

NOTE (PDF 1.2) The dictionaries for some annotation types (such as free text and polygon annotations) can include the BS entry. That entry specifies a border style dictionary that has more settings than the array specified for the Border entry. If an annotation dictionary includes the BS entry, then the Border entry is ignored.

Default value: [ 0 0 1 ].

share|improve this answer
    
well, this gets me partway. In LyX I tried for the hell of it \hypersetup{colorlinks=false,pdfborder={1 1 6 [ 3 2 ]} } and this gave me the thick dashes, but I didn't see any rounded corners. I also tried with more reasonable values like pdfborder={.5 .5 2 [ 3 2 ]} and pdfborder={0 0 2 [ 3 2 ]} –  asllearner May 5 at 15:30
1  
@asllearner: Not every detail of the PDF specification is implemented by PDF viewers. In fact even greater details are missing. I do not even get rounded corners with much larger values and without dash array in AR9.5.5/Linux. –  Heiko Oberdiek May 5 at 15:52
    
Fair enough. For what it is worth, I was using Acrobat on a mac. BTW I completely don't understand the NOTE for PDF1.2 in your answer, but no matter, I think you answered my real question. –  asllearner May 5 at 16:15
    
@asllearner: You have to dig deeper into the PDF specification to understand the note for PDF 1.2. A new feature, the border style (BS) directory is introduced in this version. For example, it allows to underline the link. It is supported by hyperref with option pdfborderstyle. See hyperref's README, section "Link border style" for an example. –  Heiko Oberdiek May 5 at 16:48
    
Will wonders never cease? ;-) Not as cool as rounded corners would have been, IMHO, but cool nonetheless. thx –  asllearner May 5 at 23:56

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.