For use in the GUI, we do not provide a "Select Sentence" action although we provide a "Select Word" and "Select Paragraph".
Other UNO actions for selections are based on current line position, or paragraph position--select to end of line, to start of line. Select to end of paragraph, to start of paragraph.
Currently the only means to select to "Sentence" runs is with a mouse button action--"triple click". Or to drag text cursor from start to end of sentence (error prone).
The missing, and lexicaly useful ICU lib based "Sentence" selection would complement the mouse controls supporting a keyboard shortcut/accelerator customization assignment.
Current mouse button actions are: double-click--select word; triple-click--select sentence; quadruple-click--select paragraph. Strange in that Word and Paragraph selection exist and can be assigned to keyboard customizations, not so for making a Sentence selection.
Isn't shift+<ctrl>+cursor sufficient?
(In reply to Heiko Tietze from comment #1)
> Isn't shift+<ctrl>+cursor sufficient?
No, it selects from current position in _word_ to end of word, and then expands at word bounds.
The only functional selection that directly uses _sentence_ boundaries is the L-MouseButton triple click (don't know if it is counting the ButtonDown or ButtonUp).
Looks like it is handled per module rather than globally. Here is the Writer handling of it:
While the triple-click in Impress/Draw Text Box object will select to the Paragraph boundaries. The double-click for Word selection, and the <Ctrl><Shift>+<Cursor> selections do seem the same in a Draw Text Box object.
Patch is here https://gerrit.libreoffice.org/#/c/70411, review pending.
However, I wonder if we not better take uno::SelectText (Select Text) instead of adding another command. "Select Text" toggles the selection cursor in read-only text (and occupies a shortcut!).
The summary is misleading asking for sentence selection while triple click is for the paragraph.
Triple click is selects at the Sentence boundaries (not sure if it is ICU lib driven), while Quadruple click selects at the Paragraph boundaries.
The UNO commands already existed for WORD and for PARAGRAPH, what is missing (and not addressed in the patch thusfar) is keyboard selection to SENTENCE boundaries.
Their selection now is only handled in the sw shell by capturing mouse clicks--see comment 3
Just saw patch set 2, implementing a "Select Sentence"--thanks...
heiko tietze committed a patch related to this issue.
It has been pushed to "master":
Resolves: tdf#124552 - Sentence selection UNO action
It will be available in 6.3.0.
The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
Affected users are encouraged to test the fix and report feedback.