Hi'all, The next version (15) of my tab/frame/keyboard navigation patch is ready (see bottom of this message for download instructions). This release incorporates a number of bug fixes to keyboard navigation, in response to feedback on the list. It also fixes several other bugs (see non-exhaustive list further down). And, last but not least, there are several new features: keywords, use of location bar for search, local document handling on location bar, user configurable '_blank' target, repeated search, many more configurable key bindings, etc... /* ATTENTION */ This is the first release *without the conditional compile options* for tabs and frames. Tabs, frames and keyboard navigation are standard now, and there is no provision to compile Dillo without support for these features. This is a BIG patch, with many changes. Please test it, and tell me (through the list) about any problems. New features ------------ - keywords Keywords can be used to access sites and locations with short commands in the location bar (and elsewhere). They are defined in the dillorc as a space-separated list of keyword:url pairs: keywords = "<keyword>:<url> <keyword>:<url> ..." %s is in url is replaced by (escaped) location bar contents Example: (in dillorc) keywords="s:http://www.google.com/search?q=%s" "s dillo patch" in the location bar will execute a search on google for the words 'dillo patch'. There is one default keyword, "search". This corresponds to the search_url preference. The web search feature has been changed to use the new code. Keywords currently work in the location bar, in the "open url" window and *from the command line*. This way you can search the web from the command line: dillo "search whatever you want to search for" (enter) [ programming info ] To add keyword processing to a url, you need to make an explicit call to a_Url_string_process_keywords(gchar *str). I explicitly did NOT add the keyword processing code to the default url code path, so keywords can not be initiated through external links. Better safe than sorry... - local file handling in the location bar: type a valid absolute path in the location bar and it will be transformed into a valid file: url. [ programming info ] To add local path processing to a url, you need to make an explicit call to a_Url_string_process_local(gchar *str, gboolean relative) Set relative to TRUE to include relative path processing (from the current directory) to the code path. - location bar search using keywords and/or with popup_dialogs=NO. If you have popup_dialogs=NO in dillorc, pressing the search button on the toolbar or using the search key combination (ALT-s) will search the web for whatever you typed in the location bar (if you have entered search terms) or focus the location bar with the search keyword set. In the latter case just add search terms and press enter to search. - location bar contents are selected when it is focused, deselected when the content area is focused. - the contents of the findtext and websearch entries are selected when they are re-opened. Type a new search term to replace the old term. Use the cursor keys to deselect the contents when you want to add to the existing search term. - the splash screen no longer lives in the binary (as suggested by Indan Zupancic). It is installed by the makefile and should be distributed with dillo. The default location is in the 'sharedstate' directory (default /usr/share/dillo/dillo.html). There is a preference for those who want to change this: splash = NO | <url> This takes any url. Set it to NO to suppress the splash screen alltogether (you will still be able to get to the splash screen by visiting about:splash). The default value is defined in prefs.h: #define DILLO_SPLASH "file:/usr/share/dillo/dillo.html" - There is a new preference for control of the "_blank" tag and handling of new windows in general (as suggested by Andreas Schweitzer): target_blank = SELF | TAB | [WINDOW] Set this to "self" to disable the "_blank" target (no more new windows popping up all around). The other two settings are self-explanatory I guess... This also works for documents opened using the middle mouse button, and documents opened on the command line. For the latter the "self" setting is ignored (it defaults to new windows in that case). - Repeated search by pressing CTRL-g at any time. Unhiglight search by pressing Escape. If search resulted in a highlighted link, this will be unhighlighted as well (to follow that link, press Enter instead of Escape). - many more configurable key bindings. To avoid overloading the scrolled_frame with content-related signals I added a general 'content_command' signal, which gets passed one parameter of type DilloCommand (defined in commands.h). To adjust a keybinding for a command, set a key for the signal 'content_command' for the widget named 'dillo-content' (or for the class GtkDwScrolledFrame). As an example the following binding sets the 'F3' key for the 'repeat find' command (like it does in Mozilla): key_bindings = "binding 'mozilla-keys' { bind 'F3' { 'content_command' (9) } ... (add more bindings if needed) ... } widget '*dillo-content' binding 'mozilla-keys'" There are currently 30 available commands: DILLO_COMMAND_NAVIGATE_BACK, /* 0 */ DILLO_COMMAND_NAVIGATE_FORWARD, /* 1 */ DILLO_COMMAND_NAVIGATE_RELOAD, /* 2 */ DILLO_COMMAND_NAVIGATE_STOP, /* 3 */ DILLO_COMMAND_NAVIGATE_HOME, /* 4 */ DILLO_COMMAND_DUPLICATE_WINDOW, /* 5 */ DILLO_COMMAND_DUPLICATE_TAB, /* 6 */ DILLO_COMMAND_FINDTEXT, /* 7 */ DILLO_COMMAND_FINDTEXT_INCREMENTAL, /* 8 */ DILLO_COMMAND_FINDTEXT_REPEAT_LAST_SEARCH, /* 9 */ DILLO_COMMAND_FINDTEXT_UNHIGHLIGHT, /* 10 */ DILLO_COMMAND_SAVE, /* 11 */ DILLO_COMMAND_SAVE_LINK, /* 12 */ DILLO_COMMAND_BOOKMARK, /* 13 */ DILLO_COMMAND_NEW_WINDOW, /* 14 */ DILLO_COMMAND_NEW_TAB, /* 15 */ DILLO_COMMAND_OPEN_FILE, /* 16 */ DILLO_COMMAND_OPEN_URL, /* 17 */ DILLO_COMMAND_OPEN_LINK, /* 18 */ DILLO_COMMAND_OPEN_LINK_NEW_WINDOW, /* 19 */ DILLO_COMMAND_OPEN_LINK_NEW_TAB, /* 20 */ DILLO_COMMAND_CLOSE_WINDOW, /* 21 */ DILLO_COMMAND_CLOSE_TAB, /* 22 */ DILLO_COMMAND_EXIT, /* 23 */ DILLO_COMMAND_TAB_PREVIOUS, /* 24 */ DILLO_COMMAND_TAB_NEXT, /* 25 */ DILLO_COMMAND_VIEW_SOURCE, /* 26 */ DILLO_COMMAND_VIEW_BOOKMARKS, /* 27 */ DILLO_COMMAND_FOCUS_LOCATION, /* 28 */ DILLO_COMMAND_WEBSEARCH, /* 29 */ DILLO_COMMAND_TOGGLE_FULLWINDOW /* 30 */ DILLO_COMMAND_FOCUS_ACTIVATE, /* 31 */ DILLO_COMMAND_FOCUS_ACTIVATE_NEW_WINDOW, /* 32 */ DILLO_COMMAND_FOCUS_ACTIVATE_NEW_TAB, /* 33 */ DILLO_COMMAND_FOCUS_POPUP, /* 34 */ DILLO_COMMAND_FOCUS_HIDE, /* 35 */ DILLO_COMMAND_FOCUS_MOVE_UP, /* 36 */ DILLO_COMMAND_FOCUS_MOVE_DOWN, /* 37 */ DILLO_COMMAND_FOCUS_MOVE_LEFT, /* 38 */ DILLO_COMMAND_FOCUS_MOVE_RIGHT, /* 39 */ DILLO_COMMAND_FOCUS_MOVE_TAB_BACK, /* 40 */ DILLO_COMMAND_FOCUS_MOVE_TAB_FORWARD, /* 41 */ DILLO_COMMAND_SCROLL_UP, /* 42 */ DILLO_COMMAND_SCROLL_DOWN, /* 43 */ DILLO_COMMAND_SCROLL_LEFT, /* 44 */ DILLO_COMMAND_SCROLL_RIGHT, /* 45 */ DILLO_COMMAND_SCROLL_PAGE_UP, /* 46 */ DILLO_COMMAND_SCROLL_PAGE_DOWN, /* 47 */ DILLO_COMMAND_SCROLL_PAGE_LEFT, /* 48 */ DILLO_COMMAND_SCROLL_PAGE_RIGHT, /* 49 */ DILLO_COMMAND_SCROLL_EDGE_TOP, /* 50 */ DILLO_COMMAND_SCROLL_EDGE_BOTTOM, /* 51 */ DILLO_COMMAND_SCROLL_EDGE_LEFT, /* 52 */ DILLO_COMMAND_SCROLL_EDGE_RIGHT /* 53 */ If you'd like to see any other commands, tell me or the list! [programming info] To add a new command, simply add the name to the DilloCommand enum, add a handler to a_Commands_handler() and, optionally, add a default key binding to a_Commands_init(). The commands.[ch] files are in a bit of a state of flux, as many commands are currently present in two forms: one with a *dd interface, the other (older) with a *bw interface. Where appropriate the older (*bw) versions can and will be removed - the View Source window can now be closed by pressing Escape. View source is (over)due for an overhaul by the way. I might implement the view-source protocol in one of the next patches. - Tab movement is now cyclic, thanks to a patch by Stephan Goetter - the Frame context menu now has navigation controls (as suggested by Stephan Goetter), so it is possible to go back in the frame history. The main history is not yet synchronised with frame actions. [LIST: Is this necessary? Should the 'back' button and menu remember actions inside nested frames or should it do what it does now, remember actions in the top-level document?] - Keyboard navigation can be used to popup context menus, as suggested by Melvin Hadasht. The default binding for context menu is Alt-Enter (and Alt-KP_Enter). The related DILLO_COMMAND is DILLO_COMMAND_FOCUS_POPUP. Fixed bugs ---------- keyboard navigation - all known segfaults - most 'weird navigation order' problems - related issue (now fixed in CVS): a_Findtext_search returned FALSE (instead of FINDTEXT_NOT_FOUND) when a search was performed on an empty page. Since this function is supposed to return a FindtextResult enum value (and the first value in that enum is FINDTEXT_SUCCESS) this made the focus code try to focus a link in an empty page leading to a segfault in the scrolled_window. document abstraction - a problem with tab/page duplication which had the potential to cause segfaults is fixed - selection copy did not work because I forgot to set the owner for the selection in tab mode. This is fixed. REMOVED PREFERENCES =================== These preferences have been removed from the patch. Update your dillorc if you used them. Complain to me (on the list) if you want them back. * tab_instead_of_window: merged into the new target_blank pref * focus_location_on_new: did anyone use the NO setting? * tab_bar_homogeneous: did anyone use the NO setting? * compress_vowels: can be changed during compile if needed, COMPRESS_VOWELS in src/misc.h CHANGED KEY COMBINATIONS ======================== * Internet search: ALT-s (was CTRL-g, CVS CTRL-s) * Repeat search CTRL-g (was nothing, CVS nothing) * View source: ALT-u (was CTRL-u, CVS nothing) * Open URL: CTRL-l (was SHIFT-CTRL-l, CVS CTRL-l) * focus location bar: CTRL-u (was CTRL-l, CVS CTRL-u) If you want the old keys back, add a binding for the related command (see above) If something doesn't work they way it should (or the way you *think* it should), I want to know! For more info on keyboard navigation, see the doc/Keyboard_Navigation.txt document (after applying the patch, naturally...). More information on tabs can be found in doc/Browser_Tabs.txt, for frames see doc/Browser_Frames.txt. The mailing list archives are also a good place to look for answers to questions relating to this patch. REMOVED COMPILE OPTIONS ======================= * --disable-tabs Tabs are a fixed part of the code now * --enable-xhtml-dtd Full frameset support is a fixed part of the code now TODO ==== - add x scrolling capability to Dillo (change anchors, URL_POS, scrolling functions, iterators, etc...). This is needed for better keyboard navigation on wide pages. Tabs, Frames and browser bloat ============================== version: 0.8.0-pre patch: dillo-20031121-tabs.patch.gz unpatched: 297172 bytes patched: 333364 bytes (gcc 3.2.2, binutils 2.13.90.0.18, CFLAGS "-Os") Download instructions ===================== The patch is made against 20031119@15:09 CVS. Do not forget to run ./autogen.sh after applying the patch. You can find the patch on the usual (ad-happy, use an ad-blocking proxy or sane browser) site: http://www.geocities.com/ikbenfrank/ More specifically: Dillo 0.8.0-pre (CVS) ===================== http://www.geocities.com/ikbenfrank/dillo-20031121-tabs.patch.gz size: 116678 bytes (gzipped, as downloaded) 529298 bytes (uncompressed) md5sum: 846a6be5100809cd95553e2cae595f3b (gzipped, as downloaded) 7a94882aa87a8787d959105231fcfacf (uncompressed) As always, check the site for the most recent version Cheers//Frank -- WWWWW ________________________ ## o o\ / Frank de Lange \ }# \| / +46-734352015 \ \ `--| _/ <Hacker for Hire> \ `---' \ +31-640037120 / \ frank@unternet.org / `------------------------' [ "Omnis enim res, quae dando non deficit, dum habetur et non datur, nondum habetur, quomodo habenda est." ]