Bug 163427 - Can't set a hyperlink on a text box / drawing object
Summary: Can't set a hyperlink on a text box / drawing object
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: low normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Hyperlink
  Show dependency treegraph
 
Reported: 2024-10-14 12:22 UTC by Eyal Rozenberg
Modified: 2024-10-16 13:39 UTC (History)
2 users (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 Eyal Rozenberg 2024-10-14 12:22:53 UTC
I want to my rectangle, or textbox, object to follow a hyperlink when I click it. It is possible in LO to linkify a stretch of text, but not an object; let's add that capability.
Comment 1 Regina Henschel 2024-10-14 13:57:47 UTC
I have tested these cases:

Draw:
Insert shape "diamond". While it is selected press Ctrl+K to open hyperlink dialog. Enter the target URL. OK. Save the document.
Error:
The saved file is invalid ODF, because the xlink:show attribute has the wrong value "embed". It has to be "new" or "replace".
If I change the value in the file source to "new", the hyperlink on the shape works as expected.

Writer:
Insert shape "diamond". While it is selected press Ctrl+K to open hyperlink dialog. Enter the target URL. OK. Save the document.
Error:
The attribute xlink:show attribute is missing.
If I add the missing attribute in the file source, the hyperlink on the shape works as expected. Only the UI misses the pointing mouse cursor.

It looks as if the reasons why the hyperlink does not work is different for the modules and might be different for the type of shape. At least in the tested cases it would not be an enhancement, but a simple bug.

I will not split this bug report immediately. But I suggest, that who will fix the problems, should write a bug report for an individual problem and add a dependency here.

I think "needsUXEval" is not needed. Eyal, what do you want to get from UX?
Comment 2 Eyal Rozenberg 2024-10-15 22:44:58 UTC
(In reply to Regina Henschel from comment #1)
> I think "needsUXEval" is not needed. Eyal, what do you want to get from UX?

I didn't realize it was a bug, I thought it was intentionally unsupported. I asked for needsUXEvl to get an opinion about the clickability of the whole drawing object. It can't then be selected by simple clicking, only by forming a rectangle or using the tab key. Good idea? Bad idea?
Comment 3 Heiko Tietze 2024-10-16 12:07:32 UTC
(In reply to Regina Henschel from comment #1)
> The saved file is invalid ODF, because the xlink:show attribute
> ... 
> I think "needsUXEval" is not needed.

=> ordinary bug

I can assign a hyperlink to a shape in Impress and open the hyperlink on click. Don't see much need to have the same in other modules. => low priority
Comment 4 Eyal Rozenberg 2024-10-16 12:24:37 UTC
(In reply to Heiko Tietze from comment #3)
> I can assign a hyperlink to a shape in Impress

I don't see that on the context menu.

> and open the hyperlink on click.

Doesn't work for me. Nor does it work with Ctrl+Click.

> Don't see much need to have the same in other modules.

If we can linkify text in other modules, why not drawing objects with the same ease?
Comment 5 Heiko Tietze 2024-10-16 12:47:03 UTC
True, Writer can export to PDF and a hyperlink is a common element then.

But ctrl+K works also in Writer (or Inser > Hyperlink), and ctrl+click too. Now I'm confused what's not working as expected.
Comment 6 Eyal Rozenberg 2024-10-16 13:39:38 UTC
(In reply to Heiko Tietze from comment #5)
> But ctrl+K works also in Writer (or Inser > Hyperlink), and ctrl+click too.
>
> Now I'm confused what's not working as expected.

There is what Regina mentioned, at the output level.

From the user's perspective:

1. (Writer, Calc, Impress/Draw) If I right-click a drawing object, I should have the ability to set a hyperlink from it - either directly on the context menu or from one of the dialogs the menu directs me to. AFAICT, I don't have that in any LO module.

2. (Writer, Calc, Impress/Draw) If I hyperlink an object, e.g. with Ctrl+K, and then either click or Ctrl-click the object - the link is not followed.

3  (Writer, Calc, Impress/Draw; and probably should be a separate bug) If I hyperlink an object, e.g. with Ctrl+K - there is no visual indication of the object having a hyperlink; and AFAICT there is no way to configure LO so that such indication is made.