Questions tagged [textselection]

In User Interface Design, text selection is the method of handpicking a portion of text, most commonly for the purpose of copying/cutting/pasting.

In User Interface Design, text selection is the method of handpicking a portion of text that will be further acted upon by the user. The selection is done by the interaction devices provided by the user interface.

Text selection is most commonly associated with the user actions of copying, cutting, and pasting. In Graphical User Interface, text selection is performed by a mouse or touch represented as cursors.

459 questions
0
votes
1 answer

Android Studio TextView Text Selection Handler Icon Position

Click here to see screen shot I want to set position of this custom right and left handlers aligned text top.Can you help me with that
0
votes
1 answer

Problems with selecting entire text in VS.Code

You may know that when you select your code by default in the VS-Code, the cursor itself selects anything since you stay in the same column of a "code's paragraph". However, this is not the case, some time ago I installed VIM extension and since…
0
votes
0 answers

Wrong functionality with Textselection in Flutter

i recognized a strange thing. When i have 4 digits in an input field and I delete the last digit, the cursor should then be on the third position (|1|2|3|), i.e. after the third digit, I count with 0. I check this with Flutter with Textselection and…
Peter
  • 87
  • 1
  • 6
0
votes
2 answers

tkinter seems to have changed its default style for showing selected text

I've just rebuilt my linux desktop, now Mint 20.1 Mate. I have python 3.8.5, and Tk 8.6. Unfortunately I don't know for certain what version of Tk I was using last week, I'm sure it's been 8.6 for a long time, but was using Mint 20.1 xcfe with…
Neil_UK
  • 1,043
  • 12
  • 25
0
votes
1 answer

Cannot select just written word after a white space by selection api

i'm learned selection api soon and i cannot found a real tutorial who is explain everything about it i checked the MDN tutorial but there's just examples about properties of window.getSelection() object but there's something like…
Mahmoud Y3c
  • 94
  • 1
  • 9
0
votes
0 answers

How can one extract selected text with a context menu

This is the first mechanism my chrome extension needs to perform, and I am unable to find a way to do this. I've tried using the window.getSelection().toString() / document.getSelection().toString() method, but I can only get it to work on a…
0
votes
1 answer

What happened when dragging on a text selection?

When I press and move the mouse on a text selection in the browser, the default behavior is to drag the selected text? How does it work? Can I add an event listener on the document.getSelection() or something like that, if I want to change the…
Yuchu Luo
  • 1
  • 1
0
votes
1 answer

Get the selected string with position from textarea although it exists multiple times

function addURL(e) { var n = document.selection ? document.selection.createRange().text : e.value.substring(e.selectionStart, e.selectionEnd); var a = n + '[link]'; e.value = e.value.replace(n, a); }
David
  • 2,898
  • 3
  • 21
  • 57
0
votes
0 answers

How can create a Selection in the browser in JavaScript?

The Selection API allows me to get the current selection with window.getSelection() and edit the selection with selection.modify('extend', 'backward', 'character'); to, for example, go back a character. But how can I actually select text with the…
mikemaccana
  • 110,530
  • 99
  • 389
  • 494
0
votes
1 answer

Using Regex selecting text match everything after a word or patterns (similar topic but text is not fix patterns except 1 character)

I am trying to use Regex in notepad++ to select everything after v+(number|character)* but in the selection it should excluded the v+(num|char)*. e.g. master\_\move_consolidate_archives_html_to_move_base_v2kjkj_(2021_01_19_11h43m59s-fi_m_dt xx-) -…
0
votes
2 answers

Flutter webview text selection handle color

We have a text editing functionality in which we load HTML page in an Flutter Web-view. The long press on text opens text selection handles,However i want to change the selection handle turquoise color(that two bubbles before and after text…
0
votes
1 answer

How to get index of char as coordinate in a text Javascript

I want to get the index of char in text at coordinates. My current approach is to simulate selection. I was able to simulate a click at coordinates with the following code, but this simulated click does not trigger selection (setting…
0
votes
1 answer

Determine textNode at character number of paragraph ancestor

Let's say we have the following HTML:

12345678.

Let's say that if we wanted to consider '234' a selection it's relative index to the p parent element would be 1-3 (using 0 as starting index). How do I determine what node…
John
  • 1
  • 13
  • 98
  • 177
0
votes
1 answer

Getting list of elements in a Selection() object

Given HTML like:

Hey everyone I have a question for you.

and a selection from "everyone" to "have", I can get a Selection object by: function…
Lumen
  • 139
  • 11
0
votes
2 answers

Getting a list of elements contained in user-selected text on a webpage

Given a page like this:

Here's some text that the user could select.

If a user selects the whole sentence (from "Here's" to "select."), I want to return "1" and…
Lumen
  • 139
  • 11