From 940f0f60212f3481fec40b642ef6899bc4e47b5e Mon Sep 17 00:00:00 2001 From: Chris Waldon Date: Tue, 10 Jan 2023 12:17:38 -0500 Subject: [PATCH] widget: document MoveWord current limitations Signed-off-by: Chris Waldon --- widget/text.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/widget/text.go b/widget/text.go index 743b7a38..a5694c05 100644 --- a/widget/text.go +++ b/widget/text.go @@ -549,6 +549,10 @@ func (e *textView) MoveEnd(selAct selectionAction) { // MoveWord moves the caret to the next word in the specified direction. // Positive is forward, negative is backward. // Absolute values greater than one will skip that many words. +// BUG(whereswaldon): this method's definition of a "word" is currently +// whitespace-delimited. Languages that do not use whitespace to delimit +// words will experience counter-intuitive behavior when navigating by +// word. func (e *textView) MoveWord(distance int, selAct selectionAction) { // split the distance information into constituent parts to be // used independently.