false
Text selection changed All apps
false
TYPE_VIEW_TEXT_SELECTION_CHANGED
*
GLOB
*
false
false
from_index < to_index
from_index < to_index
false
from_index == to_index
from_index == to_index
// Some time it can't get the index so:
// from_index == to_index == 0
false
from_index > to_index
from_index > to_index
false
trigger == "Text selection changed All apps"
trigger == "Text selection changed All apps"
false
Notification on Screen:
{global_textselection}
{from_index}
{to_index} (long)
true
{global_textselection}
from_index = {from_index}
to_index = {to_index}
false
1.00
true
false
TOP_LEFT
0
0
true
Script: global_textselection = substring(text, from_index, to_index); // substring(s, start, end) // Returns the substring of the specified string.
true
Script: global_textselection = substring(text, to_index, from_index); // substring(s, start, end) // Returns the substring of the specified string.
true
Script: global_textselection = text;
Text selection changed
z Enabled Flows
false
STOP
6000
trigger == "Text selection changed All apps"
An example of checking which Trigger trigged the flow
Note: some flow have more than one Triggers
I also changed the default name of this block
from_index > to_index
You can change the option Package Name to another apps so this will trigger only in those apps
I changed the default name of this Trigger
If you select text then swipe from right to left:
from_index become larger than to_index
Duration set to long
You can set it to short
Test the result
Toast:
global_textselection
from_index
to_index
Script: global_textselection = substring(text, to_index, from_index); // substring(s, start, end) // Returns the substring of the specified string.
from_index < to_index
Notification on Screen:
{global_textselection}
{from_index}
{to_index} (long)
Script: global_textselection = text;
from_index == to_index
Script: global_textselection = substring(text, from_index, to_index); // substring(s, start, end) // Returns the substring of the specified string.
Text selection changed All apps