Comments (6)
Sorry I forgot to mention: I think the docstring might need correcting anyway here:
textual/src/textual/document/_document_navigator.py
Lines 107 to 108 in e1749ac
from textual.
Thank you for your issue. Give us a little time to review it.
PS. You might want to check the FAQ if you haven't done so already.
This is an automated reply, generated by FAQtory
from textual.
It's not off by one - I should maybe clarify in the docs though. The end of the line is the maximum position in a line the cursor can rest on. Since you need to be able to move the cursor beyond the end of the text (otherwise inserting new text would be impossible), the "end of document line" is len(document_line)
. It's not "index of the last character".
from textual.
Thanks Darren for the explanation, I think clarifying this in the docs is a good idea.
from textual.
Closed as completed by #4151 (thanks Darren!)
from textual.
Don't forget to star the repository!
Follow @textualizeio for Textual updates.
from textual.
Related Issues (20)
- Malformed @click links crash Textual application HOT 2
- How to link from docs to videos? HOT 2
- Loading Indicator page could use docs about `loading` attribute HOT 1
- Ability to replace text while keeping TextArea history HOT 4
- NoMatches error occurring when changing screens quickly in version 0.49+ HOT 14
- Hidden ListItem in ListView is selected when navigating with keyboard
- `Switch.action_toggle` name clash HOT 1
- Input and TextArea have cursor blinking even though terminal window is not focused HOT 8
- Intermittently failing test (`test_pilot.py::test_pilot_target_on_widget_that_is_not_visible_errors`)
- Add indicators for the TabbedContent widget HOT 6
- Scrollbars may trap the mouse if hidden while the user is scrolling HOT 6
- TextArea CTRL-k behavior request HOT 7
- Try/except on all app
- Exception not being raised in tests HOT 4
- `DataTable` scrolling issues with `max-height: 100vh` HOT 4
- Include default CSS in docs? HOT 1
- Hiding a `TextArea` while mouse-based selection is happening can trap the cursor HOT 1
- Different behaviour between CSS and CSS_PATH of Screen HOT 6
- `Placeholder` has no `disabled` `__init__` keyword parameter HOT 5
- TextArea swallows lines after the Undo event HOT 24
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 textual.