Keyboard Shortcuts

File
u :up to issue
m :publish + mail comments
M :edit review message
j / k :jump to file after / before current file
J / K :jump to next file with a comment after / before current file
Side-by-side diff
i :toggle intra-line diffs
e :expand all comments
c :collapse all comments
s :toggle showing all comments
n / p :next / previous diff chunk or comment
N / P :next / previous comment
<Up> / <Down> :next / previous line
<Enter> :respond to / edit current comment
d :mark current comment as done
Issue
u :up to list of issues
m :publish + mail comments
j / k :jump to patch after / before current patch
o / <Enter> :open current patch in side-by-side view
i :open current patch in unified diff view
Issue List
j / k :jump to issue after / before current issue
o / <Enter> :open current issue
# : close issue
Comment/message editing
<Ctrl> + s or <Ctrl> + Enter :save comment
<Esc> :cancel edit
Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(140)
Issues Repositories Search
Open Issues | Closed Issues | All Issues | Sign in with your Google Account to create issues and add comments

Issue 6592072: retina support in devdraw

Can't Edit
Can't Publish+Mail
Start Review
Created:
13 years, 3 months ago by robkroeger
Modified:
13 years, 2 months ago
Reviewers:
rsc
CC:
rsc, codebot
Visibility:
Public.

Patch Set 1 #

Patch Set 2 : With environment variable control and manual page adjustment #

Created: 13 years, 3 months ago
Download [raw] [tar.bz2]
Unified diffs Side-by-side diffs Delta from patch set Stats (+128 lines, -8 lines) Patch
M man/man1/devdraw.1 View 1 1 chunk +7 lines, -0 lines 0 comments Download
M src/cmd/devdraw/cocoa-screen.m View 1 21 chunks +121 lines, -8 lines 0 comments Download
Total messages: 11
|
robkroeger
13 years, 3 months ago (2012年10月04日 00:20:24 UTC) #1
Sign in to reply to this message.
robkroeger
This is a first-crack at making devdraw support the retina macbook display by letting p9p ...
13 years, 3 months ago (2012年10月04日 00:25:21 UTC) #2
This is a first-crack at making devdraw support the retina macbook display by
letting p9p apps use retina devices at the pixel resolution. Please take a look.
Sign in to reply to this message.
rsc
I don't have anything to try this on. Do you mean that this makes the ...
13 years, 3 months ago (2012年10月05日 21:21:47 UTC) #3
I don't have anything to try this on. Do you mean that this makes the app run at
the actual hw pixel resolution (so it will appear smaller) or something else?
Perhaps we need to let users choose?
Sign in to reply to this message.
robkroeger
On 2012年10月05日 21:21:47, rsc wrote: > I don't have anything to try this on. Any ...
13 years, 3 months ago (2012年10月05日 22:10:18 UTC) #4
On 2012年10月05日 21:21:47, rsc wrote:
> I don't have anything to try this on. 
Any mac with a big screen can be coerced into "retina" mode with the quartz
debug tool (http://osxdaily.com/2012/01/12/enable-hidpi-mode-in-mac-os-x-lion/)
> Do you mean that this makes the app run at
> the actual hw pixel resolution (so it will appear smaller) or something else?
> Perhaps we need to let users choose?
Yes. It makes devdraw use physical pixels so fonts and other drawing look tiny
without other measures. (Like doubling the size of -font when running acme.)
Cursors continue to be scaled by the operating system so have the right size
regardless.
This change has no effect when run on a non-retina devices and successfully
handles dragging windows from retina to non-retina display.
I see your point about letting users choose. I'm not sure how to do this -- or
more accurately -- I'm not sure which way this choosing should be enabled that
is not either a massive CL (which I would be happy to try to write albeit in
stages) or somehow icky. Do you have a suggestion? Perhaps an environment
variable? I could add this.
One possible "high road" way would be to do this patch and then add more:
* Make the device scale factor be an attribute of an Image object. A fragment of
code that is retina-unaware would have its output pixel doubled. A fragment of
code that is retina-aware would inform a draw-target Image of this awareness. So
existing code would keep looking like it does now.
* Make libframe retina-aware so it would draw fonts with glyph images and
metrics in physical pixel sizes. I went through this process on Chrome and the
text layout code has to either be pixel doubled (and look fuzzy) or operate in
pixel-layout precision (and look gorgeous) or else the glyphs
line-break/position wrongly.
Sign in to reply to this message.
rsc
A general complicating factor is that our best fonts are fixed sizes and are probably ...
13 years, 3 months ago (2012年10月06日 21:45:53 UTC) #5
A general complicating factor is that our best fonts are fixed sizes
and are probably too small for the retina display at native
resolution. However, I certainly would like to get something like this
into the tree for those who want to adjust things like font size. How
about disabling it by default but enabling if
atoi(getenv("devdrawretina")) > 0?
Thanks.
Russ
Sign in to reply to this message.
robkroeger
13 years, 3 months ago (2012年10月08日 15:28:26 UTC) #6
Sign in to reply to this message.
robkroeger
On 2012年10月08日 15:28:26, robkroeger wrote: Please take another look? I added the environment variable to ...
13 years, 2 months ago (2012年10月14日 12:47:48 UTC) #7
On 2012年10月08日 15:28:26, robkroeger wrote:
Please take another look? I added the environment variable to control retina
mode.
Sign in to reply to this message.
rsc
Thanks! Sorry, was away from mail for a few days.
13 years, 2 months ago (2012年10月16日 17:27:41 UTC) #8
Thanks! Sorry, was away from mail for a few days.
Sign in to reply to this message.
rsc
Builds fine on my Mountain Lion and whatever-was-before-that Macs.
13 years, 2 months ago (2012年10月16日 17:55:08 UTC) #9
Builds fine on my Mountain Lion and whatever-was-before-that Macs.
Sign in to reply to this message.
rsc
LGTM
13 years, 2 months ago (2012年10月16日 17:55:47 UTC) #10
LGTM
Sign in to reply to this message.
rsc
*** Submitted as http://code.google.com/p/plan9port/source/detail?r=c1233acdb9a4 *** devdraw: MacBook retina support Enable with export devdrawretina=1 (everything will ...
13 years, 2 months ago (2012年10月16日 17:55:55 UTC) #11
*** Submitted as http://code.google.com/p/plan9port/source/detail?r=c1233acdb9a4
***
devdraw: MacBook retina support
Enable with export devdrawretina=1 (everything will be smaller).
R=rsc
CC=plan9port.codebot
http://codereview.appspot.com/6592072
Committer: Russ Cox <rsc@swtch.com>
Sign in to reply to this message.
|
This is Rietveld f62528b

AltStyle によって変換されたページ (->オリジナル) /