22. System tray and auto-start

22.1 Minimise to tray

Settings → General → Minimise to system tray. Once enabled, closing the window (⌘W / Alt+F4) hides to the tray instead of quitting; the tray menu has:

  • Show window
  • Settings
  • Check for updates
  • Quit

On macOS the first toggle may need a restart.

22.1.1 Confirmation before quitting

If something is still unfinished, quitting asks first, so half-finished work isn't thrown away. All four ways out are covered by this confirmation: the title-bar close button / ⌘W, the tray menu's "Quit", ⌘Q, and the application menu. With nothing outstanding it just quits without bothering you.

The 9 situations that stop you:

Situation What quitting costs you
Attachments are still being copied The copy is interrupted; you'd have to attach them again
Session history is being compacted The compaction is wasted, and the quota it already spent is gone
A task is still running The unfinished answer is cut off
Sub-tasks are still running Delegated sub-tasks are terminated along with it
A routine is running A missed routine isn't re-run
Messages are still being delivered Pending messages may be lost
A workspace is still connecting The connection is interrupted
Changes you haven't reviewed The change list lives in memory only and is cleared on quit
You're sitting in Settings / the agent manager You may think you're back in the workspace when you aren't

The confirmation offers three choices: Quit anyway, Stop everything and quit, and Back to workspace (worded to match whichever reason stopped you); clicking the scrim is the same as cancelling.

22.2 Auto-start at login

Settings → General → Start at login. Once enabled, the system silently starts AVL Code into the tray on boot.

22.3 Silent mode

With tray + auto-start both on, AVL Code starts silently by default — the main window doesn't appear; tray icon only. Click the tray to bring up the main window.

22.4 Remember window state

Settings → General → Remember window state (on by default). On, remembers and restores your last window size / maximised state; off, every launch uses an adaptive default size, centred, with no writeback at exit ("neither remember nor restore"). Existing configurations are auto-defaulted to on.

On high-DPI / zoomed screens (1080p at 125% / 150%), startup auto-shrinks the default size to fit the available area (height ×0.90 / width ×0.95) and centres it; moving to a smaller screen also clamps the remembered size within bounds so it can't fall off-screen. Large screens keep the full 1400×900.