Uc@scdZddlZejdddlZddlZed\ZZZZ e dddfe dd d fe d d d fe dd dfe dddfe dddfe dddfe dddfe dddfe dddfe dddfe dddfe d d!d"fe d#dd$ffZ d%ej fd&YZd'Zed(kr_endS()sTree View/List Store The GtkListStore is used to store data in list form, to be used later on by a GtkTreeView to display it. This demo builds a simple GtkListStore and displays it. See the Stock Browser demo for a more advanced example.iNs2.0iiBtNormals$scrollable notebooks and hidden tabsitCriticals;gdk_window_clear_area(gdkwindow-win32.c) is not thread-safei&tMajors'Xft support does not clean up correctlyis)GtkFileSelection needs a refresh method. is-Can't click button after setting in sensitivei#s.GtkLabel - Not all changes propagate correctlyis-Rework width/height computations for TreeViewis0gtk_dialog_set_response_sensitive() doesn't workisGetters for all settersi]sGtkcalender sizeis,Selectable label needs right-click copy menuis!Add shift clicking to GtkTextViewit Enhancements"netscape-like collapsable toolbarsis First bug :=)t ListStoreDemocBs/eZddZdZdZdZRS(cCs[tjj|y|j|jWn$tk rM|jddnX|j|jj |j d|j ddtj t d}|j|tjd}|j|t t tj}|jtj|jtjtj|j||j}tj|}|jt|jt|j||j||jdS(NtdestroycWs tjS(N(tgtkt main_quit(tw((s(/usr/lib/pygtk27/2.0/demos/list_store.pyt-sii,is~This is the bug list (note: not based on real data, it would be nice to have a nice ODBC interface to bugzilla or so, though).(RtWindowt__init__t set_screent get_screentAttributeErrortconnectt set_titlet __class__t__name__tset_border_widthtset_default_sizetVBoxtFalsetaddtLabelt pack_starttScrolledWindowtset_shadow_typetSHADOW_ETCHED_INt set_policyt POLICY_NEVERtPOLICY_AUTOMATICt_ListStoreDemo__create_modeltTreeViewtset_rules_hinttTruetset_search_columntCOLUMN_DESCRIPTIONt_ListStoreDemo__add_columnstshow_all(tselftparenttvboxtlabeltswtmodelttreeview((s(/usr/lib/pygtk27/2.0/demos/list_store.pyR 's.          c Csztjtjtjtjtj}xOtD]G}|j}|j|t |t t |t t |t t |t  q+W|S(N( Rt ListStoretgobjectt TYPE_BOOLEANt TYPE_UINTt TYPE_STRINGtdatatappendtsett COLUMN_FIXEDt COLUMN_NUMBERtCOLUMN_SEVERITYR%(R(tlstoretitemtiter((s(/usr/lib/pygtk27/2.0/demos/list_store.pyt__create_modelNs       cCsH|jt|f}|j|t}| }|j|t|dS(N(tget_itertintt get_valueR7R6(R(tcelltpathR-R<tfixed((s(/usr/lib/pygtk27/2.0/demos/list_store.pyt fixed_toggled^scCs|j}tj}|jd|j|tjd|dt}|jtj|j d|j |tjdtj dt }|j t |j |tjdtj dt}|j t|j |tjdtj dt}|j t|j |dS( NttoggledtFixedtactivei2s Bug NumberttexttSeverityt Description(t get_modelRtCellRendererToggleRRDtTreeViewColumnR7t set_sizingtTREE_VIEW_COLUMN_FIXEDtset_fixed_widtht append_columntCellRendererTextR8tset_sort_column_idR9R%(R(R.R-trenderertcolumn((s(/usr/lib/pygtk27/2.0/demos/list_store.pyt __add_columnsis&            N(Rt __module__tNoneR R RDR&(((s(/usr/lib/pygtk27/2.0/demos/list_store.pyR&s '  cCsttjdS(N(RRtmain(((s(/usr/lib/pygtk27/2.0/demos/list_store.pyRYst__main__(t__doc__tpygtktrequireR0RtrangeR7R8R9R%RR#R4R RRYR(((s(/usr/lib/pygtk27/2.0/demos/list_store.pyts0     d