X-Git-Url: http://iramuteq.org/git?p=iramuteq;a=blobdiff_plain;f=dialog.py;h=82dc089cdc1ffc4e5a42a1b7e0fe32739a7678bd;hp=818485e137cd55773a729b77debfb158c0b6067b;hb=e1fab13fcb5acc145a53301b5a7f9a4ab496f3c1;hpb=2ec30a2ebf7b9576251d298d79cebf83dec75d88 diff --git a/dialog.py b/dialog.py index 818485e..82dc089 100755 --- a/dialog.py +++ b/dialog.py @@ -1881,38 +1881,38 @@ class PrefDendro ( wx.Dialog ): self.m_staticline41 = wx.StaticLine( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.LI_HORIZONTAL ) fgSizer1.Add( self.m_staticline41, 0, wx.EXPAND |wx.ALL, 5 ) + if self.param['typedendro'] == 'classique' : + self.m_staticText5 = wx.StaticText( self, wx.ID_ANY, _(u"Color or black and white").decode('utf8'), wx.DefaultPosition, wx.DefaultSize, 0 ) + self.m_staticText5.Wrap( -1 ) + fgSizer1.Add( self.m_staticText5, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALL, 5 ) - self.m_staticText5 = wx.StaticText( self, wx.ID_ANY, _(u"Color or black and white").decode('utf8'), wx.DefaultPosition, wx.DefaultSize, 0 ) - self.m_staticText5.Wrap( -1 ) - fgSizer1.Add( self.m_staticText5, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALL, 5 ) - - m_radioBox1Choices = [ _(u"color").decode('utf8'), _(u"black and white").decode('utf8') ] - self.m_radioBox1 = wx.RadioBox( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, m_radioBox1Choices, 1, wx.RA_SPECIFY_COLS ) - self.m_radioBox1.SetSelection( 0 ) - fgSizer1.Add( self.m_radioBox1, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALIGN_RIGHT|wx.ALL, 5 ) + m_radioBox1Choices = [ _(u"color").decode('utf8'), _(u"black and white").decode('utf8') ] + self.m_radioBox1 = wx.RadioBox( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, m_radioBox1Choices, 1, wx.RA_SPECIFY_COLS ) + self.m_radioBox1.SetSelection( 0 ) + fgSizer1.Add( self.m_radioBox1, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALIGN_RIGHT|wx.ALL, 5 ) - self.m_staticline5 = wx.StaticLine( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.LI_HORIZONTAL ) - fgSizer1.Add( self.m_staticline5, 0, wx.EXPAND |wx.ALL, 5 ) + self.m_staticline5 = wx.StaticLine( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.LI_HORIZONTAL ) + fgSizer1.Add( self.m_staticline5, 0, wx.EXPAND |wx.ALL, 5 ) - self.m_staticline6 = wx.StaticLine( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.LI_HORIZONTAL ) - fgSizer1.Add( self.m_staticline6, 0, wx.EXPAND |wx.ALL, 5 ) + self.m_staticline6 = wx.StaticLine( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.LI_HORIZONTAL ) + fgSizer1.Add( self.m_staticline6, 0, wx.EXPAND |wx.ALL, 5 ) - bSizer4 = wx.BoxSizer( wx.HORIZONTAL ) + bSizer4 = wx.BoxSizer( wx.HORIZONTAL ) - self.m_staticText6 = wx.StaticText( self, wx.ID_ANY, _(u"Add cluster size").decode('utf8'), wx.DefaultPosition, wx.DefaultSize, 0 ) - self.m_staticText6.Wrap( -1 ) - bSizer4.Add( self.m_staticText6, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALL, 5 ) + self.m_staticText6 = wx.StaticText( self, wx.ID_ANY, _(u"Add cluster size").decode('utf8'), wx.DefaultPosition, wx.DefaultSize, 0 ) + self.m_staticText6.Wrap( -1 ) + bSizer4.Add( self.m_staticText6, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALL, 5 ) - self.m_checkBox1 = wx.CheckBox( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 ) - self.m_checkBox1.SetValue(True) - bSizer4.Add( self.m_checkBox1, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALL, 5 ) + self.m_checkBox1 = wx.CheckBox( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 ) + self.m_checkBox1.SetValue(True) + bSizer4.Add( self.m_checkBox1, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALL, 5 ) - fgSizer1.Add( bSizer4, 1, wx.EXPAND, 5 ) + fgSizer1.Add( bSizer4, 1, wx.EXPAND, 5 ) - m_radioBox2Choices = [ _(u"circular diagram").decode('utf8'), _(u"bar").decode('utf8') ] - self.m_radioBox2 = wx.RadioBox( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, m_radioBox2Choices, 1, wx.RA_SPECIFY_COLS ) - self.m_radioBox2.SetSelection( 0 ) - fgSizer1.Add( self.m_radioBox2, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALIGN_RIGHT|wx.ALL, 5 ) + m_radioBox2Choices = [ _(u"circular diagram").decode('utf8'), _(u"bar").decode('utf8') ] + self.m_radioBox2 = wx.RadioBox( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, m_radioBox2Choices, 1, wx.RA_SPECIFY_COLS ) + self.m_radioBox2.SetSelection( 0 ) + fgSizer1.Add( self.m_radioBox2, 0, wx.ALIGN_CENTER_VERTICAL|wx.ALIGN_RIGHT|wx.ALL, 5 ) self.m_staticline7 = wx.StaticLine( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.LI_HORIZONTAL ) fgSizer1.Add( self.m_staticline7, 0, wx.EXPAND |wx.ALL, 5 ) @@ -1942,10 +1942,11 @@ class PrefDendro ( wx.Dialog ): self.m_spinCtrl2.SetValue(self.param['width']) self.m_spinCtrl1.SetValue(self.param['height']) self.m_choice1.SetSelection(self.param['type_dendro']) - self.m_radioBox1.SetSelection(self.param['color_nb']) - self.m_checkBox1.SetValue(self.param['taille_classe']) - self.m_radioBox2.SetSelection(self.param['type_tclasse']) self.choice_format.SetSelection(self.param['svg']) + if self.param['typedendro'] == 'classique' : + self.m_radioBox1.SetSelection(self.param['color_nb']) + self.m_checkBox1.SetValue(self.param['taille_classe']) + self.m_radioBox2.SetSelection(self.param['type_tclasse']) def __del__( self ): pass @@ -2284,7 +2285,7 @@ class CorpusPref ( wx.Dialog ): def __init__( self, parent, parametres ): wx.Dialog.__init__ ( self, parent, id = wx.ID_ANY, title = _(u"Settings").decode('utf8'), pos = wx.DefaultPosition, size = wx.DefaultSize, style = wx.DEFAULT_DIALOG_STYLE | wx.STAY_ON_TOP ) self.parent = parent - langues_n = [u'français', u'english', u'german (expérimentale)', u'italian', u'swedish (expérimentale)', u'portuguese', u'spanish (expérimentale)', u'greek (expériementale)', u'galician (expérimentale)', u'autre...'] + langues_n = [u'français', u'english', u'german (expérimentale)', u'italian', u'swedish (expérimentale)', u'portuguese', u'spanish', u'greek (expériementale)', u'galician (expérimentale)', u'autre...'] self.langues = [u'french', u'english', u'german', u'italian', u'swedish', u'portuguese', u'spanish', u'greek', u'galician', u'other'] self.encodages = [enc[0].lower() for enc in encodages] @@ -2669,7 +2670,7 @@ class message(wx.Frame): self, message=_(u"Save as ...").decode('utf8'), defaultDir=os.getcwd(), defaultFile="concordancier.html", wildcard="html|*.html", style=wx.SAVE | wx.OVERWRITE_PROMPT ) - dlg.SetFilterIndex(2) + #dlg.SetFilterIndex(2) dlg.CenterOnParent() self.html = '
'.join([self.items[i] for i in range(0,len(self.items))]) if dlg.ShowModal() == wx.ID_OK: