Thank you, Salvatore Larosa.
        I read the link you give, it looks like build a PyQGIS applications
( Without QGIS Application ).
        Although I just want to build a Qgis plugin using python ( Within
QGIS Application ),
    I learn "the legend" ( like qgis.utils.iface.legendInterface() ) is a
kind of  QTreeWidget.
    It can process layers ( eg. QTreeWidgetItem or QgsLegendModel ??).
    But I still not found using API to collapse/expand a layer or get legend
object.
        I Think If I can get QGIS application's legend object,
    I can use the QTreeWidget's method collapseItem/expandItem to get what I
want (Maybe...).

I will try my best and thank you again.

           KSJ

    

--
View this message in context: 
http://osgeo-org.1560.n6.nabble.com/How-to-Use-Qgis-API-to-Collapse-or-Expand-a-Layer-tp4479915p4481046.html
Sent from the Quantum GIS - Developer mailing list archive at Nabble.com.
_______________________________________________
Qgis-developer mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/qgis-developer

Reply via email to