Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > [wxpython] exclude files in a wx.FileDialog?

Reply
Thread Tools

[wxpython] exclude files in a wx.FileDialog?

 
 
John Field
Guest
Posts: n/a
 
      01-18-2005
Hello,

Is it possible to exclude certain files in a wx.FileDialog, so that the user
won't see them and can't select them with the mouse in de File open window?

I was thinking of somehow extending the class FileDialog(Dialog)
in the wx module _windows.py to a subclass, but I'm not sure how to do that
(if feasible).


cheers
 
Reply With Quote
 
 
 
 
Franz Steinhaeusler
Guest
Posts: n/a
 
      01-18-2005
On 18 Jan 2005 13:23:24 GMT, John Field <(E-Mail Removed)> wrote:

>Hello,
>
>Is it possible to exclude certain files in a wx.FileDialog, so that the user
>won't see them and can't select them with the mouse in de File open window?
>
>I was thinking of somehow extending the class FileDialog(Dialog)
>in the wx module _windows.py to a subclass, but I'm not sure how to do that
>(if feasible).
>
>
>cheers


wx.FileDialog is only a wrapper for the api FileDialog (at least this
applies for windows) and therefore it is not possible to derive from it.

Really exclude, I think, is not possible.

You can put a mask
wx.FileDialog(...wildcard = "BMP files (*.bmp)|*.bmp|GIF files
(*.gif)|*.gif")

Otherwise you have to create your own FileDialog.
--
Franz Steinhaeusler
 
Reply With Quote
 
 
 
 
John Field
Guest
Posts: n/a
 
      01-19-2005
Hello Franz,

Franz Steinhaeusler <(E-Mail Removed)> wrote in
news:(E-Mail Removed):

>>Is it possible to exclude certain files in a wx.FileDialog, so that the
>>user won't see them and can't select them with the mouse in de File open
>>window?


>>I was thinking of somehow extending the class FileDialog(Dialog)
>>in the wx module _windows.py to a subclass, but I'm not sure how to do
>>that (if feasible).


> wx.FileDialog is only a wrapper for the api FileDialog (at least this
> applies for windows) and therefore it is not possible to derive from it.


> Really exclude, I think, is not possible.


> You can put a mask
> wx.FileDialog(...wildcard = "BMP files (*.bmp)|*.bmp|GIF files
> (*.gif)|*.gif")


In my experience this one shows only .bmp files, whereas
wildcard = "Image files | *.bmp;*.gif"
shows both extensions. Which i find strange, considering wxpython Help voor
wxFileDialog:

It must be noted that wildcard support in the native Motif file dialog is
quite limited: only one alternative is supported, and it is
displayed without the descriptive test; "BMP files (*.bmp)|*.bmp'' is
displayed as "*.bmp'', and both "BMP files (*.bmp)|*.bmp|GIF files
(*.gif)|*.gif'' and "Image files|*.bmp;*.gif'' are errors.

Unfortunately there is no expected extension for the input, most probably the
input files will have no extension at all, but it really is up to the user.


> Otherwise you have to create your own FileDialog.

Yes, ehh, pff

Thanks for responding

cheers

 
Reply With Quote
 
Franz Steinhaeusler
Guest
Posts: n/a
 
      01-19-2005
On 19 Jan 2005 14:10:45 GMT, John Field <(E-Mail Removed)> wrote:

Hello John,

>Unfortunately there is no expected extension for the input, most probably the
>input files will have no extension at all, but it really is up to the user.
>
>
>> Otherwise you have to create your own FileDialog.

>Yes, ehh, pff
>
>Thanks for responding


you're welcome.
sorry, that i don't have any other infos for you anymore.

I would ask in the wxpython-user mailing list or
wxwidget Ng.

You can also take a look to DrPython;
There is a File drFileDialog, which is a
full FileDialog based on a wx.ListCtrl.

--
Franz Steinhaeusler
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
aspnet_compiler - exclude files CuriousGeorge ASP .Net 5 03-28-2006 10:06 PM
ASP.NET 2.0 - How exclude folders/files when publishing? VB Programmer ASP .Net 0 01-05-2006 10:56 PM
Exclude resource files from precompiled asp.net website Sanjay Pais ASP .Net 1 12-20-2005 01:57 AM
Exclude Files from Copy Project? Chuck Ritzke ASP .Net 1 04-22-2004 05:50 PM
Forms Authentication - how to exclude certain files Peter ASP .Net 2 08-20-2003 07:39 PM



Advertisments