Welcome, Guest. Please login or register.

Author Topic: OS 3.9 change "sort by name" font color ?  (Read 4589 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline olsen

Re: OS 3.9 change "sort by name" font color ?
« on: June 27, 2017, 03:21:35 PM »
Quote from: Whaka;827644
Hi,

on OS 3.9, since BB2 if i remember well... the defaut color when you select "sort by name" for listing drawers, is a kind of light blue, instead of good old black in earlier OS versions.
idk why they did this horrible choice, it's hard to read for me...
I'm the guilty party who opted for this choice of colour. It was a difficult decision to make, although in my defence (if you would accept that) I did not have much choice, except perhaps to make an even worse decision.

The reason why the colours for files and drawers, respectively, are different was to allow the different types to be visually distinct at first glance. We tried slanted/bold font styles in place of the different colours, but the results were even less readable than what we ended up with, eventually. Underlining was already used for a different purpose (underlined drawer entries refer to soft/hard links).

So, that's why it had to be a different colour, and for that matter, a hard-coded different colour. The Amiga user interface scheme introduced with Workbench 2.0 has to work both in two colour and in four colour screen modes. Because of how Workbench renders drawer contents in text mode, we were limited to a maximum of two colours.

The colour for files is black, which is colour #1 (the background is colour #0). We couldn't use colour #2 (white) for drawers, because on a two colour display, #2 would have been indistinguishable from colour #0.

This only left colour #3, which "works" both in two and four colour screen modes. Sorry, there was not enough flexibility in making Workbench's built-in icon rendering work better with the choice of user interface colours.

Workbench renders the drawer contents like icons, even if the contents are shown in text mode. This means that chip memory is allocated for each entry, and the amount of memory reserved for showing the text has to be kept under control.

Had there been more time available to rework the text mode display code, these curious limitations would have gone away, eventually. The Workbench resisted change, and still valiantly keeps resisting, after all those years :(

Quote
i never find how to set it in black, it seems there's no option in prefs. someone tried ?
thanks :)

Sorry, the drawer colour is hard-coded for the sad reasons I mentioned above :(  The only way to make both files and drawers come out in exactly the same colour is to switch your screen into two colour mode (which is not necessarily an improvement).
 

Offline olsen

Re: OS 3.9 change "sort by name" font color ?
« Reply #1 on: June 27, 2017, 06:02:56 PM »
Quote from: Gulliver;827665
@olsen

Perhaps you could simply point the offset and values that must be changed in workbench.library to alter those colors.
Easier said than done... I'm not 100% certain that I can rebuild the workbench.library version which shipped with the AmigaOS 3.9 update, producing exactly the same binary.

In the library version which I can build, the following bytes contain the code which sets the drawer name rendering colour to #3:

Code: [Select]
7E03 0C40 7E01
That's "moveq #3,d7; cmpi.w #$7e01,d0", which in the version I could build appears exactly once in the library.

Find that pattern and change it to the following sequence, to make the drawer name rendering colour come out as #1:

Code: [Select]
7E01 0C40 7E01
« Last Edit: June 28, 2017, 08:00:37 AM by olsen »