warning dialog box

Hi,

I'm following up on a new thread on the python NG (hereunder) - it looks like
the problem occurs in many instances - is there a solution ?

Regards,

Philippe

""""
I have a wxpython program that displays TIF images. Sometimes it will
encounter a tag the tiff loader cant handle. Rather than silently
ignoring it, it pops up a window:

Python Warning
unknown field with tag blah blah

I don't want it to do this, but I can't work out how to turn it off.
Anyone know?

Iain

Michele Petrazzo wrote:

Philippe Martin wrote:
> I had a similar but simple problem (the file was missing) and had to
> check by hand before calling wxPython.
>
> Can you check the tag by hand before calling wxPython ?
>
>
> Philippe
>
>

Hi,
also I have the same problem with g3/g4 images. My solution was convert
that image before to .png before... Very bad hack, but work.
I think that is an internal wxWidgets message (warning), passed to the
wxPython subsystem.

This is actually exactly what I did. (well, I converted to jpg, because
they're going to end up as jpg anyway).

bah

Iain

"""

···

--
_________________________
Philippe C. Martin
www.snakecard.com
_________________________

Philippe C. Martin wrote:

Hi,

I'm following up on a new thread on the python NG (hereunder) - it looks like the problem occurs in many instances - is there a solution ?

Regards,

Philippe

""""
I have a wxpython program that displays TIF images. Sometimes it will
encounter a tag the tiff loader cant handle. Rather than silently
ignoring it, it pops up a window:

Python Warning
unknown field with tag blah blah

I don't want it to do this, but I can't work out how to turn it off.
Anyone know?

Iain

If it is a wxLog message (I think it is) then you can temporarily disable log messages by creating an instance of wx.LogNull. Or you can do something like set the log target to some other object than the default wx.LogGui, or set the log level to a higher level so those messages are not logged.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Thanks, will try that.

Philippe

···

On Wednesday 26 April 2006 04:21 pm, Robin Dunn wrote:

Philippe C. Martin wrote:
> Hi,
>
> I'm following up on a new thread on the python NG (hereunder) - it looks
> like the problem occurs in many instances - is there a solution ?
>
> Regards,
>
> Philippe
>
> """"
> I have a wxpython program that displays TIF images. Sometimes it will
> encounter a tag the tiff loader cant handle. Rather than silently
> ignoring it, it pops up a window:
>
> Python Warning
> unknown field with tag blah blah
>
> I don't want it to do this, but I can't work out how to turn it off.
> Anyone know?
>
> Iain

If it is a wxLog message (I think it is) then you can temporarily
disable log messages by creating an instance of wx.LogNull. Or you can
do something like set the log target to some other object than the
default wx.LogGui, or set the log level to a higher level so those
messages are not logged.

--
_________________________
Philippe C. Martin
www.snakecard.com
_________________________