diff --git a/src/Mod/Start/StartPage/StartPage.css b/src/Mod/Start/StartPage/StartPage.css index c0d1b43b46..693531c2b1 100644 --- a/src/Mod/Start/StartPage/StartPage.css +++ b/src/Mod/Start/StartPage/StartPage.css @@ -155,3 +155,6 @@ ul.workbenches li, ul.addonslist li { .forum { display: none; /* forum display */ } +.forum pre { + white-space: pre-wrap; +} diff --git a/src/Mod/Start/StartPage/StartPage.py b/src/Mod/Start/StartPage/StartPage.py index 2a32dbc644..0db98c0470 100644 --- a/src/Mod/Start/StartPage/StartPage.py +++ b/src/Mod/Start/StartPage/StartPage.py @@ -350,33 +350,61 @@ def handle(): for wb in sorted(FreeCADGui.listWorkbenches().keys()): if wb.endswith("Workbench"): wn = wb[:-9] - wblist.append(wn.lower()) - if wb in iconbank: - img = iconbank[wb] - else: - img = os.path.join(FreeCAD.getResourceDir(),"data","Mod",wn,"Resources","icons",wn+"Workbench.svg") - if not os.path.exists(img): - w = FreeCADGui.listWorkbenches()[wb] - if hasattr(w,"Icon"): - xpm = w.Icon - if "XPM" in xpm: - xpm = xpm.replace("\n ","\n") # some XPMs have some indent that QT doesn't like - r = [s[:-1].strip('"') for s in re.findall("(?s)\{(.*?)\};",xpm)[0].split("\n")[1:]] - p = QtGui.QPixmap(r) - p = p.scaled(24,24) - img = tempfile.mkstemp(dir=tempfolder,suffix='.png')[1] - p.save(img) - else: - img = xpm + else: + wn = wb + if wn == "flamingoTools": + wn = "flamingo" + if wn == "Geodat": + wn = "geodata" + if wn == "None": + continue + wblist.append(wn.lower()) + if wb in iconbank: + img = iconbank[wb] + else: + img = os.path.join(FreeCAD.getResourceDir(),"data","Mod",wn,"Resources","icons",wn+"Workbench.svg") + if not os.path.exists(img): + w = FreeCADGui.listWorkbenches()[wb] + if hasattr(w,"Icon"): + xpm = w.Icon + if "XPM" in xpm: + xpm = xpm.replace("\n ","\n") # some XPMs have some indent that QT doesn't like + r = [s[:-1].strip('"') for s in re.findall("(?s)\{(.*?)\};",xpm)[0].split("\n")[1:]] + p = QtGui.QPixmap(r) + p = p.scaled(24,24) + img = tempfile.mkstemp(dir=tempfolder,suffix='.png')[1] + p.save(img) else: - img="images/freecad.png" - iconbank[wb] = img - UL_WORKBENCHES += '