Bug 114122 - Double click in special character dialog inserts a character into the document, even when the dialog is only opened to select a single character
Summary: Double click in special character dialog inserts a character into the documen...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
6.1.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: kurtaazz
URL:
Whiteboard: target:6.1.0
Keywords: difficultyBeginner, easyHack, skillCpp, topicUI
Depends on:
Blocks:
 
Reported: 2017-11-28 18:55 UTC by Tamás Zolnai
Modified: 2017-12-11 22:19 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 Tamás Zolnai 2017-11-28 18:55:02 UTC
Description:
Special character dialog has two useages. First one when you open it directly (conext menu -> Special Character or Insert -> Special character). In this case its functional to insert character by double click in the character list, so you can insert more character before you close the dialog. The second usage when the dialog is opened from an other dialog and is opened for selecting one single character which is used by the other dialog and not actually inserted into the docuemnt (e.g. Bullets and Numbering -> Customize -> Select... (select custom bullet)). In this case the dialog should not insert any character into the document.

Steps to Reproduce:
1. Open Impress
2. Open Bullets and numbering -> Customize tab
3. Push Select... button to open Special character dialog
4. Select a character from favorite or recent character by double click

Actual Results:  
The character is inserted into the document by double click.

Expected Results:
No character should be inserted into the document. See how it works if you select a character from the main character selector item.


Reproducible: Always


User Profile Reset: No



Additional Info:


User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36
Comment 1 Tamás Zolnai 2017-11-28 18:56:40 UTC
Let's turn this into a easy hack. The code is here:
cui/source/dialogs/cuicharmap.cxx
sfx2/source/control/charwin.cxx

Check InsertCharToDoc() method in both file, this is a good debug point to see how this insertion works.
Comment 2 Commit Notification 2017-12-06 21:13:53 UTC
Mark Vecsernyes committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=37c719d92b8645aef68925c2dab669a4d1d83e85

tdf#114122 - Double click in special character dialog inserts a character

It will be available in 6.1.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.