A long time ago I discovered a configuration program which allowed you to set
the NoObscureIconBar bit (as noted it OSLib) in CMOS RAM, although there is
no actual use for it as the Wimp pays no heed what-so-ever to it. The
application was Config+, and whilst being an excellent utility it is somewhat
lacking by the fact that some of the options do not work (eg 3rd Party
crashed on my Machine), and the above flag does nothing. Whilst this is not
the programmers fault, I did find it a little annoying that the program could
not easily allow other users to write configuration programs in the same
vein.
Later, I saw an article in Acorn User about possible new features which might
appear in RiscOS 4. Whilst very vague, it did include some nice screen shots
from a RiscPC with a mock-up of what things might look like. Along with the
slabbed menus (available in PD by somebody whose name I forget - RiscPC only,
I believe) I saw an improved Configuration application. Although all the
windows were slabs (each had it's border raised) and I could see no easy way
to do this, I could see a simple manner in which the Config program could be
put together with third party options easily added in Libraries.
Hence ConfigPlus.
In the mean time, however, I was looking into OSLibs and found the NoObscure
IconBar bit I mentioned above, along with :
Desktop dither - very little use except in 4 and 2 colour modes
Tube - hang over from old Master days perhaps ?
NoTile - possibly special flag for tile_1 ?
VFS - Hmmm.
ROMFS - More hmmm.
IconCache - Not a clue :-)
ROMBatMan - along side the auto loaded ROM applications as the bottom bit :-)
The NoObscureIB flag looked interesting, so I quickly knocked together a
module to get around the problem of the wimp ignoring it.
Usage
-----
Run the !Run file. That's it.
One question will be asked of you. That is if you wish Ctrl-Shift to
cancel the shift action. Basically, if you hold down shift then the checks
for not covering the iconbar will be ignored. However, in some applications
like Zap you use Shift-Ctrl-G for full size and Shift-Ctrl-W for wide (well I
do anyway). Therefore if you don't set this, then this keeys will do as
asked, but the next time that the window is opened (probably on next key
press) the window will shink.
So, if you want Ctrl-Shift to bypass the bypass, then press Y or Select.
Hopefully, the code will be assembled with no errors and all that in
future will be required is the running of the resultant code file.
How it works
------------
Basically, it just patches the Wimp_OpenWindow call to modify it's parameters
using WimpSWIve (see below). The bottom of the window is limited to just
above the iconbar unless shift is pressed, the CMOS bit is unset, there is no
Adjust size or vertical scroll bar, or the title bar is below the iconbar
top. The toolsprites are taken into account by using Wimp_GetWindowInfo and
WimpGetWindowOutline (unlike many programs!).
A small patch is used to ensure that if you click on full size, you get full
size, as otherwise the window only opens downwards to the iconbar and stops.
This is peculiar, but thats what the Wimp does, so I had to work around it.
If you do click on the toggle icon, then the maximum height is found, and the top extended by that amount. Then it is clipped to the screen, also taking into
account the tool icons. Try it using the Mega set created by Edouard Poor and
see the effect!
A further modification is also made to any window with Force to screen on
next open, or bounded by screen and if this is the first open, bits are set.
This ensures that StrongHelp windows which, I think, are opened twice (or are
at least created in different positions to that in which they are opened),
open correctly (ie on the screen). For some peculiar reason (possibly related
to the above peculiar reason, but more likely due to the fact that I open the
window myself an extra time in the patch) these windows open with just half a
line showing at the top of the screen and the adjust size icon. This is
useful, but only if the information was contained in the bottom half of the
last line and you really needed to see the adjust size icon. If, like any
sane person (ie those who believe this), you would much prefer to see the
whole of the window, then the patched version is much more useful.
Bugs
----
One of the problems which I have not encountered (but guess could occur if
some programmer tried hard enough) is that some programs may check to see if
the window is full size and act differently on it if it is (ie try to force
full size); this may cause problems, but then again the same effect would
probably occur if the Wimp did the same thing, unless it modified the bits to
indicate that the window was at full size when on a line with the icon bar.
This problem mainly comes from the fact that there is no way to force a
window to full size (ie simulate click on Toggle size), because if you open
to a ridiculous size under RO3, you get a window which is ridiculously size,
rather than one which you would have got had you resized it using the resize
button. Ask Dominic Symes if the lack of this facility has caused him any
problems and I'm sure he'd say “no, but don't as me to do it again” (maybe he
won't, but I would!)
Disclaimer
----------
The author accepts no responsibility for any problems which this
application may cause or loss of data resulting in its use. This application
is Public Domain. This means that it may be distributed, so long as no charge
other than copying costs are charged for it.
Source code
-----------
This program requires the !JFPatch pre-assembler to make the code. This is
a simple text-to-basic assembler which takes a text assembler file, makes a
basic program from it to assemble, assembles it and returns any errors.
Currently, it is under development and requires a lot of work before it will
be released in any form. As such, the patch file is mostly useless, but must
be distributed with the resultant module.
All source code an the resultant module must be distributed together.
WimpSWIVe
---------
This program require WimpSWIve to be installed before it will run
correctly. It provides easy access to filtering Wimp calls other than
Wimp_Poll (provided by FilterManager) and is provided with NewerLook (which