wxDirDialog looks strange on win7
wxDirDialog looks strange on win7
In some of my applications I am using wxDirDialog, but on win7 it looks very strange, more like wxFileDialog.
When I start the same application on XP the dialog looks OK. Here how I expect wxDirDialog to look like:
My wxWidgets version is 3.0.2 and I am using wxSmith to build my GUIs. Have used wxDev befor and had no such problems with wxFileDialog there, which could be beacause wxDev used older wxWidgets version, but not shure about that.
When I start the same application on XP the dialog looks OK. Here how I expect wxDirDialog to look like:
My wxWidgets version is 3.0.2 and I am using wxSmith to build my GUIs. Have used wxDev befor and had no such problems with wxFileDialog there, which could be beacause wxDev used older wxWidgets version, but not shure about that.
Re: wxDirDialog looks strange on win7
Hi,
Unfortunately the images are not displayed.
Can you re-post them?
Thank you.
Unfortunately the images are not displayed.
Can you re-post them?
Thank you.
Re: wxDirDialog looks strange on win7
I can see the images and i think it's normal that you get the native dialog under Windows 7.
Use the source, Luke!
Re: wxDirDialog looks strange on win7
Is there a way to let it look, like the other one?doublemax wrote:I can see the images and i think it's normal that you get the native dialog under Windows 7.
Re: wxDirDialog looks strange on win7
You can use the generic dir dialog that looks somewhat like the XP version.
You can see it in action in the "dialogs" sample under "Directory operations -> Choose a directory (generic)"
#include "wx/generic/dirdlgg.h" and use wxGenericDirDialog instead of wxDirDialog.
You can see it in action in the "dialogs" sample under "Directory operations -> Choose a directory (generic)"
#include "wx/generic/dirdlgg.h" and use wxGenericDirDialog instead of wxDirDialog.
Use the source, Luke!
Re: wxDirDialog looks strange on win7
The old dialog based on SHBrowseForFolder should definitely not be used if possible, the new one has been in wxWidgets since 2012.
One of the reasons I participated in bringing the new IFileDialog-based wxDirDialog to life was that the old one was buggy on MS Windows 7, the selected folder did not scroll into view. Obviously, the other reason was the old dialog not being user friendly in general; similarly, you would not want your users having to use the Win95-style dialogs for opening/saving files either....MSDN wrote:For Windows Vista or later, it is recommended that you use IFileDialog with the FOS_PICKFOLDERS option rather than the SHBrowseForFolder function. This uses the Open Files dialog in pick folders mode and is the preferred implementation.
Re: wxDirDialog looks strange on win7
Thanks, and it´s look like the standard dirDialog? Unfortunately it´ll be a pain in the as for me, as I am using wxSmith and mixing autogenerated stuff mixed with manual stuff can be problematic sometimes.doublemax wrote:You can use the generic dir dialog that looks somewhat like the XP version.
You can see it in action in the "dialogs" sample under "Directory operations -> Choose a directory (generic)"
#include "wx/generic/dirdlgg.h" and use wxGenericDirDialog instead of wxDirDialog.
Re: wxDirDialog looks strange on win7
protip: build out your ui first, then copy all the generated files into a new project using a standard IDE and work from there. That way if you have to go back and edit the ui, you wont accidently let the ui generator goof up your "real" project.gtafan wrote: Unfortunately it´ll be a pain in the as for me, as I am using wxSmith and mixing autogenerated stuff mixed with manual stuff can be problematic sometimes.
- eranon
- Can't get richer than this
- Posts: 867
- Joined: Sun May 13, 2012 11:42 pm
- Location: France
- Contact:
Re: wxDirDialog looks strange on win7
Typically (unless very specific design), you don't add your dir. dialog in your user-interface, but you call it in the flow of your code to launch it when necessary only. So, you don't need wxSmith to manage this dialog.gtafan wrote:Thanks, and it´s look like the standard dirDialog? Unfortunately it´ll be a pain in the as for me, as I am using wxSmith and mixing autogenerated stuff mixed with manual stuff can be problematic sometimes.
This said, all the GUI designers generate code and it's up to you to embed it in you own project the way you prefer. So, there're two schools: some derive their own classes from the generated ones (this way, the codes are never mixed in common files) and some others simply write down their own code outside of the generated code blocks (delimited by dedicated tags).
[Ind. dev. - wxWidgets 3.0/3.1 under "Win 7 64-bit, TDM64-GCC" + "OS X 10.9, LLVM Clang"]
Re: wxDirDialog looks strange on win7
I was already tolld in some other thread, that I should create the dialogs only at the place I need them and they should not be members of the application, but since my applications are converters and file and/or dir dialogs are used very often, I see it as an overhead to creat the needed dialog everitime from scrach.eranon wrote:Typically (unless very specific design), you don't add your dir. dialog in your user-interface, but you call it in the flow of your code to launch it when necessary only. So, you don't need wxSmith to manage this dialog.gtafan wrote:Thanks, and it´s look like the standard dirDialog? Unfortunately it´ll be a pain in the as for me, as I am using wxSmith and mixing autogenerated stuff mixed with manual stuff can be problematic sometimes.
- eranon
- Can't get richer than this
- Posts: 867
- Joined: Sun May 13, 2012 11:42 pm
- Location: France
- Contact:
Re: wxDirDialog looks strange on win7
But whatever the place where you declare and create it, as member or not, on heap for a long life or on stack for a short one, it's not a permanent part of your UI on screen and you don't even have to manage a place holder for it... Thus, you don't need wxSmith nor any GUI designer for it. You simply write down your code (two or three lines) by hand and it's done!
[Ind. dev. - wxWidgets 3.0/3.1 under "Win 7 64-bit, TDM64-GCC" + "OS X 10.9, LLVM Clang"]
Re: wxDirDialog looks strange on win7
I took a look at wxWidget documentation and there is no wxGenericDirDialog, is it just undocumented?doublemax wrote:You can use the generic dir dialog that looks somewhat like the XP version.
You can see it in action in the "dialogs" sample under "Directory operations -> Choose a directory (generic)"
#include "wx/generic/dirdlgg.h" and use wxGenericDirDialog instead of wxDirDialog.
Re: wxDirDialog looks strange on win7
Yes, the "generic" classes are often not documented, as they're usually only a fallback for platforms where no native version of that control exists.I took a look at wxWidget documentation and there is no wxGenericDirDialog, is it just undocumented?
Use the source, Luke!
Re: wxDirDialog looks strange on win7
OK, thanks. Are generic versions avaible for all dialogs?doublemax wrote:Yes, the "generic" classes are often not documented, as they're usually only a fallback for platforms where no native version of that control exists.I took a look at wxWidget documentation and there is no wxGenericDirDialog, is it just undocumented?
Re: wxDirDialog looks strange on win7
Probably not all of them.Are generic versions avaible for all dialogs?
Check the files in <wxdir>/include/generic/
It should give you a general idea about which ones are available. They all end in *dlgg.h"
Use the source, Luke!