X-Git-Url: http://iramuteq.org/git?p=iramuteq;a=blobdiff_plain;f=Liste.py;h=73d3f33787a8ab2cd9ab2c99fe6879682018fa0a;hp=e0bc11a6167d5fe1a0eb3b477fd55eeabe84b55a;hb=95be18f0436f49152f463280dbe016a3ecd3dbd0;hpb=437f0dd98164afb134c221fe4c4378ec7e3b64e5 diff --git a/Liste.py b/Liste.py index e0bc11a..73d3f33 100644 --- a/Liste.py +++ b/Liste.py @@ -19,7 +19,7 @@ import wx from dialog import SearchDial, message import wx.lib.mixins.listctrl as listmix from operator import itemgetter - +from functions import doconcorde #--------------------------------------------------------------------------- class ListPanel(wx.ListCtrl, listmix.ListCtrlAutoWidthMixin, listmix.ColumnSorterMixin): @@ -182,20 +182,10 @@ class ListPanel(wx.ListCtrl, listmix.ListCtrlAutoWidthMixin, listmix.ColumnSorte def OnPopupTwo(self, event): corpus = self.gparent.corpus - win = message(self, u"Concordancier", (750, 600)) - avap = 60 item = self.getColumnText(self.GetFirstSelected(), 0) - listmot = corpus.getlems()[item].formes - #uce_ok = [corpus.formes[corpus.idformes[forme].forme][1] for forme in listmot] - uce_ok = corpus.getlemuces(item)#list(set([tuple(val) for line in uce_ok for val in line])) - txt = '

Concordancier

' - res = corpus.getconcorde(uce_ok) - for uce in res : - ucetxt = ' '+uce[1]+' ' - txt += ' '.join(corpus.ucis[corpus.getucefromid(uce[0]).uci].etoiles) + '
' - for forme in listmot : - forme = corpus.getforme(forme).forme - ucetxt = ucetxt.replace(' '+forme+' ', ' ' + forme + ' ') - txt += ucetxt + '

' - win.HtmlPage.SetPage(txt) + uce_ok = corpus.getlemuces(item) + ucis_txt, ucestxt = doconcorde(corpus, uce_ok, [item]) + win = message(self, u"Concordancier", (750, 600)) + win.html = ('\n

%s

' % item) + '
'.join(['
'.join([ucis_txt[i], ucestxt[i]]) for i in range(0,len(ucestxt))]) + '\n' + win.HtmlPage.SetPage(win.html) win.Show(True)