Python indentation
Allan Sandfeld Jensen
kde at carewolf.com
Fri Oct 13 14:40:00 UTC 2017
I don't know much about how that script is supposed to work, so it might be
easier for you to debug.
On Freitag, 13. Oktober 2017 12:37:28 CEST Sven Brauch wrote:
> Hey Allan,
>
> you did the QtScript -> QtQml port in kate's script engine, right? Some
> of the indenters are behaving strangely (I'll attach part of the
> discussion below, in case you are not on kwrite-devel), apparently
> because some global variables are not defined properly. Any idea what
> could cause this? If you don't have time, I can also go look myself, but
> maybe it's a five-minute job for you.
> Best,
> Sven
>
> On 28/09/17 14:02, Gerald Senarclens de Grancy wrote:
> > Thanks Sven.
> >
> >>> The variable triggerCharacters is not defined in the python indenter.
> >>> Any clues what has changed here?
> >>
> >> I think the underlying JS engine changed. That probably broke this.
> >> Where should the value of the variable come from?
> >
> > Unfortunately, I don't know (yet). Had a look at the source tree and
> > stumbled across
> > ktexteditor/src/script/data/indentation_template.js
> >
> > which contains
> > """
> > // specifies the characters which should trigger indent, beside the
> > default
> > '\n'
> > triggerCharacters = "{}/:;";
> > """
> > didn't go through the cpp source yet to figure out more
> >
> >>> Related question: I was trying to locate the python.js indenter of my
> >
> > local
> >
> >>> installation.
> >>
> >> It's in a qrc and built into the ktexteditor shared library.
> >
> > Thanks a lot, good to know. Has been a while since I last contributed.
> > Will
> > have to get into it again :)
> > /g
More information about the KWrite-Devel
mailing list