Recent

Author Topic: TValueListEditor editing behavior  (Read 3085 times)

Bart

  • Hero Member
  • *****
  • Posts: 5290
    • Bart en Mariska's Webstek
Re: TValueListEditor editing behavior
« Reply #15 on: October 31, 2020, 07:04:21 pm »
Quote
I committed a fix in r64089 and r64090.
How can I update the fixes?  --> This is not my main question.

I did not request this to be merged to the fixes branch.
The new behaviour ('=' -> goto Value column) breaks existing behaviour.
It's more of a new feature than a fix (it's part of the way I implemented the fix though).
The second part of the fix: reverting a pasted '=' is a bit more tricky. I don't know it this (how I did it) is the correct way, so I do not want that merged to fixes. Let it be in trunk for a while.

There is an easy workaround: assign OnKeyPress to the ValueListEditor, suppress '='  if Col equals zero.

Alternatively:
Implement EditorCanAcceptChar for TValueListEditor and do it (suppressing '=') there.

With Lazarus 2.0.10, I still see that when the ValueListEditor is focused and copy strings to the ValueListEditor, i.e.

         ValueListEditor1.Strings.Text := AStringList.Text;

The the first row value is left blank. Is this fixed?

With trunk (and this should also work in current stable) I do
Code: Pascal  [Select][+][-]
  1.     ValEd.Strings.Assign(memo1.lines);
  2.   //ValEd.Strings.Text := Memo1.Text; {behaves exactly the same}

Where the content of Memo1 is:
Code: [Select]
Key0=Value0
Key1=Value1
Key2=Value2

This works as expected.
And IIRC this has worked for a long time.

Bart

egsuh

  • Hero Member
  • *****
  • Posts: 1292
Re: TValueListEditor editing behavior
« Reply #16 on: November 01, 2020, 06:02:26 am »
Quote
Let it be in trunk for a while.

I do not know what trunk means exactly, but I'll be waiting for later versions which incorporate those changes. Thank you.

Bart

  • Hero Member
  • *****
  • Posts: 5290
    • Bart en Mariska's Webstek
Re: TValueListEditor editing behavior
« Reply #17 on: November 01, 2020, 12:13:37 pm »
I do not know what trunk means exactly

Trunk is the development branch.
Releases are split of from trunk and form a different branch then, so development can go on and only fixes will be merged to the release branch (called fixes branch in our case).

See the Lazarus Devolpment Process article on the wiki.

Bart

 

TinyPortal © 2005-2018