all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* create-image on console emacs
@ 2010-05-06 19:56 Gary
  2010-05-06 20:18 ` Lennart Borgman
       [not found] ` <mailman.11.1273177123.30155.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 5+ messages in thread
From: Gary @ 2010-05-06 19:56 UTC (permalink / raw)
  To: Help-gnu-emacs

Can anyone explain to me why If I use emacs in the console and call
create-image I get a message like "Non-X frame used" (whether I use an
X11 binary or non-X)? I don't get this at all.

The reason I ask is that I am trying to use the code from
http://xahlee.org/emacs/emacs_html.html (*waves*) and as I said to Xah
Lee off-list, while it may well be necessary to (for example) get an
image's dimensions in order to display an image, the reverse is not
true. Other console tools are able to do it fine, for example
ImageMagick can tell me the dimensions from the command line:

$ identify work/web1/Bilder/aussen.jpg
work/web1/Bilder/aussen.jpg JPEG 874x583 874x583+0+0 DirectClass 8-bit
58.75kb

X doesn't need to get involved until such time things actually (try to)
get displayed.
g
-- 
Gary




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: create-image on console emacs
  2010-05-06 19:56 create-image on console emacs Gary
@ 2010-05-06 20:18 ` Lennart Borgman
  2010-05-06 22:05   ` Kevin Rodgers
       [not found] ` <mailman.11.1273177123.30155.help-gnu-emacs@gnu.org>
  1 sibling, 1 reply; 5+ messages in thread
From: Lennart Borgman @ 2010-05-06 20:18 UTC (permalink / raw)
  To: Help-gnu-emacs

On Thu, May 6, 2010 at 9:56 PM, Gary <help-gnu-emacs@garydjones.name> wrote:
> Can anyone explain to me why If I use emacs in the console and call
> create-image I get a message like "Non-X frame used" (whether I use an
> X11 binary or non-X)? I don't get this at all.
>
> The reason I ask is that I am trying to use the code from
> http://xahlee.org/emacs/emacs_html.html (*waves*) and as I said to Xah
> Lee off-list, while it may well be necessary to (for example) get an
> image's dimensions in order to display an image, the reverse is not
> true. Other console tools are able to do it fine, for example
> ImageMagick can tell me the dimensions from the command line:
>
> $ identify work/web1/Bilder/aussen.jpg
> work/web1/Bilder/aussen.jpg JPEG 874x583 874x583+0+0 DirectClass 8-bit
> 58.75kb
>
> X doesn't need to get involved until such time things actually (try to)
> get displayed.

I tested this starting from "emacs -nw":

  (setq x (create-image "c:/my-image.jpg"))
  (setq s (image-size x t))

create-image works, but image-size fails.with "Non-W32 frame used".

It looks like the reason is that internally images are in some way
bound to frames. I do not know the reason for this, but you can see it
in the code of `image-size'.

Maybe it is a bug. Please submit a bug report.




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: create-image on console emacs
  2010-05-06 20:18 ` Lennart Borgman
@ 2010-05-06 22:05   ` Kevin Rodgers
  2010-05-06 22:21     ` Lennart Borgman
  0 siblings, 1 reply; 5+ messages in thread
From: Kevin Rodgers @ 2010-05-06 22:05 UTC (permalink / raw)
  To: help-gnu-emacs

Lennart Borgman wrote:
> On Thu, May 6, 2010 at 9:56 PM, Gary <help-gnu-emacs@garydjones.name> wrote:
>> Can anyone explain to me why If I use emacs in the console and call
>> create-image I get a message like "Non-X frame used" (whether I use an
>> X11 binary or non-X)? I don't get this at all.
>>
>> The reason I ask is that I am trying to use the code from
>> http://xahlee.org/emacs/emacs_html.html (*waves*) and as I said to Xah
>> Lee off-list, while it may well be necessary to (for example) get an
>> image's dimensions in order to display an image, the reverse is not
>> true. Other console tools are able to do it fine, for example
>> ImageMagick can tell me the dimensions from the command line:
>>
>> $ identify work/web1/Bilder/aussen.jpg
>> work/web1/Bilder/aussen.jpg JPEG 874x583 874x583+0+0 DirectClass 8-bit
>> 58.75kb
>>
>> X doesn't need to get involved until such time things actually (try to)
>> get displayed.
> 
> I tested this starting from "emacs -nw":
> 
>   (setq x (create-image "c:/my-image.jpg"))
>   (setq s (image-size x t))
> 
> create-image works, but image-size fails.with "Non-W32 frame used".
> 
> It looks like the reason is that internally images are in some way
> bound to frames. I do not know the reason for this, but you can see it
> in the code of `image-size'.
> 
> Maybe it is a bug. Please submit a bug report.

Just a guess: the size of the image depends on the resolution of the
display system.

-- 
Kevin Rodgers
Denver, Colorado, USA





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: create-image on console emacs
  2010-05-06 22:05   ` Kevin Rodgers
@ 2010-05-06 22:21     ` Lennart Borgman
  0 siblings, 0 replies; 5+ messages in thread
From: Lennart Borgman @ 2010-05-06 22:21 UTC (permalink / raw)
  To: Kevin Rodgers; +Cc: help-gnu-emacs

On Fri, May 7, 2010 at 12:05 AM, Kevin Rodgers
<kevin.d.rodgers@gmail.com> wrote:
>>
>> I tested this starting from "emacs -nw":
>>
>>  (setq x (create-image "c:/my-image.jpg"))
>>  (setq s (image-size x t))
>>
>> create-image works, but image-size fails.with "Non-W32 frame used".
>>
>> It looks like the reason is that internally images are in some way
>> bound to frames. I do not know the reason for this, but you can see it
>> in the code of `image-size'.
>>
>> Maybe it is a bug. Please submit a bug report.
>
> Just a guess: the size of the image depends on the resolution of the
> display system.


Maybe, I have never understood image sizes. I thought that perhaps the
pixel size was independent of the display.




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: create-image on console emacs
       [not found] ` <mailman.11.1273177123.30155.help-gnu-emacs@gnu.org>
@ 2010-05-07  2:53   ` Stefan Monnier
  0 siblings, 0 replies; 5+ messages in thread
From: Stefan Monnier @ 2010-05-07  2:53 UTC (permalink / raw)
  To: help-gnu-emacs

> It looks like the reason is that internally images are in some way
> bound to frames. I do not know the reason for this, but you can see it
> in the code of `image-size'.
> Maybe it is a bug. Please submit a bug report.

Yes, it's a misfeature, indeed.
The implementation of image handling is linked to the particular kinds
of terminal supported since part of that code is related to displaying
the images.


        Stefan


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-05-07  2:53 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-06 19:56 create-image on console emacs Gary
2010-05-06 20:18 ` Lennart Borgman
2010-05-06 22:05   ` Kevin Rodgers
2010-05-06 22:21     ` Lennart Borgman
     [not found] ` <mailman.11.1273177123.30155.help-gnu-emacs@gnu.org>
2010-05-07  2:53   ` Stefan Monnier

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.