-
-
Notifications
You must be signed in to change notification settings - Fork 537
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TextArea #447
TextArea #447
Conversation
if unicode.IsLetter(r) || | ||
unicode.IsNumber(r) || | ||
unicode.IsMark(r) || | ||
unicode.IsSpace(r) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This filtering is too strict - it blocks user from entering any special characters, eg !"£$%^&*(){}~@:<>? and more. I think it could be reduced to just "unicode.IsGraphic", so that it only blocks control sequences.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with you.
@Konstantin8105 Given the pace at which reviews go in this repo, I'd suggest you move this widget to your own staond-alone repo under your control so we can begin using this and you can get PRs for improvements. I did this with my widget, winman so it would be available immediately to everybody. |
@jpeletier In according to LICENSE, you can merge that widget in your project without any link on myself. Feel free to coping, using, and ... |
@Konstantin8105 Yes, thank you for a permisive license, but I would like to avoid copying your code if I can better link to it and everyone shares the same to improve it together. This repo is quite "slow". If you keep this in your repo, we can probably evolve your TextArea widget faster together. |
This is actually a very very useful addition. Is there any reason it cannot be merged into master. Just trying to get a picture on timeline as this is also what I need. |
watching this one as well... |
This is very useful! |
Also waiting for merge of this PR. |
I have been waiting for this future to start a personal project. So I appreciate it if it can be merged asap. |
I know this will be disappointing to some of you but it's unlikely I will merge this PR. There are a whole bunch of reasons but the two major reasons are: I don't think Please fill out #578, |
f.view.lineOffset += diff | ||
} | ||
if f.cursor.y < y { | ||
diff := -((lastIndexLine - indexLine) - lastCy) - 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As best I can tell 'lastCy' shouldn't be involved in this calculation at all. When the textarea fills the screen lastCy will be zero when we hit the top of the screen and need to scroll earlier lines into view. When the textarea is offset from the top of the screen though, lastCy will be non-zero and this will cause diff
to get ridiculous values. As a result lineOffset gets set to incorrect values and all your text disappears off the textarea display. Removing 'lastCy' from this calc made scrolling work as expected.
|
Create for #64
demos
sourceTextView
Form
interface