|
List Info
Thread: wxTreeCtrl under Windows XP
|
|
| wxTreeCtrl under Windows XP |
  United States |
2007-10-10 21:23:04 |
|
Hi:
I am working on a project using DB 4.16 and wxWidgets 2.8.3. My main
development platform is openSuse 10.2 and my project uses a wxTreeCtrl
that works fine under Linux. However, the same project compiled with
wxDevCpp under XP does not allow the tree to be expanded, and does not
show the twister button to click on it. Everything else works ok so far.
Any suggestions would be appreciated.
Best regards,
--
Alfredo Cole-Tuchler
Tel. 251-8572
Tegucigalpa
__._,_.___
.
__,_._,___
|
| Re: wxTreeCtrl under Windows XP |
  United Kingdom |
2007-10-11 01:36:50 |
|
Alfredo Cole wrote:
> Hi:
>
> I am working on a project using DB 4.16 and wxWidgets 2.8.3. My main
> development platform is openSuse 10.2 and my project uses a wxTreeCtrl
> that works fine under Linux. However, the same project compiled with
> wxDevCpp under XP does not allow the tree to be expanded, and does not
> show the twister button to click on it. Everything else works ok so far.
>
Strange - maybe there's an id clash causing the tree to be disabled? You
mean nothing is selectable, as well as not being expandable? What
happens when you compile a minimal DialogBlocks project containing a
tree control? If that works, but your project doesn't, then you could
try to work out the differences between the two pieces of code.
BTW you don't get a twister button on XP - the native style is +/- buttons.
Regards,
Julian
__._,_.___
.
__,_._,___
|
| Re: wxTreeCtrl under Windows XP |
  United States |
2007-10-11 12:02:16 |
|
El jue, 11-10-2007 a las 07:36 +0100, Julian Smart escribió:
> Alfredo Cole wrote:
> > Hi:
> >
> > I am working on a project using DB 4.16 and wxWidgets 2.8.3. My main
> > development platform is openSuse 10.2 and my project uses a
> wxTreeCtrl
> > that works fine under Linux. However, the same project compiled with
> > wxDevCpp under XP does not allow the tree to be expanded, and does
> not
> > show the twister button to click on it. Everything else works ok so
> far.
> >
> Strange - maybe there's an id clash causing the tree to be disabled?
> You
> mean nothing is selectable, as well as not being expandable? What
> happens when you compile a minimal DialogBlocks project containing a
> tree control? If that works, but your project doesn't, then you could
> try to work out the differences between the two pieces of code.
>
> BTW you don't get a twister button on XP - the native style is +/-
> buttons.
>
> Regards,
>
> Julian
I tried to see the behavior of the Sample/Elements project. Under Linux
and Windows its identical: Nothing shows on the wxTreeCtrl. With my
project, I initialize the tree as follows:
rootId = Tree->AddRoot(_("Catalog"));
Then, I read individual items from a database:
while(q.fetch_row())
{
sAccount = q.getstr();
sName = q.getstr();
Tree->AppendItem(rootId, sAccount + "-" + sName);
}
Under Linux, the control looks like
http://www.acyc.com/TreeLinux.jpg
and expanded like
http://www.acyc.com/TreeLinux1.jpg
Under Windows, it looks like
http://www.acyc.com/WindowsTree.jpg
The project was copied directly from Linux, and it compiled without
errors. Everything else looks fine.
>
--
Alfredo Cole-Tuchler
Tel. 251-8572
Tegucigalpa
__._,_.___
.
__,_._,___
|
| Re: wxTreeCtrl under Windows XP |
  United Kingdom |
2007-10-11 12:05:36 |
|
Alfredo Cole wrote:
>
> Under Windows, it looks like
>
> http://www.acyc.com/WindowsTree.jpg
>
Can you double-click on the root to expand it? Maybe you need to set a
few styles, e.g. wxTR_HAS_BUTTONS? Although the Elements sample does
have this style. Maybe compare it with the wxTreeCtrl sample in
wxWidgets. There have been no related reported bugs in wxTreeCtrl AFAIK
so I would have thought a little more experimentation will resolve it.
Regards,
Julian
__._,_.___
.
__,_._,___
|
| Re: wxTreeCtrl under Windows XP |
  United States |
2007-10-11 13:08:23 |
|
El jue, 11-10-2007 a las 18:05 +0100, Julian Smart escribió:
> Alfredo Cole wrote:
> >
> > Under Windows, it looks like
> >
> > http://www.acyc.com/WindowsTree.jpg
> >
> Can you double-click on the root to expand it? Maybe you need to set
> a
> few styles, e.g. wxTR_HAS_BUTTONS? Although the Elements sample does
> have this style. Maybe compare it with the wxTreeCtrl sample in
> wxWidgets. There have been no related reported bugs in wxTreeCtrl
> AFAIK
> so I would have thought a little more experimentation will resolve it.
>
> Regards,
>
> Julian
Hi Julian:
Double clicking does nothing and the styles are identical
(wxTR_HAS_BUTTONS is checked, and so is wxTR_TWIST_BUTTONS). I will keep
trying.
Thank you and regards.
>
--
Alfredo Cole-Tuchler
Tel. 251-8572
Tegucigalpa
__._,_.___
.
__,_._,___
|
[1-5]
|
|