BBC BASIC for Windows
« Colour v color »

Welcome Guest. Please Login or Register.
Apr 5th, 2018, 9:58pm



ATTENTION MEMBERS: Conforums will be closing it doors and discontinuing its service on April 15, 2018.
Ad-Free has been deactivated. Outstanding Ad-Free credits will be reimbursed to respective payment methods.

If you require a dump of the post on your message board, please come to the support board and request it.


Thank you Conforums members.

BBC BASIC for Windows Resources
Online BBC BASIC for Windows documentation
BBC BASIC for Windows Beginners' Tutorial
BBC BASIC Home Page
BBC BASIC on Rosetta Code
BBC BASIC discussion group
BBC BASIC for Windows Programmers' Reference

« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: Colour v color  (Read 1117 times)
Michael Hutton
Developer

member is offline

Avatar




PM

Gender: Male
Posts: 248
xx Colour v color
« Thread started on: Oct 22nd, 2008, 07:01am »

A style option for the spelling of the word COLOUR in the IDE for our cousins over the pond?

Michael
User IP Logged

admin
Administrator
ImageImageImageImageImage


member is offline

Avatar




PM


Posts: 1145
xx Re: Colour v color
« Reply #1 on: Oct 22nd, 2008, 09:37am »

Quote:
A style option for the spelling of the word COLOUR in the IDE for our cousins over the pond?

As you may have noticed, COLOR is accepted, but it is immediately changed to COLOUR on hitting Enter! BBC BASIC is very much a British product so I feel that is an adequate concession to our transatlantic cousins!

There are in any case practical difficulties with your suggestion, because even if the IDE had such a configuration option how would the interpreter know what spelling to use in *LIST (e.g. in a compiled executable)?

Richard.
User IP Logged

DDRM
Administrator
ImageImageImageImageImage


member is offline

Avatar




PM

Gender: Male
Posts: 321
xx Re: Colour v color
« Reply #2 on: Oct 22nd, 2008, 1:39pm »

on Oct 22nd, 2008, 09:37am, Richard Russell wrote:
even if the IDE had such a configuration option how would the interpreter know what spelling to use in *LIST (e.g. in a compiled executable)?


Hi Richard,

Presumably by using the option to decide how to "decode" the relevant token? Is that not how the IDE changes it from COLOR to COLOUR? I assumed the parser recognised it as an alternative form of the keyword, and put in the relevant token, but then expressed it back again - as "P." is converted to PRINT, and so on. Thus it would simply be a case of setting it to show the US version whenever it comes across that token.

Of course, if that's not how it works, it may not be so simple (if doing what I suggest IS simple, when it comes to the code under the bonnet!)....

... not that I necessarily think it's good to pander to the linguistic preferences of our overseas colleagues...

smiley

D

User IP Logged

admin
Administrator
ImageImageImageImageImage


member is offline

Avatar




PM


Posts: 1145
xx Re: Colour v color
« Reply #3 on: Oct 22nd, 2008, 2:12pm »

Quote:
Presumably by using the option to decide how to "decode" the relevant token?

My point was that a BASIC program being executed by the interpreter knows nothing about the IDE or its settings. The program might be run using BBCWRUN.EXE or as a 'compiled' executable; in neither case is the IDE necessarily loaded (or even installed) so there's no "option" for the program to refer to.

Even if one contrived a means for the interpreter to access the IDE's settings, I can't see much point in a program *LISTing the token as COLOR when running under control of the IDE, but reverting to COLOUR as soon as it is run independently of the IDE.

User IP Logged

Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

| |

This forum powered for FREE by Conforums ©
Terms of Service | Privacy Policy | Conforums Support | Parental Controls