"Plain text" vs. "Oberon DoCument" for sources

Ivan Denisov
Posts: 1700
Joined: Tue Sep 17, 2013 12:21 am
Location: Russia

"Plain text" vs. "Oberon DoCument" for sources

Post by Ivan Denisov »

There is an idea actively discussing in Russian forum, and I heard it here about using of plain text (utf8) format for sources.

What do you think? Will Center convert sources to some plain text with some new extension (for example .cpas).

It gives benefits for using open repositories tools for sources comparison.

I do not like this idea, because I am using colour in my sources and I want it to be saved.
cfbsoftware
Posts: 204
Joined: Wed Sep 18, 2013 10:06 pm
Contact:

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by cfbsoftware »

It would be useful if both BlackBox format and plain text could be supported transparently. I use a lot of non-BlackBox tools for working with text files and it would be convenient to be able to use those without having to convert to and from text. If the BlackBox editor could be enhanced to support automatic syntax-colouring there would be less of a need to save colour information with the file.
User avatar
DGDanforth
Posts: 1061
Joined: Tue Sep 17, 2013 1:16 am
Location: Palo Alto, California, USA
Contact:

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by DGDanforth »

cfbsoftware wrote:It would be useful if both BlackBox format and plain text could be supported transparently. I use a lot of non-BlackBox tools for working with text files and it would be convenient to be able to use those without having to convert to and from text. If the BlackBox editor could be enhanced to support automatic syntax-colouring there would be less of a need to save colour information with the file.
Interesting idea. The only downfall is if the colour choice for the syntax is not liked by a user. Which suggests that a user specific file "strings" could handle the users colour choices.
cfbsoftware
Posts: 204
Joined: Wed Sep 18, 2013 10:06 pm
Contact:

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by cfbsoftware »

In CPIde, our Component Pascal IDE we have an options dialog box which gives the user control over which colours to use for the different types of language elements. As the user changes their selections a preview of the effect can be viewed:
Colour1.JPG
Colour1.JPG (30.75 KiB) Viewed 11042 times
The different Component Pascal language elements can be selected from a drop-down list:
Colour2.jpg
Colour2.jpg (33.05 KiB) Viewed 11042 times
And there are plenty of colours to choose from: ;-)
Colour3.jpg
Colour3.jpg (51.16 KiB) Viewed 11042 times
I find syntax-colouring very useful for quickly highlighting unterminated comments and unterminated strings which can otherwise lead to some confusing compilation errors.
Ivan Denisov
Posts: 1700
Joined: Tue Sep 17, 2013 12:21 am
Location: Russia

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by Ivan Denisov »

There is subsystem for BlackBox called Master.
http://zx.oberon2.ru/forum/viewtopic.php?f=34&t=95

However usage of coloured sources for Component Pascal is overengineering, because the language it self was designed to prevent the necessity in syntax highlight.

I am using colour not for the syntax highlight, but for the logical accents and to highlight the parts of new code or parts of debugging procedures, that should be hidden later and so on.
User avatar
ReneK
Posts: 214
Joined: Tue Sep 17, 2013 9:16 am
Location: Vienna, Austria, Europe

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by ReneK »

As I see it, automatic coloring of the sourcr code without enabling the user to turn it off would be against the Oberon spirit.

Also, I would prefer keeping the center focussed in providing the next release, which should be Bugfixes, not New features.
cfbsoftware
Posts: 204
Joined: Wed Sep 18, 2013 10:06 pm
Contact:

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by cfbsoftware »

Allowing syntax colouring to be switched off would be a trivial exercise. Even if it was not an explicit option it can easily be achieved by setting the same font and colour for all language elements.

I would recommend that, assuming it is feasible, any new feature should be able to be switched off for backward compatibility.
Ivan Denisov
Posts: 1700
Joined: Tue Sep 17, 2013 12:21 am
Location: Russia

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by Ivan Denisov »

I think, that this question about plain text is important for choosing the repository. If Center will decide to store the sources in plain text the GitHub can be the best choice.
User avatar
ReneK
Posts: 214
Joined: Tue Sep 17, 2013 9:16 am
Location: Vienna, Austria, Europe

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by ReneK »

Thanks for the explanation, Ivan. I believe that the ability to highlight manually is an important feature of the BB IDE, even if something like the CPC Beautifier is used. Giving up in that feature, IMHO, would be wrong.

Gesendet von meinem LIFETAB_E7316 mit Tapatalk
User avatar
DGDanforth
Posts: 1061
Joined: Tue Sep 17, 2013 1:16 am
Location: Palo Alto, California, USA
Contact:

Re: "Plain text" vs. "Oberon DoCument" for sources

Post by DGDanforth »

Ivan Denisov wrote:I think, that this question about plain text is important for choosing the repository. If Center will decide to store the sources in plain text the GitHub can be the best choice.
Although most of my code can be stored as plain text there are times when I document the code by inserting bitmaps (views). Also, the 'road map' (and other) documentation from Oberon microsystems AG uses views.

So it would be necessary to have two repositories; .txt and .odc.
Locked