-*- indented-text -*-

TODO list for sawmill
*********************

Bugs are marked !, things that should be done soon are marked +,
and longer-term ideas are marked -



Outstanding bugs
================

  ! `:type (or ...)' doesn't get serialized

  ! Everytime my system's hardware clock get's resetted (this happens
    from time to time because my motherboard's battery has become a
    little weak), my whole sawfish configuration is erased and replaced
    with the default settings. Btw, the 'new' system time becomes
    01/01/1977 after the reset. [gnome #14623]

  ! underscores in window names create accelerators in menus

  ! raise-groups-on-focus is commented out

    should raise transient groups, but this may have the same problem..?

  ! running multiple instances of the wm loses

    (because they share the same ~/.sawmill/custom file)

  ! keeping unshown windows unmapped isn't so great?

    the ICCCM says that to go to Withdrawn state a window must send a
    synthetic UnmapNotify, so this is not a problem. But it also says:
    `NormalState - the client's top-level window is viewable'

    one option is to set all hidden windows to IconicState. But this
    would probably confuse the tasklist applet..

    [ I have a patch to do this, and it totally breaks the workspace
      handling of desk-guide and the tasklist ]

  ! cancel the GNOME logout dialog, window decorations aren't redrawn

    [ after looking at the X event trace, I don't think it's a sawmill
      bug, since sawmill receives _no_ events after the iris effect is
      removed, until it finally redraws everything. Unless sawmill is
      somehow not recognizing that events are available..? ]

  ! play-sample.c doesn't seem to work on solaris (esdplay does)

  ! anim-outline just guesses where windows will be iconified to, so it
    usually gets it wrong

    [ the new GNOME/KDE wm hints have support for this ]

  ! timestamp ordering code falls over with machines that vary their
    clock rate..

  ! loading theme `Ganymede' into themer wedges it

  ! loading a session shifts window positions by the frame offset

    [ this only happens with apps that try to save and restore their
      own geometry (e.g. gnome-terminal); this is against the ICCCM... ]

  ! swapped-out window properties aren't saved with session

  ! * Open Netscape
    * Click the botton on the status-bar that brings the little
      browser/mail/news/editor toolbar into its own window.
    * Now iconify this window - instead of being iconfied on its own, it
      goes back onto main netscape browser window as if it was closed
    * Now open it again - SLAM!
    * Suddenly the window opens and closes like mad causing the window to
      flicker on the desktop so fast you can't click on anything to get
      rid of it, and you have to 'kill' it (sometimes it eventually dies
      on its own in a minute or two).

  ! xv/java-apps get weird placement [apps being non-ICCCM compliant?]

  ! the gnome _WIN_MAXIMIZED_ hints are ignored when the window is
    mapped, since it's not possible to maximize the window at that
    point (until the frame has been created)

  ! turn off mouse warping options, put cursor in window in center of
    screen (under message window), M-TAB, and the pointer leaving the
    message window will refocus the original window

  ! I bring up an exmh transient, and place it so it's totally enclosed
    by the exmh parent window.  I put my mouse in the middle of the
    transient so it has focus (I'm using sloppy focus.)  I then move to
    a different desktop, and back. The transient window has focus still
    (ie. I can type in it), but the frame is drawn in the unfocused
    style.

  ! edge-flipping while interactively placing a window can leave
    rubber-band traces [this is hard to fix..]

  ! if i press M-button1 (move-window-interactively) but not move the
    window and _hold_ button1, it gets raised, but the window
    decoration is not drawn, only if i move the window or release the
    button

  + write documentation: workspaces, viewports, window groups, alist
    frame patterns, frame parts as objects, placement, focus modes,
    symbolic event structures...

  + allow enter/leave-notify events to be suppressed?

    (use this when switching workspaces, but focus must be preserved)



Window manager tasks
====================

  + aspect ratio hints

  + when M-TAB'ing windows, display window icon in status message

  + look into tear-off menus

    need some way of notifying when dynamically generated menus have
    changed

  + some hci ideas:

    placement mode to favour some/any of:

	- near other windows in the same group

	- extend cost components to include overlap, instead of overlap
	  being non-negotiable (i.e. able to trade overlap for locality)

    theme that has visual cues (colours?) for group membership

  + look at kde khotkeys for ideas

  + support the new GNOME/KDE wm interaction protocols

    the spec isn't finalized yet, but it has been 99% for a while..

    [ I've implemented most of the draft spec now ]

  + sound themes

  + drag-and-drop to configure window appearance?

    this could depend on the theme, but it would be good to allow
    dropping of colors (gradients?) and images for at least some themes

    add a hook (frame-part-drop-hook?)

    also allow theme files to be dropped on windows

  + add a (destroyed . FUN) attribute to display-message

    also allow multiple messages to be displayed/managed

  + allow transparent backgrounds to frame parts

    need to use overlays, solaris X server supports two types, what
    about XFree?

  + add option to prevent workspace switching while cycling

  + threshold options to control window-move sensitivity?

  + in interactive placement, allow the window-pointer position to be
    configurable 

  + allow configuration of where move/resize display appears

    allow relative to window, or relative to root, for both x and y

  + Handle multiple-screen displays

    What are the issues? Multiple root windows, and..?

    [ use `Xnest -scrns N' to simulate multi-heading ]

  + Add checked and radio menu item support

  + Icons (?)

    Icons could be handled using a special frame/window type

  - Rotated text

    Allow text to be rendered at angles (in multiples of 90 degrees?).
    This could be useful for the sides of windows

    [ scp found a library for doing this with Xlib.. ]

  - GTK theme

    Is there any way that the gtk theme could support engine-based GTK
    themes? Probably not without using a subprocess (since the engines
    are written to GDK, not Xlib), this could get hairy..

    Also, why do themes with bg_pixmap set use so much memory? Is it
    just because the images are XPM's..?

    re: engines, now that frame parts are proper objects, and thus
    fg/bg specifiers may be functions, it should be possible to spawn a
    GTK slave to do all redrawing (using the gtk_draw_foo functions)

    have to be careful to avoid deadlocks though. Maybe avoid using
    fifos for this reason, perhaps use SYSV shared memory segments and
    semaphores?

    [ I have a patch that does a first approximation of this, the
    problem however is that GTK doesn't have enough drawing primitives 
    to cleanly handle all buttons etc.. ]

  - Remove root menu?

    The argument is that doing this removes the need for the wm to
    select ButtonPress events on the root window (which is a point of
    conflict with, for example, a desktop file manager)

    The sole need for the wm to manage the root menus (as far as I can
    see) is so that it can offer window management functions (such as
    "interactively move the focused window" or whatever), but all
    these things can be invoked through sawmill-client, i.e.
    "sawmill-client -c move-window-interactively"

    With a bit of work the dynamically generated menus (e.g. the window
    and workspace submenus) could also be generated through the client

  - CORBA interface

    I have a prototype idl, but it needs rewriting. The idea is to
    basically reimplement the new GNOME/KDE wm hints using CORBA,
    perhaps with some other useful features

    Use rep-orbit to provide the CORBA binding



ui tasks
========

see nokogiri/WISHLIST



themer tasks
============

  ! only the `default' window type may be previewed

    [ workaround: temporarily change the `default' mapping ]

  + allow functional frame part attributes to be defined

    possibly add an `(extra sexp)' field that is evaluated then added
    to the end of the frame part definition 

  + allow dynamic patterns to be defined (e.g. gradients)

  + better previewing:

    * highlight the current frame part somehow

    * clicking/hovering on a frame part selects that definition

    * auto-update, either after each change, or from the idle-hook?

  + support a pseudo-pattern containing the window's icon
