Re: feature request: easy embedding of images

2023-03-24 Thread Ihor Radchenko
Alexis Gallagher  writes:

>   •   you can still scroll the window one line height unit at a time, 
> without the entire image being scrolled as if it were one giant line, 
> breaking scrolling, as seems to happen on my emacs (version 28.x on Linux)

Emacs will actually scroll partially when the image is taller than
window height. But not otherwise.
Changing this is not trivial.
See https://debbugs.gnu.org/cgi/bugreport.cgi?bug=62048#17

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: feature request: easy embedding of images

2023-02-21 Thread Daniel Fleischer
Jude DaShiell [2023-02-20 Mon 16:24] wrote:

> To help accessibility it would be useful when an image was dragged into
> org-mode if the user got prompted for an image description that gets
> associated with the image in org-mode.  Some images are art work and those
> should get alt="" tags if a user fails to provide a description but only
> after asking if this image is art work or something that needs a
> description.  If a description is provided that should go between the
> quotes in the alt="" tag.

In org-download you can specify html attributes for the attached image,
see link

https://github.com/abo-abo/org-download/blob/master/org-download.el#L178-L184

It's not a prompt, it's a template and you can fill the alt description.

-- 
Daniel Fleischer



Re: feature request: easy embedding of images

2023-02-20 Thread Jude DaShiell
To help accessibility it would be useful when an image was dragged into
org-mode if the user got prompted for an image description that gets
associated with the image in org-mode.  Some images are art work and those
should get alt="" tags if a user fails to provide a description but only
after asking if this image is art work or something that needs a
description.  If a description is provided that should go between the
quotes in the alt="" tag.



Jude  "There are four boxes to be used in
defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)

.

On Mon, 20 Feb 2023, Russell Adams wrote:

> On Sat, Feb 18, 2023 at 04:22:33PM -0800, Alexis Gallagher wrote:
> > Hello, my fellow org-mode lovers,
> >
> > This is a feature request ? or failing that, a request for advice on
> > a settings configuration which could produce this functionality now.
>
> Have you looked at org-attach-screenshot?
>
> https://github.com/dfeich/org-screenshot
>
> It uses org-attach and calls out to take a screenshot.
>
> I do the same with some local function's I wrote a while ago. It works
> very well for me. I run M-x my/org-screenshot, and after 3 seconds it
> will use Imagemagick's "import" command to allow me to select a region
> to screenshot and saves it to a filename I prepared.
>
> I do this daily, many times each day.
>
> > I wish org-mode had the ability to attach images to notes, display
> > them inline, and have that work well. By ?work well? I mean a few
> > specific things:
> >
> > ?   the image is automatically resized to maintain aspect ratio and
> > ?   fit horizontally with a civilized margin, so that I can resize
> > ?   my emacs window without the image disappearing or swamping the
> > ?   other content.
>
> This is Emacs, not Org. Perhaps someone knows how to adjust that.
>
> > ?   you can still scroll the window one line height unit at a time,
> > ?   without the entire image being scrolled as if it were one giant
> > ?   line, breaking scrolling, as seems to happen on my emacs
> > ?   (version 28.x on Linux)
>
> Mine jumps too, but again that's Emacs, not Org.
>
> > ?   drag and drop, so I can add the image by dragging it in, for
> > ?   instance from a screenshot tool or from an image on a web page.
>
> I can't answer that. Drag and drop functions depend on your
> platform. Does anything else in Emacs use drag and drop?
>
> > ?   sensible defaults for storing the images bundled with notes and
> > ?   keeping the two associated, so that I don't subsequently live in
> > ?   fear of ever moving my org files
>
> I do save all of mine to the same directory as my org file in
> .org/Filename.org.screenshotMMDDHHMMSS.png. It means I can easily
> know what files below to my org document.
>
> > Why is this valuable, to me at least? I use org to take notes all
> > day, during meetings, on reading matter, in the development of my
> > own thoughts. Embedding images would let me collect every kind of
> > resource I can't reproduce by typing or copy and pasting text ?
> > photos of slides during presentations, photos of whiteboard, key
> > snippets from websites, handwritten notes and equations, etc..
>
> Of course it's valuable, and already implemented. I think you're
> asking more about refining how you use it.
>
> --
> Russell Adamsrlad...@adamsinfoserv.com
> https://www.adamsinfoserv.com/
>
>



Re: feature request: easy embedding of images

2023-02-20 Thread Daniel Fleischer
Alexis Gallagher [2023-02-18 Sat 16:22] wrote:

> This is a feature request — or failing that, a request for advice on a 
> settings configuration which could produce this
> functionality now. 

Russell mentioned a package and pointed to the image issues related to
Emacs, not Org.

I want to suggest the package https://github.com/abo-abo/org-download
which I use all time, for dragging and dropping images and for taking
screeshots. 

-- 
Daniel Fleischer



Re: feature request: easy embedding of images

2023-02-20 Thread Russell Adams
On Sat, Feb 18, 2023 at 04:22:33PM -0800, Alexis Gallagher wrote:
> Hello, my fellow org-mode lovers,
>
> This is a feature request — or failing that, a request for advice on
> a settings configuration which could produce this functionality now.

Have you looked at org-attach-screenshot?

https://github.com/dfeich/org-screenshot

It uses org-attach and calls out to take a screenshot.

I do the same with some local function's I wrote a while ago. It works
very well for me. I run M-x my/org-screenshot, and after 3 seconds it
will use Imagemagick's "import" command to allow me to select a region
to screenshot and saves it to a filename I prepared.

I do this daily, many times each day.

> I wish org-mode had the ability to attach images to notes, display
> them inline, and have that work well. By “work well” I mean a few
> specific things:
>
>   •   the image is automatically resized to maintain aspect ratio and
>   •   fit horizontally with a civilized margin, so that I can resize
>   •   my emacs window without the image disappearing or swamping the
>   •   other content.

This is Emacs, not Org. Perhaps someone knows how to adjust that.

>   •   you can still scroll the window one line height unit at a time,
>   •   without the entire image being scrolled as if it were one giant
>   •   line, breaking scrolling, as seems to happen on my emacs
>   •   (version 28.x on Linux)

Mine jumps too, but again that's Emacs, not Org.

>   •   drag and drop, so I can add the image by dragging it in, for
>   •   instance from a screenshot tool or from an image on a web page.

I can't answer that. Drag and drop functions depend on your
platform. Does anything else in Emacs use drag and drop?

>   •   sensible defaults for storing the images bundled with notes and
>   •   keeping the two associated, so that I don't subsequently live in
>   •   fear of ever moving my org files

I do save all of mine to the same directory as my org file in
.org/Filename.org.screenshotMMDDHHMMSS.png. It means I can easily
know what files below to my org document.

> Why is this valuable, to me at least? I use org to take notes all
> day, during meetings, on reading matter, in the development of my
> own thoughts. Embedding images would let me collect every kind of
> resource I can't reproduce by typing or copy and pasting text —
> photos of slides during presentations, photos of whiteboard, key
> snippets from websites, handwritten notes and equations, etc..

Of course it's valuable, and already implemented. I think you're
asking more about refining how you use it.

--
Russell Adamsrlad...@adamsinfoserv.com
https://www.adamsinfoserv.com/