回复: one pixel=how many mm?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

回复: one pixel=how many mm?

luofeiyu
in my computer:
 xrandr
Screen 0: minimum 320 x 200, current 1280 x 800, maximum 8192 x 8192
LVDS1 connected 1280x800+0+0 (normal left inverted right x axis y axis) 331mm x 207mm

>>> import Tkinter
>>> root=Tkinter.Tk()
>>> k=root.winfo_fpixels('1m')
>>> print k
3.78698224852
>>> print 1280/k
338.0
why  it's  338  ,not  331mm??


 
------------------ 原始邮件 ------------------
发送时间: 2011年8月28日(星期天) 下午2:37
收件人: "tkinter-discuss"<[hidden email]>;
主题: Re: [Tkinter-discuss] one pixel=how many mm?
 
V Sun, 28 Aug 2011 10:10:30 +0800
"守株待兔" <[hidden email]> napsáno:

> in tkinter ,you can express  width in cm ,mm,inch,,pixel
> i want to know:
>  one pixel=how many mm?
 
pixels per mm   = root.winfo_fpixels('1m')
pixels per point = root.winfo_fpixels('1p')
pixels per inch   = root.winfo_fpixels('1i')
pixels per cm     = root.winfo_fpixels('1c')
_______________________________________________
Tkinter-discuss mailing list
[hidden email]
http://mail.python.org/mailman/listinfo/tkinter-discuss

_______________________________________________
Tkinter-discuss mailing list
[hidden email]
http://mail.python.org/mailman/listinfo/tkinter-discuss