Recent

Author Topic: Tedit: can't disable autoselect  (Read 6309 times)

Rivello

  • Newbie
  • Posts: 3
Tedit: can't disable autoselect
« on: November 18, 2012, 07:48:47 am »
Hello guys,

It seems impossible to disable the autoselect property of Tedits in win CE.

On win 32 everything works well, if I tab to the edit, the text is not selected.
But when I try on win CE, it doesnt matter the value of the autoselect property, the text is always selected when the focus goes to the edit.
I also noted that when the focus is in an edit and I click anywhere outside it, even without loosing the focus, its text is selected again.

I'm making an on screen keyboard with speedbuttons to not loose focus of the Tedit, but everytime I click the speedbutton, (or anything else) the text of the tedit is selected and replaced by a single key of my virtual keyboard.

Could anyone help?

Rivello

  • Newbie
  • Posts: 3
Re: Tedit: can't disable autoselect
« Reply #1 on: November 18, 2012, 08:28:42 am »
Not sure if it's relevant, but I tried commenting the function "SelectAll" in lazarus/lcl/include/customedit.inc , which seems to be the one called to select the edit's text when the property "autoselect" is enabled.

Results:
Autoselect stopped working on Win32, even when "true", the text is not selected.

On Win CE, nothing changed, whenever I tab to, or click outside from a Tedit, its text is selected  :(

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: Tedit: can't disable autoselect
« Reply #2 on: November 18, 2012, 09:38:46 am »
Then you've probably edited the wrong file (yes, Captain Obvious here).

Probably wince has a different include file, because it's a different widgetset (though similar) than win32
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

Rivello

  • Newbie
  • Posts: 3
Re: Tedit: can't disable autoselect
« Reply #3 on: November 18, 2012, 05:48:35 pm »
Thank you for the reply.

I searched all the files in the lcl folder and the few ones which have "autoselect" or "selectall" are in the lcl/include folder, which I supose its not for winCE.

I also reported in bugtracker:
http://mantis.freepascal.org/view.php?id=23345

 

TinyPortal © 2005-2018