Re: How to make a tree item editable?
Jeroen van der Zijp <[email protected]>
| Newsgroups | gmane.comp.lib.fox-toolkit.user |
|---|---|
| Organization | FOX Toolkit |
| Message-ID | <[email protected]> |
On Fri, 14 Jan 2022 16:12:21 +0000 Dingxi Wang <[email protected]> wrote: >Dear Jeroen van der Zijp > May I ask you a favor for helping me with creating an editable tree item? >I have been trying to do the following: > >1) Create a menu pane using FXMenuPane > >2) Create a FXTextField on the menu pane > >3) Popup the menu pane when a tree time is double-clicked. >The problem I face now is where to position the menu pane. >I want to put the menu pane just over the tree item so that it looks like that the tree item is editable. >However, I have not figured how to calculate the position of an tree item. The position of each tree item is in the item (x, y). It is relative to the "content origin" of the FXScrollArea. The FXScrollArea content origin is at (pos_x, pos_y). Due to the nature of scrolling, i.e. moving the content UP, these numbers are typically negative or 0. -- JVZ -- +----------------------------------------------------------------------------+ | Copyright (C) 11:20 01/14/2022 Jeroen van der Zijp. All Rights Reserved. | +----------------------------------------------------------------------------+