Koder - new native code editor

Hello. There are the spanish catkeys translation:

http://sprunge.us/jcLi Koder

Thanks, humdinger has created a PR, I’ve just pulled it in :slight_smile:

This application looks very good.

Added Russian translation.

In continue of issue #9 (https://github.com/KapiX/Koder/issues/9 ) — does Haiku support creation and management of window groups (tiling and tabbing) programmatically?

Thank you for your contribution :slight_smile:

I think only tabbing is supported now.

1 Like

I expect to release 0.2.0 soon and app strings won’t change at this point.
People intending to update translations please let me know via PM so I’ll know to wait for you.

1 Like

Please, add lithuanian translation to the app:
… need to fix

@damoklas, thanks, no need to fix, I removed the garbage from the end :slight_smile:

KapiX
Updated Ukrainian translation - http://sprunge.us/AEOO

Updated ES catkeys:
http://sprunge.us/JfGM

Hi, @KapiX! :slight_smile: How do I test my local translation before I send you the PR?

And does the highlighting system work? Those yaml files are all it takes to make the highlighter rules? And what’s PHP’s lexer ID?

Translations are done at https://i18n.kacperkasper.pl .
To test your translation, you’d have to download your catkeys from there, get the code and compile Koder after adding your language to its makefile.
So, that all takes some effort… :slight_smile:

send your files and if something is not ok send your corrected file again…
btw. what is the actual version number of Koder?

:confounded:

0.3

Actually it should be possible to drop the plain catkeys in the right place without compiling it. I don’t remember the exact path we look for these, however. Probably some non-packaged/data/catkeys/… or non-packaged/data/catalogs/… ?

It may be possible to test without compiling the catkeys into the executables resources. There are “catalogs” in MIME type subfolders in /boot/system/data/locale/catalogs/. So, it may be possible to put a catalog into a MIME type subfolder in /boot/system/non-packaged/data/locale/catalogs/x-vnd.Haiku-About.

Unfortunately, I don’t know how to get from “catkeys” to “catalog” to test that.

Anyway, not being able to easily test one’s catkeys directly in the app didn’t deter people from contributing good translations.
People concerned could try contacting the project’s dev to ask for a localized pre-release before the real deal to be able to make corrections.

Converting to a catalog isn’t needed. You should be able to use the catkey file directly, it’s just slower to parse. Only problem is I don’t remember where exactly you have to put it. Probably a catkeys folder next to the catalog one?

Compiling is straightforward anyways, you just use the linkcatkeys tool.

I tried analog to the “catalog” system by putting the de.catkeys of BeMines into /boot/system/non-packaged/data/locale/catkeys/x-vnd.dw-BeMines.
That didn’t work.

But creating a de.catalog from the de.catkeys worked with:
linkcatkeys -l de -s x-vnd.dw-BeMines ./de.catkeys

Put the de.catalog into /boot/system/non-packaged/data/locale/catalogs/x-vnd.dw-BeMines, and BeMines did use it! :bomb::boom:

Still, probably too much of a hassle for the casual translator. After all, getting the source, making a little change in the Makefile and a make bindcatalogs isn’t that much harder… :slight_smile:

1 Like

Yes. Generally I’d like it to be a bit more abstract. Now it’s pretty tightly tied with Scintilla implementation.

IDs are here: https://sourceforge.net/p/scintilla/code/ci/default/tree/include/SciLexer.h
#define SCLEX_PHPSCRIPT 69

To make it work you need three things:

  1. define php in languages.yaml
  2. define keywords in languages/php.yaml
    the number you need is 4 - see here: https://sourceforge.net/p/scintilla/code/ci/default/tree/lexers/LexHTML.cxx#l584
  3. define colors in styles/default/php.yaml
    names are not used now - they will be when I implement more sophisticated configuration
    IDs are from https://sourceforge.net/p/scintilla/code/ci/default/tree/include/SciLexer.h
    for PHP they start with SCE_HPHP_*: https://sourceforge.net/p/scintilla/code/ci/default/tree/include/SciLexer.h#l336

I have implemented a simple system for overriding stuff: you can put additional languages.yaml in non-packaged structure and the two files (from packaged and non-packaged) will be merged. Same thing applies to keywords and styles.

Pull Requests welcome of course, Scintilla supports a lot of languages.

1 Like

I want to create a dark theme for Koder, but I cant write to System. Why arent the theme settings saved in /home/config/settings?

How do I do?
Regards!
//Mikael