Comments (4)
Im pretty sure that is the expected behaviour. Anyway, such things are handled by the system, not us.
from simple-notes.
I wouldn't call that expected behavior. If I'm inserting text & having a blinking "text" cursor, I'm expecting that my arrow keys do move the "text" cursor & not jump in between elements.
However, I found out the exact conditions the issue is appearing (tested with version 6.15.5):
- Enable "Make links and emails clickable" in the app settings
- Creating a note with a link for testing the issue
- Fully restart the app to ensure that said link is recognized as such
- Reopen the note & verify that arrow keys are working as expected (moving text cursor)
- Now long press anything to trigger Android's sub menu
- EDIT: It does not need to be the link which has to be selected, anything selecting works, making the app barely usable with this setting. However, the setting from point 1 needs to be enabled.
- Press anywhere in the text to give focus back to the input
- Now verify that the arrow keys (IMO falsely) do not move the text cursor but jump between/to the links
This is a screen record where I reproduce the issue:
_screencapture.mp4
I have no real experience in Android development specific, but to me it looks like the focus isn't correctly set to be only on the text input after the link was selected once. I cannot say if this might be an issue with the Android system, but this is the only app where I experience this. Anyway, I will keep my eyes open to find an app with a similar simple text UI & link recognizing to see if it experiences the same error.
from simple-notes.
that is all done by the system, not us.
from simple-notes.
Sorry, I value the huge work you put in this app, but I disagree with you. I've looked in-depth into the code & I found out the hotfix added in 1741070 is causing that, with "Make links and emails clickable" enabled, the fix you introduced in 696858e for #136 is reverted at runtime in the case I presented above.
Your fix for #136 wants to use MyMovementMethod
instead of LinkMovementMethod
with linksClickable=true
to solve it:
And it does in my case, after a fresh launch, the arrow keys work fine.
But when selecting a text, this hotfix comes in to solve an issue in Android <=6 Google "couldn't" fix by enabling ArrowKeyMovementMethod
when a selection is triggered to avoid a crash. It would eventually revert the hotfix when the text is deselected, but it reverts it to LinkMovementMethod
, ultimately reverting your work in 696858e at runtime:
So I concluded that changing line 257 to use MyMovementMethod
and not LinkMovementMethod
should fix the issue I have, and after testing I see that it does fix my issue. I've created PR #634 to propose this change.
Alternatively, or rather additionally, the hotfix may be guarded to be only applied on Android <=6 devices (like proposed here), to avoid further hassle with this workaround where it is not needed, as it feels kind of "hacky" and hopefully is only required on such old Android versions (However, that requires further testing with older devices at least I cannot do, that's why I didn't add this to my PR).
from simple-notes.
Related Issues (20)
- Launching via shortcut shouldn't open note picker
- Themes other than Black & White should have access to Accent color HOT 3
- Option to disable previews in the note picker menu HOT 1
- [Feature Request] button to delete all the text in the note HOT 1
- Open Note dialog (6.16.0+) missed the "has backup file" indicator
- Widget color transparency incorrect
- Checklist sharing not working properly HOT 2
- [Feature Request] Notebooks and password locking HOT 2
- Why arent on Note picker window cancel and add note buttons on left and right side? HOT 4
- "Show word count" is not quite useful for Chinese and Japanese HOT 2
- Checklist wrong long-press selection after sorting
- Open search bar prevents undo button showing up
- Ability to export to SimpleNotes out of other apps HOT 13
- [Feature Request] Automatically "Sort by: Move done checklist items to the bottom" when marking an item as done HOT 1
- [Feature Request] Reminder for notes HOT 1
- Lists’ “remove done items” should be a button in the toolbar. HOT 1
- [Bug] Wrong note is opened by clicking a widget HOT 1
- [Feature Request] Add alpha channel setting to widget's text
- Bug: Automatic backups don't appear to work. HOT 2
- Tabs bug with RTL languages HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from simple-notes.