Hi.
First, let me apologize for not noticing the sm option replication. Mea culpa.
Now to the point. I went ahead and tested the sm, and ran into a problem: in the X11 session, the geany instances are stored both as Client_ (by sm.c) and Legacy_ (by gtk/gdk, as in 0.18).
Normally a gdk_set_sm_client_id(new_client_id) would fix this, but there is a side effect. The XSM window settings (maximized state, desktop# etc.) are applied to the first window open by the session client, and since sm_init() is run after the main geany window is created:
1. Geany always appears on the first desktop. 2. If you choose File -> Open or Edit -> Preferences, and geany was maximized, the Open or Preferences dialog appears maximized instead. That depends on the dialog, for example, Open may also "appear" minimized, while Find seems unaffected.
Using gdk_set_sm_client_id() and moving sm_init() before main_init() will fix this, and since sm_init() is very limited, that shouldn't break anything... but I'm not sure.
-- E-gards: Jimmy