Re: [cc65] wrong colors in conio

Date view Thread view Subject view

From: Christian Groessler (cpg_at_aladdin.de)
Date: 2002-12-10 17:37:17


Hi,

On 12/09/2002 10:36:09 PM CET Ullrich von Bassewitz wrote:
>
>On Mon, Dec 09, 2002 at 10:03:58PM +0100, Christian Groessler wrote:
>> But removing textcolor() or doing nothing in it leaves the Atari port
>> with no way to set the text bightness.
>> I could add a textluminance() or similar function which does it, but
>> then all other ports would need a new (empty?) textluminance()
>> function.
>
>Since the Atari is the only platform that has this sort of behaviour, and I
>don't think there are many others, textluminance() should be Atari
>specific.

Ok, but then ..

>
>> Can't we just document the different behaviour of textcolor() for the
>> Atari and leave it in so Atari users can set the brightness of the
>> text?
>> It appears to me to be less hassle this way.
>
>It may be less hassle on the first view, but it would be very short sighted.
>If we start having each function behave differently on one or more platforms,
>we will effectively undermine the whole portability goal. It is a different
>thing for a function to be unavailable on a specific platform, and to behave
>differently. Think about it yourself. If bgcolor wouldn't return the old color
>on one platform, cputc wouldn't move the cursor on another, cputs wouldn't
>interpret a carriage return on a third platform, and gotoxy would measure
>coordinates relative to 1/1 instead of 0/0 on a fourth: Even if all these
>special behaviours were documented somewhere, it would nevertheless be almost
>impossible to write a conio based program that runs on all platforms.
>
>So I would like to ask you to make the necessary changes. The changes (rename
>textcolor to textluminance and define textcolor to be an alias for return0) do
>not seem to be complex, so if you're busy with other things, I can as well
>make these changes. I promise I'll try not to break anything:-)
>
>Please get me right: It is not my intent to cripple the Atari port. Having an
>Atari specific function to set the text luminance would be a good idea. But
>since this function *is* special, it should be clear to anyone using it, that
>it is not portable, and that it does not behave as expected from textcolor().

... I suggest to completely remove textcolor() from the Atari
port. Since return0 will also behave differently as expected and if
the function isn't there it will give an immediate hint to the
programmer.

regards,
chris

----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo_at_musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.


Date view Thread view Subject view

This archive was generated by hypermail 2.1.3 : 2002-12-10 17:39:05 CET