View Issue Details

IDProjectCategoryView StatusLast Update
0020890LazarusLCLpublic2020-03-25 10:25
ReporterFredAssigned ToZeljan Rikalo 
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version0.9.30.3 (SVN)Product Build 
Target VersionFixed in Version 
Summary0020890: Wrong usage of SelStart and SelLength in OnChange event
DescriptionTry to put this code into OnChange:

Edit1.Text := 'ABCDEF';
Edit1.SelStart := 1;
Edit1.SelLength := Length (Edit1.Text);

and after firing OnChange event nothing is selected.
Additional InformationThis happens on Linux only. Tested on Carbon and it is OK there.

Lazarus Rev. 33088
TagsNo tags attached.
Fixed in Revision36086
LazTarget-
WidgetsetGTK 2
Attached Files

Relationships

related to 0007243 closedZeljan Rikalo TEdit SelStart behaves different (incorrectly) under linux 
related to 0023219 closedZeljan Rikalo TEdit component loses SelStart and SelLength values 
related to 0024371 resolvedJuha Manninen Wrong usage of SelStart and SelLength in OnChange event only the first time 
related to 0034678 feedbackJuha Manninen TMaskEdit sometimes skips characters 

Activities

Zeljan Rikalo

2011-12-12 17:59

developer   ~0054996

Last edited: 2011-12-12 17:59

What linux distribution, what version also what gtk2 version ?
Also, please attach example.

2011-12-12 21:27

 

selection.zip (128,579 bytes)

Fred

2011-12-12 21:29

reporter   ~0055000

I have tested it on Ubuntu 10.04 and OpenSUSE 11.4 and the behavior is the same.

Use my test app where it selects the text from second character after every change. You can see, that the selection is not visible and it tries to put new char to second position.

Bart Broersma

2011-12-13 12:46

developer   ~0055008

Probably related to 0007243.

Zeljan Rikalo

2011-12-13 13:05

developer   ~0055009

@Bart, I don't think so 0007243 is still opened just because I didn't find way howto fix it for gtk 2.8.

Fred

2011-12-15 16:33

reporter   ~0055059

OK, I have made a temporary solution to get working what I needed, but this is a quite big bug.

Zeljan Rikalo

2012-02-17 16:26

developer   ~0056887

And probably never will be fixed.

Zeljan Rikalo

2012-03-16 12:27

developer   ~0057714

Please test and close if ok.

Issue History

Date Modified Username Field Change
2011-12-12 17:19 Fred New Issue
2011-12-12 17:19 Fred Widgetset => GTK 2
2011-12-12 17:59 Zeljan Rikalo LazTarget => -
2011-12-12 17:59 Zeljan Rikalo Note Added: 0054996
2011-12-12 17:59 Zeljan Rikalo Status new => feedback
2011-12-12 17:59 Zeljan Rikalo Note Edited: 0054996
2011-12-12 21:27 Fred File Added: selection.zip
2011-12-12 21:29 Fred Note Added: 0055000
2011-12-13 12:46 Bart Broersma Note Added: 0055008
2011-12-13 13:05 Zeljan Rikalo Note Added: 0055009
2011-12-15 16:33 Fred Note Added: 0055059
2012-02-17 16:26 Zeljan Rikalo Note Added: 0056887
2012-03-16 12:27 Zeljan Rikalo Fixed in Revision => 36086
2012-03-16 12:27 Zeljan Rikalo Status feedback => resolved
2012-03-16 12:27 Zeljan Rikalo Resolution open => fixed
2012-03-16 12:27 Zeljan Rikalo Assigned To => Zeljan Rikalo
2012-03-16 12:27 Zeljan Rikalo Note Added: 0057714
2012-11-01 14:12 Zeljan Rikalo Relationship added related to 0023219
2013-05-05 16:25 Juha Manninen Relationship added related to 0024371
2020-03-25 10:19 Juha Manninen Relationship added related to 0034678
2020-03-25 10:25 Juha Manninen Relationship added related to 0007243