Re: [O] scale inline images in orgmode

2015-02-24 Thread Shavkat Rustamov
Hello,

This setting works fine:

(setq org-image-actual-width 300)

  = always resize inline images to 300 pixels

However, this does not {it falls back to 400 and ignores #+ATTR}:

(setq org-image-actual-width '(400))

  = if there is a #+ATTR.*: width=200, resize to 200,
 otherwise resize to 400

I tried different versions of #+ATTR, including:

##+ATTR.*: :width 150px
##+ATTR.*: width=100
##+ATTR_HTML: :width 300px
#+ATTR_HTML: :width=100

Any idea what’s wrong?


Re: [O] scale inline images in orgmode

2013-05-25 Thread Klaus-Dieter Bauer
Bastien bzg at altern.org writes:

 
 Hi Alexander,
 
 AW alexander.willand at t-online.de writes:
 
  If I include an image in an *.org file, let's say [[large-image.jpg]], I 
can 
  toggle the inline image with C-c C-x C-v .
 
 You can now (from git master) use `org-image-actual-width'.
 
 (setq org-image-actual-width 300)
   = always resize inline images to 300 pixels
 
 (setq org-image-actual-width '(400))
   = if there is a #+ATTR.*: width=200, resize to 200,
  otherwise resize to 400
 
 (setq org-image-actual-width nil)
   = if there is a #+ATTR.*: width=200, resize to 200,
  otherwise don't resize
 
 (setq org-image-actual-width t)
   = Never resize and use original width (the default)
 
 HTH,
 

Hello!

I am searching for a while now for a solution to get image scaling inside 
the org-mode buffer working /on Windows/. After installing GnuWin32 at least 
displaying the various image types works, but scaling does not. 

I assume the problem simply is missing ImageMagick-support in the Windows 
binaries. Any idea, how to get it? Or how to check whether emacs was 
compiled with ImageMagick support and just can't find DLLs on my system?

Note: I am also trying a while now to get emacs compiling from source, but 
there are so many problems popping up, that I barely see a chance to get 
this working.

I am using
  org-mode 8.0.3-15-g030e96-elpa 
  GNU Emacs 24.3.1 (i386-mingw-nt6.1.7601) of 2013-03-17 on MARVIN
  Windows 7 Home Premium, 64bit 

kind regards, Klaus




Re: [O] scale inline images in orgmode

2012-08-30 Thread Bastien
Hi Alexander,

AW alexander.will...@t-online.de writes:

 If I include an image in an *.org file, let's say [[large-image.jpg]], I can 
 toggle the inline image with C-c C-x C-v .

You can now (from git master) use `org-image-actual-width'.

(setq org-image-actual-width 300)
  = always resize inline images to 300 pixels

(setq org-image-actual-width '(400))
  = if there is a #+ATTR.*: width=200, resize to 200,
 otherwise resize to 400

(setq org-image-actual-width nil)
  = if there is a #+ATTR.*: width=200, resize to 200,
 otherwise don't resize

(setq org-image-actual-width t)
  = Never resize and use original width (the default)

HTH,

-- 
 Bastien



Re: [O] scale inline images in orgmode

2012-08-30 Thread AW
Am Donnerstag, 30. August 2012, 15:52:59 schrieb Bastien:
 Hi Alexander,
 
 AW alexander.will...@t-online.de writes:
  If I include an image in an *.org file, let's say [[large-image.jpg]], I
  can toggle the inline image with C-c C-x C-v .
 
 You can now (from git master) use `org-image-actual-width'.
 
 (setq org-image-actual-width 300)
   = always resize inline images to 300 pixels
 
 (setq org-image-actual-width '(400))
   = if there is a #+ATTR.*: width=200, resize to 200,
  otherwise resize to 400
 
 (setq org-image-actual-width nil)
   = if there is a #+ATTR.*: width=200, resize to 200,
  otherwise don't resize
 
 (setq org-image-actual-width t)
   = Never resize and use original width (the default)
 
 HTH,

Hi Bastien,

indeed, that helps a lot! Thank you very much. 

Kind regards,
Alexander



Re: [O] scale inline images in orgmode

2012-08-29 Thread Jeffrey Spencer
+1
On Aug 29, 2012 7:31 AM, Detlef Steuer detlef.ste...@gmx.de wrote:

 On Tue, 28 Aug 2012 15:34:59 -0500
 Russell Adams rlad...@adamsinfoserv.com wrote:

  On Tue, Aug 28, 2012 at 10:13:18PM +0200, AW wrote:
  
   I would like to scale the images on screen in the buffer, often I
 don't need a
   large picture, but just a reminder, what's on the picture. Is there a
 way to
   scale the image on screen, something like #+ATTR: scale=0.5 ?
 
  Alexander,
 
  I believe Org calls out to image.el via create-image. That doesn't
  appear to do any resizing.
 
  I read there may be compiled in Emacs support for Imagemagick, and I
  have existing elisp code that shells out to resize images for display
  separate from Org via Imagemagick's convert utility.
 
  To Org devs, would it be difficult to add a wrapper around the
  create-image call that only resizes if the image will exceed certain
  dimensions (ie: window width or 75% of height?).
 
  This is a feature I'd love to see.


 +1
 Detlef

 
  Thanks.
 
 
  --
  Russell Adamsrlad...@adamsinfoserv.com
 
  PGP Key ID: 0x1160DCB3   http://www.adamsinfoserv.com/
 
  Fingerprint:1723 D8CA 4280 1EC9 557F  66E8 1154 E018 1160 DCB3
 
 






[O] scale inline images in orgmode

2012-08-28 Thread AW
Hi!

If I include an image in an *.org file, let's say [[large-image.jpg]], I can 
toggle the inline image with C-c C-x C-v .

I would like to scale the images on screen in the buffer, often I don't need a 
large picture, but just a reminder, what's on the picture. Is there a way to 
scale the image on screen, something like #+ATTR: scale=0.5 ?

Regards,

Alexander



Re: [O] scale inline images in orgmode

2012-08-28 Thread Russell Adams
On Tue, Aug 28, 2012 at 10:13:18PM +0200, AW wrote:

 I would like to scale the images on screen in the buffer, often I don't need a
 large picture, but just a reminder, what's on the picture. Is there a way to
 scale the image on screen, something like #+ATTR: scale=0.5 ?

Alexander,

I believe Org calls out to image.el via create-image. That doesn't
appear to do any resizing.

I read there may be compiled in Emacs support for Imagemagick, and I
have existing elisp code that shells out to resize images for display
separate from Org via Imagemagick's convert utility.

To Org devs, would it be difficult to add a wrapper around the
create-image call that only resizes if the image will exceed certain
dimensions (ie: window width or 75% of height?).

This is a feature I'd love to see.

Thanks.


--
Russell Adamsrlad...@adamsinfoserv.com

PGP Key ID: 0x1160DCB3   http://www.adamsinfoserv.com/

Fingerprint:1723 D8CA 4280 1EC9 557F  66E8 1154 E018 1160 DCB3



Re: [O] scale inline images in orgmode

2012-08-28 Thread Detlef Steuer
On Tue, 28 Aug 2012 15:34:59 -0500
Russell Adams rlad...@adamsinfoserv.com wrote:

 On Tue, Aug 28, 2012 at 10:13:18PM +0200, AW wrote:
 
  I would like to scale the images on screen in the buffer, often I don't 
  need a
  large picture, but just a reminder, what's on the picture. Is there a way to
  scale the image on screen, something like #+ATTR: scale=0.5 ?
 
 Alexander,
 
 I believe Org calls out to image.el via create-image. That doesn't
 appear to do any resizing.
 
 I read there may be compiled in Emacs support for Imagemagick, and I
 have existing elisp code that shells out to resize images for display
 separate from Org via Imagemagick's convert utility.
 
 To Org devs, would it be difficult to add a wrapper around the
 create-image call that only resizes if the image will exceed certain
 dimensions (ie: window width or 75% of height?).
 
 This is a feature I'd love to see.


+1
Detlef

 
 Thanks.
 
 
 --
 Russell Adamsrlad...@adamsinfoserv.com
 
 PGP Key ID: 0x1160DCB3   http://www.adamsinfoserv.com/
 
 Fingerprint:1723 D8CA 4280 1EC9 557F  66E8 1154 E018 1160 DCB3