Bug 141507 - Insert > Media > Scan > Select Source not working in macOS and Ubuntu
Summary: Insert > Media > Scan > Select Source not working in macOS and Ubuntu
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
6.4.6.2 release
Hardware: All macOS (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 165353 (view as bug list)
Depends on:
Blocks: macOS-UI-polish
  Show dependency treegraph
 
Reported: 2021-04-06 08:12 UTC by PeeWee
Modified: 2025-02-24 09:37 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description PeeWee 2021-04-06 08:12:57 UTC
LibreOffice 7.0.5 running on macOS 11.2.3 Big Sur.
LibreOffice 7.1.1 running on macOS 10.16.7 Catalina.
Go to Insert > Media > Scan > Select Source — no select source dialog opens and cannot insert media from a scan.

LibreOffice 7.1.1 running on Ubuntu 20.04.
Go to Insert > Media > Scan > Select Source — Scanner dialog opens.
In Device used no options available to select a scanner. Cannot select or use any of the other options available in the Scanner dialog.
Cannot insert media from a scan.

LibreOffice 7.1.1 running on Windows 10 Home edition.
Go to Insert > Media > Scan > Select Source — Select Source dialog opens.
Media can be scanned and inserted into a LibreOffice file as an image.
Comment 1 steve 2021-04-07 07:50:29 UTC
Confirmed → NEW
Writer > Insert > Media > Scan > Select Source does nothing.

Version: 7.2.0.0.alpha0+ / LibreOffice Community
Build ID: d0b4719ca3d4608bcb7431dbeb097146dd5a5127
CPU threads: 8; OS: Mac OS X 10.16 (11.2.3); UI render: default; VCL: osx
Locale: de-DE (de_DE.UTF-8); UI: en-US
Calc: threaded
Comment 2 Alex Thurgood 2021-04-08 18:38:40 UTC
It was already broken in 

Version : 6.4.6.1
Build ID : 985dd72ca280d5c6da2e9f90f7ff9286cafe7ff8
Threads CPU : 8; OS : Mac OS X 10.16; UI Render : par défaut; VCL: osx; 
Locale : fr-FR (fr_FR.UTF-8); Langue IHM : fr-FR
Calc: threaded
Comment 3 QA Administrators 2024-09-04 03:15:00 UTC Comment hidden (obsolete)
Comment 4 Alex Thurgood 2025-02-21 09:28:55 UTC
*** Bug 165353 has been marked as a duplicate of this bug. ***
Comment 5 Alex Thurgood 2025-02-21 09:29:55 UTC
The bug is still present.

Version: 24.8.3.2 (AARCH64) / LibreOffice Community
Build ID: 48a6bac9e7e268aeb4c3483fcf825c94556d9f92
CPU threads: 8; OS: macOS 15.3.1; UI render: Skia/Raster; VCL: osx
Locale: fr-FR (fr_FR.UTF-8); UI: fr-FR
Calc: threaded
Comment 6 Alex Thurgood 2025-02-21 10:00:01 UTC
This functionality is implemented in the Apple provided Preview.app, so it must presumably be possible.

In Preview.app, you can acquire an image directly from a scanner via:

File > Import from {name of available scanner}


That being said, Word for Mac doesn't appear to have this possibility under the corresponding Insert menu, in which the various choices are :

- via local photo library browser
- from file directory
- from MS' own photo library browser
- from online image repository


So, the question is:

- remove the menu entry and disable the functionality altogether, because it doesn't currently work, if it ever did (I don't remember) and there is a system alternative available which requires the user to go through Preview.app, or else directly use the scanner app to scan and save an image somewhere in the file system; or

- implement the functionality in a manner similar to what Preview.app does ?


From a coding perspective, I'm going to guess that it would be easier to remove the menu entries altogether rather than implement (and maintain) the code to enable it ?
Comment 7 Patrick (volunteer) 2025-02-22 14:30:56 UTC
(In reply to Alex Thurgood from comment #6)
> From a coding perspective, I'm going to guess that it would be easier to
> remove the menu entries altogether rather than implement (and maintain) the
> code to enable it ?

Don't know how people scan on Linux. But macOS has the bundled Image Capture application for scanning so I would vote for removing the Scan menu.

I don't know how to remove a menu item for only one platform in LibreOffice's menubar.xml files so one other possibility is to disable all of Scan menu items. I see that those menu items have the following UNO IDs assigned to them so maybe I could hardcode something down in the vcl layer to just disable any native menu items that have the following UNO IDs: 

  <menu:menuitem menu:id=".uno:TwainSelect"/>
  <menu:menuitem menu:id=".uno:TwainTransfer"/>
Comment 8 Patrick (volunteer) 2025-02-22 15:17:28 UTC
(In reply to Patrick (volunteer) from comment #7)
> of Scan menu items. I see that those menu items have the following UNO IDs
> assigned to them so maybe I could hardcode something down in the vcl layer
> to just disable any native menu items that have the following UNO IDs: 
> 
>   <menu:menuitem menu:id=".uno:TwainSelect"/>
>   <menu:menuitem menu:id=".uno:TwainTransfer"/>

Unfortunately, hacking the above into vcl won't work as I found that these UNO IDs are also in toolbar buttons as well so disabling the menu items and toolbar buttons would likely need to happen in the Writer, Impress, etc. code. I am pretty lost in that code but IIRC each type of LibreOffice module has its own code to handle those menu items.
Comment 9 PeeWee 2025-02-24 09:37:13 UTC
Having carried out tests on new and old scanners, I suggest that any programming for scanning is removed from LibreOffice. Using scanning software that comes with a scanner is easy to use and importing any scanned images or text files into LibreOffice is very easy to do.

I have done some scanner testing using new and old scanners. It was very easy to scan images/text and import into LibreOffice.