wxpython

WxPython: Control for numbers in scientific notation

佐手、 提交于 2020-01-06 15:18:43
问题 Are there controls to allow the user to enter numbers in scientific notation in WxPython? I could not get NumCtrl to accept those, neither have I found a formatter. Indeed FloatSpin does support scientific notation, but I think a spin control is misleading in this case. 回答1: You might be able to accomplish what you want using a data formatter. There is a wxPython wiki article that actually mentions one using scientific notation here: http://wiki.wxpython.org/DataFormatters Alternatively, I

wxpython tooltip at specific coordinates

北城余情 提交于 2020-01-06 15:08:40
问题 I have seen lots of similar questions and those answers are what has gotten me this far. I have an application where all all object are created via DC, so they are all all drawn. (I have had much experience with sizers and 99% of the time sizers ROCK but in this case DC is the best answer.) So I want to have a tooltip for each element that is drawn and in the case the screen is refreshed and the element is drawn in a different location the tooltip should also move. My first attempt was with

wxPython Add multiple images to a panel issue

巧了我就是萌 提交于 2020-01-06 14:53:32
问题 I am trying to add bitmaps into a GridSizer, in a separate method: def populate_grid_with_emojis(self, category): for i in range(len(self.emoji_categories[category])): emoji_string = self.emoji_categories[category][i].lower() if '_skin_tone' in UNICODE_EMOJI[STRING_UNICODE[emoji_string]]: continue init_emoji = wx.Image(unicode_to_filename(STRING_UNICODE[emoji_string], 32)) emoji = EmojiBitmap(wx.Bitmap(init_emoji), UNICODE_EMOJI[STRING_UNICODE[emoji_string]]) static_bmp = wx.StaticBitmap()

AttributeError: 'module' object has no attribute 'PyScrolledWindow' in wxPython

偶尔善良 提交于 2020-01-06 14:13:54
问题 My python version is 2.7 and wxPython ver 3.0 for python 32 bit 2.7 version. I was currently working on a GUI app with wxPython. I tested my code it was working fine, I paused my work saved my files. I started to install some software on my machine. Then when I again started to continue my work with wxPython suddenly I started to receive an error. The complete error is given below. I don't understand the reason. I didn't edit my code too. However I am able to execute my other python

AttributeError: 'module' object has no attribute 'PyScrolledWindow' in wxPython

你。 提交于 2020-01-06 14:12:30
问题 My python version is 2.7 and wxPython ver 3.0 for python 32 bit 2.7 version. I was currently working on a GUI app with wxPython. I tested my code it was working fine, I paused my work saved my files. I started to install some software on my machine. Then when I again started to continue my work with wxPython suddenly I started to receive an error. The complete error is given below. I don't understand the reason. I didn't edit my code too. However I am able to execute my other python

AttributeError: 'module' object has no attribute 'PyScrolledWindow' in wxPython

一世执手 提交于 2020-01-06 14:12:27
问题 My python version is 2.7 and wxPython ver 3.0 for python 32 bit 2.7 version. I was currently working on a GUI app with wxPython. I tested my code it was working fine, I paused my work saved my files. I started to install some software on my machine. Then when I again started to continue my work with wxPython suddenly I started to receive an error. The complete error is given below. I don't understand the reason. I didn't edit my code too. However I am able to execute my other python

Has wxpython SpinCtrl/SpinButton changed between Classic and Phoenix?

十年热恋 提交于 2020-01-06 06:49:45
问题 I have started to look at converting one of my projects from python2.7/wxpython 3.0.2.0 to python3.5.2/wxpython 4.0.0b2 and have immediately hit an issue with SpinCtrl / SpinButton . I'm running on Linux Mint 18.2 Using this code: import wx class MainWindow(wx.Frame): def __init__(self, *args, **kwargs): wx.Frame.__init__(self, *args, **kwargs) self.panel = wx.Panel(self) self.SetSize((200,200)) sizer=wx.BoxSizer(wx.VERTICAL) text1 = wx.StaticText(self.panel,-1,"SpinCtrl") self.spin = wx

Has wxpython SpinCtrl/SpinButton changed between Classic and Phoenix?

為{幸葍}努か 提交于 2020-01-06 06:49:27
问题 I have started to look at converting one of my projects from python2.7/wxpython 3.0.2.0 to python3.5.2/wxpython 4.0.0b2 and have immediately hit an issue with SpinCtrl / SpinButton . I'm running on Linux Mint 18.2 Using this code: import wx class MainWindow(wx.Frame): def __init__(self, *args, **kwargs): wx.Frame.__init__(self, *args, **kwargs) self.panel = wx.Panel(self) self.SetSize((200,200)) sizer=wx.BoxSizer(wx.VERTICAL) text1 = wx.StaticText(self.panel,-1,"SpinCtrl") self.spin = wx

Error when select and show zoom inside rectangle patch

扶醉桌前 提交于 2020-01-06 05:53:05
问题 i try to visualize in another panel ( zoom) the area inside rectangle patch all time when the rectangle move witch click mouse i can visualize the area inside rectangle patch the problem is the zoom is not show the all the area inside rectangle patch just part or i think the x y how can i show the area inside rectangle patch all time when i move mouse in plot ? that my code and what is show : import wx from numpy import arange, sin, pi,cos import numpy as np import matplotlib import

multiple panel in wxpython

こ雲淡風輕ζ 提交于 2020-01-06 05:37:10
问题 Is it possible to have multiple panel in wxpython? I want to have something like this: import wx.grid import sys class Mat_Frame(wx.Frame): def __init__(self,parent): wx.Frame.__init__(self,wx.GetApp().TopWindow,title='Material Properties') self.panel=wx.Panel(self,-1) self.AdderPanel=wx.Panel(self.panel,-1) self.InputPanel=wx.Panel(self.panel,-1) self.OutputPanel=wx.Panel(self.panel,-1) HorSizer=wx.BoxSizer(wx.HORIZONTAL) HorSizer.Add(self.panel,proportion=1,flag=wx.EXPAND|wx.ALL) HorSizer