GSoC 2019 : Week 4 - TreeView on a Palette

Posted 3 weeks ago

This is a brief report of what all I have done in the last week as part of my GSoC project.

Work Planned To Do:

As mentioned in the previous blog, I wanted to start the week by parsing the XML file and adding the palette Items to the TreeView by using the XML file. Also, I wanted to start adding icons to the palette Items.

Work Done:

I was able to add the Palette Item using the XML file present the directory share/workspaces/. I used the read() function in the palette and paletteBox to get the names from the XML files and then created a TreeItem for each palette Item. I also started working on placing the icons for each palette Items. By far I was able to place a single png file as an icon on each palette Item which will be replaced by the appropriate icon. I also started writing functions to place the Icons of each palette elements by returning a QVariant of the QIcon by passing it to a setIcon function in TreeItem class to the Qt::DecorationRole of the TreeModel.

PaletteXml.gif

Work Planned to do this week:

I want to complete placing the icons on the treeVeiw also start implementing the logic behind each TreeItem for the TreeView. This including connecting each element in the palette item to its corresponding element.