aboutsummaryrefslogtreecommitdiff
path: root/man/man3
diff options
context:
space:
mode:
authorRuss Cox <rsc@swtch.com>2012-11-25 22:15:57 -0500
committerRuss Cox <rsc@swtch.com>2012-11-25 22:15:57 -0500
commit9f3851871ed6edb544dfe5b518bff0121d6c020b (patch)
tree086485c69525c1923fc55f65a93605bd14e85f38 /man/man3
parent323e7d0193999a22e605786d06fcff76cb780e38 (diff)
downloadplan9port-9f3851871ed6edb544dfe5b518bff0121d6c020b.tar.gz
plan9port-9f3851871ed6edb544dfe5b518bff0121d6c020b.tar.bz2
plan9port-9f3851871ed6edb544dfe5b518bff0121d6c020b.zip
libdraw: add scalesize
R=rsc http://codereview.appspot.com/6855092
Diffstat (limited to 'man/man3')
-rw-r--r--man/man3/graphics.316
1 files changed, 16 insertions, 0 deletions
diff --git a/man/man3/graphics.3 b/man/man3/graphics.3
index 4b39332d..d07c269a 100644
--- a/man/man3/graphics.3
+++ b/man/man3/graphics.3
@@ -62,6 +62,9 @@ int gengetwindow(Display *d, char *winname,
Image **ip, Screen **sp, int ref)
.PP
.B
+int scalesize(Display *d, int n)
+.PP
+.B
void cursorswitch(Cursor *curs)
.PP
.B
@@ -502,6 +505,19 @@ and
.B Screen
variables for the new window.
.PP
+Historically, Plan 9 graphics programs have used fixed-size graphics features that assume a narrow range of display densities, around 100 dpi: pixels (or dots) per inch.
+The new field
+.B display->dpi
+contains the display's actual density if known, or else
+.B DefaultDPI
+(100).
+.I Scalesize
+scales the fixed pixel count
+.I n
+by
+.BR display->dpi / DefaultDPI ,
+rounding appropriately.
+.PP
The mouse cursor is always displayed.
The initial cursor is an arrow.
.I Cursorswitch