Ideas about windows in windows.

Requirements
------------

*  Old applications should work without modification.

*  Windows should be openable within another application's window (Hyperhype
and all that).


Issues
------

This section should end up with no entries.

*  Screen size: some applications rely on being able to get the screen size.
Currently the screen size is a VDUVariable. Applications should read the
size of the window they're in to get this value.


Implmentation
-------------

*  Windows inside windows receive all events as windows not inside windows.

*  A window inside a window is positioned relative to the window it's
inside's work area origin.

*  There is an outer-most window, the desktop, which every other window is
in.

Individual SWIs
---------------

Wimp_Initialise

Must specify a large enough Wimp version number for the windows in windows
feature to be accessible to the application.


Wimp_CreateWindow

As for Risc OS 2.00, except:

R1+24   handle to open window behind.
                *  Windows in windows are invisible to applications who
                don't know about this feature.
                *  Openning behind a window inside a window will open the
                window inside the window the window you're openning behind
                is in.
                *  Openning at top (-1) opens in outer-most window (the
                desktop) as before.
                *  Openning at botton (-2) opens in outer-most window (the
                desktop) as before.
                *  Openning behind <wind>+32768 opens at top inside <wind>.
                *  Openning behind <wind>+65536 opens at bottom inside
                <wind>.

R1+28   Window flags:
                All flags as before, except:
                *  When bounded, a window is bounded by the work area of the
                window it's in.
                *  'Back' means back of stack of windows inside the window 
                his window is in.
                *  Hot keys are passed to all hot key windows, in the order:
                        Parent
                                child
                                child
                                        child
                                        child
                                child
                        Parent
                                child
                                child
                                child
                in the obvious fassion.
                *  Window has input focus indicates that this, or a window
                inside this has the input focus.


Wimp_CreateIcon

Icons get displayed behind all windows inside a window.


Wimp_DeleteWindow

All windows inside a deleted window get closed.


Wimp_DeleteIcon

No change from Risc OS 2.00


Wimp_OpenWindow

R1+28 is as per R1+28 in Wimp_CreateWindow.


Wimp_CloseWindow

Windows inside the window being closed get closed.


Wimp_Poll

All reason codes are the same except:

Open request block is as passable to Wimp_OpenWindow. An open request is not
generated for windows inside the window being moved. The position on the
screen will have changed, and so a window's position can't be relied to
remain the same across Wimp_Polls if that window is inside another.

Scroll request block starts as per the block passed to Wimp_OpenWindow.


Wimp_RedrawWindow

Open block part of Wimp_RedrawWindow is as per Wimp_OpenWindow.


Wimp_UpdateWindow
Wimp_GetRectangle

No change.


Wimp_GetWindowState

Changed as per Wimp_OpenWindow


Wimp_GetWindowInfo
Wimp_SetIconState
Wimp_GetIconState

No change.


Wimp_GetPointerInfo

No change. Note that the pointer is considered over the inner window not the
outer one.


Wimp_DragBox
Wimp_ForceRedraw

No change.


Wimp_SetCaretPosition

No change. The caret is considered to be in a layer above the icons and
below any windows inside the window the caret is in.


Wimp_GetCaretPosition

No change.


Wimp_CreateMenu

No change. Menus are always created inside the desktop window. Dialogue
boxes should similarly be opened in the desktop window.


Wimp_DecodeMenu
Wimp_WhichIcon
Wimp_SetExtent
Wimp_SetPointerShape
Wimp_OpenTemplate
Wimp_CloseTemplate
Wimp_LoadTemplate
Wimp_ProcessKey
Wimp_CloseDown
Wimp_StartTask
Wimp_ReportError
Wimp_GetWindowOutline
Wimp_PollIdle
Wimp_PlotIcon
Wimp_SetMode
Wimp_SetPalette
Wimp_ReadPalette
Wimp_SetColour
Wimp_SendMessage
Wimp_CreateSubMenu
Wimp_SpriteOp
Wimp_BaseOfSprites
Wimp_BlockCopy
Wimp_SlotSize
Wimp_ReadPixTrans
Wimp_ClaimFreeMemory
Wimp_CommandWindow
Wimp_TextColour
Wimp_TransferBlock
Wimp_ReadSysInfo
Wimp_SetFontColours

No change.