Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
4c7077c3
Commit
4c7077c3
authored
Jan 21, 2009
by
Adrian Robert
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* nsimage.m (EmacsImage+allocInitFromFile:): Set to ignore DPI. (Bug#1316)
parent
a9b4df69
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
src/ChangeLog
src/ChangeLog
+4
-0
src/nsimage.m
src/nsimage.m
+8
-1
No files found.
src/ChangeLog
View file @
4c7077c3
2009-01-21 Adrian Robert <Adrian.B.Robert@gmail.com>
* nsmenu.m (NSMENUPROFILE): Change #if style.
* nsterm.m: (x_set_frame_alpha): Add prototype.
(ns_fake_keydown, EmacsView-keyUp:): New variable and function to
handle Ctrl-tab. (Bug#1841)
(ns_get_color): Use unsigned long long for scanned hex string value.
(ns_term_shutdown): Abort on non SIGTERM signals.
* nsimage.m (EmacsImage+allocInitFromFile:): Set to ignore DPI.
(Bug#1316)
2009-01-19 Chong Yidong <cyd@stupidchicken.com>
* xfaces.c (Finternal_set_lisp_face_attribute, Fx_list_fonts):
...
...
src/nsimage.m
View file @
4c7077c3
...
...
@@ -163,6 +163,7 @@ @implementation EmacsImage
+
allocInitFromFile
:
(
Lisp_Object
)
file
{
EmacsImage
*
image
=
ImageList
;
NSImageRep
*
imgRep
;
Lisp_Object
found
;
/* look for an existing image of the same name */
...
...
@@ -185,12 +186,18 @@ @implementation EmacsImage
image
=
[[
EmacsImage
alloc
]
initByReferencingFile
:
[
NSString
stringWithUTF8String
:
SDATA
(
found
)]];
if
([
image
bestRepresentationForDevice
:
nil
]
==
nil
)
imgRep
=
[
image
bestRepresentationForDevice
:
nil
];
if
(
imgRep
==
nil
)
{
[
image
release
];
return
nil
;
}
/* The next two lines cause the DPI of the image to be ignored.
This seems to be the behavior users expect. */
[
image
setScalesWhenResized
:
YES
];
[
image
setSize
:
NSMakeSize
([
imgRep
pixelsWide
],
[
imgRep
pixelsHigh
])];
[
image
setName
:
[
NSString
stringWithUTF8String
:
SDATA
(
file
)]];
[
image
reference
];
ImageList
=
[
image
imageListSetNext
:
ImageList
];
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment