From c96d832508cc6a8db1420b93242af08ec08be720 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Mon, 26 Nov 2012 00:33:05 -0500 Subject: acme: retina scaling for scroll bars, button R=rsc http://codereview.appspot.com/6854094 --- src/cmd/acme/dat.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/cmd/acme/dat.h') diff --git a/src/cmd/acme/dat.h b/src/cmd/acme/dat.h index 72860db3..d0feb095 100644 --- a/src/cmd/acme/dat.h +++ b/src/cmd/acme/dat.h @@ -463,12 +463,14 @@ enum BUFSIZE = Maxblock+IOHDRSZ, /* size from fbufalloc() */ RBUFSIZE = BUFSIZE/sizeof(Rune), EVENTSIZE = 256, - Scrollwid = 12, /* width of scroll bar */ - Scrollgap = 4, /* gap right of scroll bar */ - Margin = 4, /* margin around text */ - Border = 2 /* line between rows, cols, windows */ }; +#define Scrollwid scalesize(display, 12) +#define Scrollgap scalesize(display, 4) +#define Margin scalesize(display, 4) +#define Border scalesize(display, 2) +#define ButtonBorder scalesize(display, 2) + #define QID(w,q) ((w<<8)|(q)) #define WIN(q) ((((ulong)(q).path)>>8) & 0xFFFFFF) #define FILE(q) ((q).path & 0xFF) -- cgit v1.2.3