Tryton Documentation Release 4.8
Total Page:16
File Type:pdf, Size:1020Kb
tryton Documentation Release 4.8 Anne Krings, Bertrand Chenal, Cédric Krier, Mathias Behrle, Tobias Paepke, Udo Spallek Nov 22, 2019 Contents 1 Introduction 3 2 Installing tryton 5 2.1 Prerequisites...............................................5 2.2 Installation................................................5 3 Client Usage 7 3.1 Name...................................................7 3.2 Synopsis.................................................7 3.3 Options..................................................7 3.4 Environment...............................................8 3.5 URL...................................................8 3.6 Overview.................................................8 3.7 Menu Bar Items............................................. 10 3.8 Tool Bar................................................. 12 3.9 Widgets.................................................. 14 3.10 CSS.................................................... 17 3.11 Appendix................................................. 17 4 Glossary 19 4.1 References................................................ 21 Bibliography 23 Index 25 i ii tryton Documentation, Release 4.8 Contents: Contents 1 tryton Documentation, Release 4.8 2 Contents CHAPTER 1 Introduction Tryton is a Graphical User Interface to the Tryton Framework based on GTK and Python. 3 tryton Documentation, Release 4.8 4 Chapter 1. Introduction CHAPTER 2 Installing tryton 2.1 Prerequisites • Python 2.7.9 or later (http://www.python.org/) • gtk+ 3.20 or later and py-gobject3 (http://www.gtk.org/) • librsvg (http://librsvg.sourceforge.net/) • python-dateutil (http://labix.org/python-dateutil) • Optional: cdecimal (http://www.bytereef.org/mpdecimal/index.html) • Optional: GooCalendar (https://pypi.python.org/pypi/GooCalendar) 2.2 Installation Once you’ve downloaded and unpacked a tryton source release, enter the directory where the archive was unpacked, and run: python setup.py install Note that you may need administrator/root privileges for this step, as this command will by default attempt to install tryton to the Python site-packages directory on your system. For advanced options, please refer to the easy_install and/or the distutils documentation: To use without installation, run bin/tryton from where the archive was unpacked. 5 tryton Documentation, Release 4.8 6 Chapter 2. Installing tryton CHAPTER 3 Client Usage This document is the reference about the concepts of the graphical user interface (also known as Tryton client ) of the Tryton application framework. 3.1 Name tryton - Graphical user client of the Tryton application framework 3.2 Synopsis tryton [options] [url] After startup the login dialog is displayed. 3.3 Options --version Show program version number and exit -h, --help Show help message and exit -c FILE, --config=FILE Specify alternate configuration file -d, --dev Enable development mode, which deactivates client side caching -v, --verbose Enable basic debugging -l LOG_LEVEL, --log-level=LOG_LEVEL Specify the log level: DEBUG, INFO, WARNING, ER- ROR, CRITICAL -u LOGIN, --user=LOGIN Specify the login user -s SERVER, --server=SERVER Specify the server hostname:port 7 tryton Documentation, Release 4.8 3.4 Environment GTKOSXAPPLICATION Activate with native Mac desktop 3.5 URL When an url is passed, the client will try to find already running client that could handle it and send to this one to open the url. If it doesn’t find one then it will start the GUI and open the url itself. The url schemes are: tryton://<hostname>[:<port>]/<database>/model/<model name>[/<id>][;parameters] tryton://<hostname>[:<port>]/<database>/wizard/<wizard name>[;parameters] tryton://<hostname>[:<port>]/<database>/report/<report name>[;parameters] where parameters are the corresponding fields of actions encoded in JSON. Note: model is for act_window Note: report must have at least a data parameter with ids, id and model name 3.6 Overview The following schematic illustration of the Tryton client shows the names of all important visual parts. Figure: Tryton client application: Client Window ________________________________________________________________ | Tryton _ o x| |----------------------------------------------------------------| Menu bar| Connection User Options Favorites Help| |________________________________________________________________| || ______| Tabs| Menu| [Tab1]|[Tab2]| [Tab3]...| |-------------|+-------++--------------------------------+| |+|| Menu Tab2|| ||-+||-----------------------------------------------|| Tool bar|||-|| New Save Switch Reload| Prev Next| Attach v|| |||-||-----------------------------------------------|| |+|| _______________________|| Search widget||-+|| Filter| *| Bookmark<-->|| |||-||-----------------------------------------------|| |||-|||| |+|||| View||-+|||| ||-|||| ||-|||| ||||| ||||| (continues on next page) 8 Chapter 3. Client Usage tryton Documentation, Release 4.8 (continued from previous page) ||||| ||||| |_____________||_______________________________________________|| |________________________________________________________________| 3.6.1 Menu Bar The menu bar is the main control unit. It provides most of the functionalities of the client application. The menu bar is grouped into categories. It is controlled with mouse or keyboard. The menu bar items are explained later. Mouse and Keyboard Use Most functions of the Tryton client can be accessed with mouse or keyboard. Key bindings for all menu items are preset. Furthermore all key bindings are manually configurable. To change the binding of a menu item the user needs to put the cursor onto it and simply press the user defined key combination. For this purpose it is needed to activate the configuration of the key bindings with Options > Menubar > Change Accelerators. After the configuration it is preferable to disable Change Accelerators, to avoid accidental changes of key bindings while navigating the Menu bar with the keyboard. To remove a key binding simply press the delete button while pointing the cursor on the menu item to change. Note: Usually key bindings are composed with modifier keys. Additionally the menu bar items are accessible with the Alt or Option key. The user needs to hold the Alt or Option key followed by the underlined character of the menu bar item to choose. To dive into deeper menu levels, he needs to release the Alt or Option key and to simply press the underlined letter of the sub menu item. If there exist several menu items with the same shortcut, repeated activation of the shortcut key will jump to the next one. The second mouse button (usually right mouse button) provides an additional contextual menu for some views and fields. In this context menu the user finds actions to copy and paste contents or selections for several fields. 3.6.2 Tabbed Main Frame This part of the client contains all the related contents and functions provided by the Tryton server modules. All aspects inside the main frame depend at least on the individual set of installed modules. The main frame provides a tabbed document interface to arrange different views side by side. New tabs are opened by special actions, like choosing a menu item or clicking some action buttons. All tabs include titles which show the name of the provided view. Tabs can be arranged by Drag and Drop. Note: Inside views there can be tabs, too. Menu The menu does not contain fixed menu items. All of them are dynamically provided by the actual set of the installed modules depending on the access rules of the current user. If a menu item is clicked, the appropriate action will open in a new tab. 3.6. Overview 9 tryton Documentation, Release 4.8 A search field allows to quickly filter the menu items by name and to search in models for which the global search is enabled. 3.7 Menu Bar Items The following section describes the function of each menu bar entry in detail. A rule of thumb: All items of the menu bar that are suffixed by three dots (. ) will open an intermediate dialog for setting up the provided menu action. Most dialogs provide a Cancel button, used to stop the complete dialog process. 3.7.1 Connection The connection menu level provides functions about Tryton server login, logout and closing the client application. Connect. By choosing this menu entry the client will be connected to an available Tryton server. A dialog opens to request credentials: • Server • Database: Database to connect server side • User name: Tryton user name to login • Password: Tryton password to login • Actions: – Connect: Connects to the server with the given credentials. – Cancel Note: Depending on server configuration for session timeout, the actual user may be logged out of the current session, and need to login again. Default timeout for inactivity logout is six minutes. Disconnect. Disconnects the client from an active server connection. In case of unsaved changes in an open tab, the Tryton client will request for saving the changes. Server (connection) dialog: This dialog is widely used to setup a Tryton server connection. This dialog shows the actual state of the client/server communication. It also shows when there is no connection to a Tryton server at all. The Change button opens a dialog for connection details: • Server: Network address or IP number of the Tryton server (protocols are not supported) • Port: Port where the Tryton server listens. Note: If there is no connection to a Tryton server, many items in menu bar and tool bar are deactivated. 3.7.2 User This menu bar item controls the preferences of the actual user. Preferences. A preference