A large amount of the GUI code ( gtkgui/ and gtkgui/ ) is generated from glade-2 files with the glade2py script. loads the glade-generated python files and creates all the main window's widgets and the trayicon.

'Notebooks' and 'Notebook Tabs' are contained in their respective python files, with User Info and User Browse sharing the UserTabs notebook class in

pynicotine/gtkgui/ contains a bunch of functions that are shared across different files, such as InitialiseColumns, a function for creating listview/treeview columns. AppendLine is used for adding text to all textviews.

The Notebooks are wrapped with the IconNotebook class, which allows for an icon (which changes) and close button on each tab.

Config contains the config template and save/load functions. It also handles reading the shares databases from disk. is an old version of the Python ConfigParser


pynicotine/ holds the networking callbacks. They pass through's callback, networkcallback to OnNetworkEvent where the proper function (that's in's events dict) is executed. is the networking thread. lots of undocumented stuff, here. Server and Peer messages get downloaded and get sent off to be parsed in, unless they are peerinit messages. Outgoing messages are packed and sent from here, as well. has classes for unpacking/packing server and peer messages. It uses struct for packing numbers.


pynicotine/ manages transfers and updates the gui after every change.

pynicotine/gtkgui/ is a class that gets incorporated in both and The update function is probably the most important part of that. Currently, I have transfers in a tree, sorted by username.


Search, the about dialogs, Interests, and the buddies list have their own classes and functions.

Private Chat, Chatrooms have their own input /commands.

Often you'll see a notebook class that has a function with the same names as the tab class. These will try to run same function in each class.

Last modified 15 months ago Last modified on 31/12/2016 03:52:39