"John Fox" <[EMAIL PROTECTED]> writes:

> Dear Peter,
> 
> (as.numeric(tkwinfo("width", .output$ID))
>     - 2*as.numeric(tkcget(.output, borderwidth=NULL)) - 2)/
>     as.numeric(tkfont.measure(tkcget(.output, font=NULL), "0"))
> 
> (for the text widget .output) appears to do the trick (note, subtracting 2
> rather than 4).

Hmm, that's odd. I needed the 4. Beware that Tcl does integer division
(%/%). Did you round() or floor() the result? 

-- 
   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - ([EMAIL PROTECTED])             FAX: (+45) 35327907

______________________________________________
R-devel@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Reply via email to