Wichert has been fiddling with a possible GUI design for APT, here it is.. Jason
Hi there! I just sat down and finished the last couple of sections. The only things that might still be added are details on the layout of some items. The new extensions with respect to multi-CD support might also warrant some changes, although they should be trivial. Comments are welcomed as usual, but I think we can send this off for a public review on debian-devel sometime this week.. Wichert.
Apt UI design 1. Introduction --------------- This document describes the design of Apt (A Package Tool). It documents what Apt is meant to do and describes the user interface. It does not attempt to document how Apt internals will work. 2. Purpose ---------- The purpose of Apt is to be a replacement for dselect, the tool Debian GNU/Linux has used for a long time to manage selecting, installing and removing packages. Using Apt it should be possible to select packages for multiple sources, manage the list of packages, navigate through them and fetch them. Normal low-level tools (like dpkg) are used for the actual installation, configuration and removing of packages. 3. User interface principles ---------------------------- 3.1 goals Apt should be usefull on all systems running Debian GNU/Linux (or any other form of Linux). This means that it should be able to run on text consoles. In modern times an X interface is also expected, so Apt will provide that as well. For simpler needs which don't need user interaction there is also a command-line tool (apt-get) to do things like complete upgrades and installation/removal of single packages. 3.2 Interface conformance The best aspect of modern user interface is that they share a common philosophy with respect to handling windows, the mouse and keyboard commands. This assures that user do not need to learn a completely new interface and that intuition will generaly give good results. Apt will try to conform to established standard methods by using standard keyboard shortcuts and mouse commands. A list of common keyboard shortcuts that will be used are: Space Toggle current entry or drop down list Enter Execute/Enter current entry Tab Jump to next pane/frame Shift-Tab Jump to previous pane/frame + Expands the selected node in a tree - Collapses the selected node in a tree Up-arrow Move cursor up one entry Down-arrow Move cursor down one entry Left-arrow Move cursor left one control Right-arrow Move cursor right one control Page-Up Move cursor up one page of entries Page-Down Move cursor down one page of entries Alt-<key> Used to select a Menu directly (e.g. Alt-F opens the File Menu) Ctrl-<key> Keyboard accelerators for Menu items F10 (or right mouse button) - Popup menu (context sensitive) Please note the popup-menu need not be available in all contexts. Documenting standard mouse commands is out of scope for this document. Any text on UI standards should suffice on this point. 3.3 Saving state Apt will try to save the state when shutting down so that the user will can continue where he/she left of before. Apt will save the following information: user preferences, other options, position & sizes of windows for the current interface method (ie X11 and console information will be stored seperately) and package selection-states. 4. Using Apt ------------ 4.1 First usage The first time Apt is run the user should be presented with a number of questions to determine the minimal configuration. At the moment this is only the list of packages sources. After the user answers these he/she will continue to the normal main screen. 4.2 The main screen The main screen is the screen from which the user can select packages to install/upgrade/remove. There are also option to manage the list of packages displayed, search for packages and show extra information on packages. 4.2.1 The package list The number of Debian packages is currently at about 2200, and still growing. This means the user can select from a bewildering number of packages. Managing this list is not a simple task. Apt will not try to limit the user in any way in selecting and viewing packages. Instead the user gets full control over the list of displayed packages: he/she can select from which sources packages, from which sections and for which priorities packages are displayed. Only packages which meet these criteria are shown in the main package list. 4.2.2 Searching packages There are two methods to look for packages: the user can either narrow down the list of packages by selection the source, section or priority to manage the main package list. The other method is a seperate `search package' option. With this command the user can select more criteria, such are words to search for in the description, maintainer names, etc. All packages which meet this criteria are then displayed in a window with search results, ordered by likeliness. This search command will use the same filtering as is used for the main package list. A package can be selected from this list and the focus will jump to that package in the main package list. 5. Package management --------------------- Apt will not handle package mangement itself: it will call a low-level tool (like dpkg) to handle the actual installation, configuration or removal. Apt will try to make all options of the tool available via its userinterface, but for some things manual interaction will still be required. 5.1 Obsolete packages dselect tries to handle obsolete packages by marking all installed packages which are not in any source as obsolete. Unfortunately this is not really correct behaviour: a source might become unavailable temporarily for example. Apt will not try to detect obsolete packages. Instead a special source called `unknown' is added to the list of sources which contains all installed packages which have no known source. 5.2 Automatically installed packages Occasionaly if the user selects a package other packages also have to be installed to satisfy dependencies. Apt will remember which packages where not manually selected but only installed to satisfy the dependency of another package. Later when Apt is doing a complete run or only removing packages it can detect which of these automatically installed packages are no longer needed and remove them. This automatics removal can be toggled on or off. 5.3 Multiple package version It can happen that multiple version of the same package are available for selection (for example of both the stable and unstable tree from Debian are listed as sources). Apt can switch between two behaviours when encountering this: it can either always select the newest version, or it can use a preferred source. The preferred selection is the selection that is first listed in the list of sources. 6. User interface ----------------- 6.1 Package-selection screen The package-selection userinterface for Apt is very simple: there is one screen in which a menu, a toolbar, the package list and package information is shown. For frontends which support it the package list and package information panels are seperate windows which can be resized and moved within the main window. For other interfaces non-resizable panels will be used. 6.1.1 The menu The menu contains all commands the user can perform. This includes managing the package list, performing actions on packages, changing options, etc. The complete menu is: Actions: Complete run Install new packages Remove packages Upgrade packages ------------------- Quit Package: Configure Install Reinstall (upgrade/downgrade) Remove Hold Options: List preferences (dialog to change columns shown and sort order) System preferences (general Apt preferences) Sources Advanced: Export packagelist Import packagelist Help: Context ------- About 6.1.2 The filterbar To manage the list of packages there are three filters available through the filterbar: selection by source, section, priority and status. This part of the toolbar looks like this: +--------------------------------------------------------------------------+ | | Sources V | | Sections V | | Priority V | | Status V | | +--------------------------------------------------------------------------+ If you click on the `V' (downward pointing triangle) next to the name of the filter or hit the right key-combination (Alt-S for sources for example) a list drops down in which can you can select the filter details. For example: +--------------------------------------------------------------------------+ | | Sources V | | Sections V | | Priority V | | Status V | | +--------------------------------------------------------------------------+ | [X] base | | [ ] comm | | [X] devel | | [ ] doc | .... 6.1.3 The Package list This is the largest part of the screen. It lists all package which pass the current filter. For each package at least the package name is displayed, and optionally more information. The list is displayed in a format very much like the explorer Windows uses: there is a row for each package, and one or more columns displaying information about the package. The user can toggle which columns are displayed. The currently defined columns are: * package name * package status * section * priority * status * installed version * available version * source 6.1.3.1 Context-menu (popup) The packagelist is one of the screen which has a context-menu. If the users requests the context-menu Apt will offer the following items: * Change columns shown (submenu) + show priority (toggle) + show status (toggle) + etc. * Order by (submenu) + packagename (toggle, only 1 selected) + status (toggle, only 1 selected) + section (toggle, only 1 selected) + source (toggle, only 1 selected) + priority (toggle, only 1 selected) * Panels (submenu) + package description (toggle) + package information (toggle) ----------------------- (seperator) * Mark for hold (command) * Mark for install (command) * Marf for purge (command) * Mark for removal (command) * Show all information (command) Please note the sorting algorithm used should be stable, so the user can customize the sorting-method in any way he/she likes. Some commands deserve a short explanation: * Panels / package description: toggles if the package description panel should be displayed or hidden * Panels / package information: toggles if the package description panel should be displayed or hidden (defaults to off) * Show all information: popup a window with detailed information on the package. See section 6.1.6 for details in this window. 6.1.4 Available shortcuts All keyboard-shortcuts and mouse-commands listed in 3.2 will be available. There is also an extra set of commands available which are specific for this window: = Mark package for hold + Mark package for installation - Mark package for removal _ (underscore) Mark package for purge Enter Do nothing, move focus to next package Shift-Enter Show all information on package F3 Open the package-search dialog 6.1.5 Package information panels Apt has two information panels: package information and packages description. The description-panel shows the extended description as found in the control file from the package. The informatino package shows all other information, suchs as maintainer, dependencies, suggests, provides, etc. 6.1.6 Package information window This window shows all information on the current package. Part of this information is already shown in the two panels described above, but since they need not be visible at all times this window also shows that information. Besides the information there is also a button which can take you directly to a webpage from the bugtracking-system which lists all bugs for this package. The layout looks like this: +======= Information on fubar ========+ | | | +---------------------------------+ | | | Version: 1:2.4-1 ^ | | | Maintainer: John Doe <jdoe@debi # | | | Depends: libc6 | | | | Conflicts: fubar0 (<= 2.4) | | | | Installed-size: 142Kb | | | | . | | | | . | | | | . | | | | . | | | | . V | | +-<# - - - - - - - - - - - - - ->-+ | | | | +------+ +------+ +------+ | | | Back | | Bugs | | Help | | | +------+ +------+ +------+ | | | +=====================================+ 6.1.7 Handling special relations Debian supports a number of relations between packages. These can require extra input from the user to resolve problems. We'll discuss each relation and how we handle it shortly. Apt will try to assemble the questions it needs to ask the user so the number of prompts is reduced as much as possible. 6.1.7.1 (Pre-)dependencies If a package is (possibly automatically) marked for installed Apt will check if that package (pre-)depends on other packages. If so these packages should also be installed. Depending on how Apt is configured it can do two things: it can either marks dependant packages for installtion automatically, or it can ask the user if he/she agrees with installing those packages. If the user disagrees the request for installation is cancelled. Automatic installtion can be toggled seperately for packages which should be upgraded or packages which should be newly installed. 6.1.7.2 Conflicts Occasionally a package conflicts with a packages that is installed or marked for installation. If Apt detects this it should ask the user if he really wants to install the package, noting that other packages must be removed to allow this. 6.1.7.3 Recommends Some packages can be installed on their own, but need other packages for some of their functionality. When the user selects a package which recommends other packages Apt will ask the user if he/she wants to install these packages as well. 6.1.7.4 Recommends Some packages can be enhanced by installting other packages. When the user selects a package which suggets other packages Apt will ask the user if he/she wants to install these packages as well. 6.2 Download-screen The download-screen is shown when Apt is downloading the packages to be installed. The information shown is: * progress total download * progress current package * size of remaining stuff to download * expected time of download completion * abort button 6.3 Installation screen When all packages are downloaded Apt will start installing them. This is down using dpkg. Currently this means that the installation-process has to run in a window (or full-screen if the frontend does not supprt windows) in which dpkg's input and output are shown, so the {pre,post}{inst,rm} scripts are run correctly. In the future this screen can be replaced with another frontend for a new package-configuration system. 7. Dialogs ---------- Apt has multiple dialogs This section describes each dialog. Please note that all dialogs are application modal (ie while a dialog is displayed all other parts of Apt are non-active, but the user may still switch to different programs). 7.1 List options Using this dialog the user can fine-tune the method in which the packagelist is displayed. Currently defined options in this dialog are: * Sort order. You can sort by multiple keys, so the order can be fine-tuned. The user must be able to change the sort order. An example: Sort by: [ 3 ] packagename ascending [ 1 ] priority descending [ 2 ] source ascending This will sort first by priority, with the highest priority first. Packages with equal priority are then sorted by archive source. Packages with equal priority and source are then sorted by packagename. This can easily be implemented by sorting first on packagename, then on source and finally on priority using a stable sorting algorithm. * Columns shown (can also be down using the pop-up menu) Shows a list of all possible columns that can be shown in the packagelist. The user can toggle for each column (except packagename) if it should be shown or hidden. * Toggle if Apt should automatically select the newest version of a package, or the version from a preferred source. This is only relevant if multiple versions of the same package are available. 7.2 System options This dialog contains information about the Apt in general. The currently defined options are: * toggle if Apt will attempt to automatically remove no longer needed packages * toggle if packages which are installed to meet dependencies may be upgraded silently or if Apt should ask for confirmation * toggle if packages which are newly installed to meet dependencies should be installed silently or if Apt should ask for confirmation 7.3 Sources selection In this dialog the user can select from which sources packages are available. Please note that the user must also be able to change the order of the source, since the order can be used to determine which package should be instaled if multiple versions are available. 7.4 Package search On occasion the user will want to search the packagelist for a specific package. To make this possible Apt has a package search-dialog. In this dialog the user can select a number of criteria for the wanted package. After selecting this Apt will present the user with a list of packages which meet the given criteria. The dialog will allow the user to select the following criteria: * packagename (substring match) * (extended) description (subtring match) * maintainer (substring match) * source * section * priority The resulting list of packages will be sorted by match-likelyhood. When the user selects a list in the list of found packages Apt will go back to the packagelist and will move the focus to the selected package. Please note that the package search will honour the filter that the user has given for the package list.
Attachment:
pgp2sm5UuU7tl.pgp
Description: PGP signature