[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kwrite-devel
Subject:    Re: Ideas
From:       Dominik Haumann <dhdev () gmx ! de>
Date:       2008-04-06 13:48:35
Message-ID: 200804061548.37110.dhdev () gmx ! de
[Download RAW message or body]

On Friday 04 April 2008, Anders Lund wrote:
> Hi all,
>
> Up to the developer sprint next weekend, I'd like to share some of the
> idears that i have had for improving KatePart.
>
> * Highlight combination.
>   I'd like to add the ability to implicitly combine highlights by
> injecting one highlight into another, given it provides the means. It is
> meant for template languages (php, eperl, EmbPerl, HTML::MASON, asp, some
> flavors of ruby, java, python and probably several more). These languages
> can be used with any other text format, they mainly have interpreters
> that evaluates code marked up with defined delimiters. You could have a
> apache config file where some parts were generated by a template
> language, for example.
>   Currently we only handle very few combinations, and we do it by
> creating extra files. For example for HTML + PHP we generate special
> html, javascript and CSS xml files where every context contains a few
> rules to enter the php main loop.
>   My idea is that a template language could contain a specially
> attributed context for the purpose, which could contain the rules to
> enter the main language loop, and those rules would be evaluated in every
> context in the host highlight system.
>   You could then create a combination by setting the highlight for a file
> to 'HTML + PHP' or 'Apache conf + Mason' etc.
>   This would require a few additions to the highlight generation, i had a
> brief look the other day and my first thought was that it could be nice
> to make the generator a class of its own.
>
> * Context sensitive indentation
>   Many text files combines text with diffetent indentation requirements,
> an obvious example is HTML with embedded javascript and CSS text.
>   My suggestion is that we provide a way to use an indenter based on the
> current highlight, with optional specific settings for the whitespace. It
> would be rather simple, a question of checking the highlighter before
> calling the required intenter.
>   To facilitate this, we could extend the indent-mode variable to accpet
> this syntax:
>   "kate: indent-mode HTML html-indent; indent-mode javascript js-indent;"
>   and mayby aditionally this:
>   "kate: indent-mode HTML html-indent javascript js-indent;"
>   and similarly other involved settings, example:
>   "kate: indent-width HTML 3;" etc.

It sounds interesting but how should the indentation scripts work then? 
Maybe there is a cool solution, but I don't see it yet :)

> * Status bar
>   (This is an old one) We should really provide a way to easily select
> properties for display on the statusbar.

Wasn't someone going to submit a patch to show the encoding?
Besides that, it would already work quite well if configuring the status bar 
would work directly with a context menu on the status bar. The context menu
could simply have entries to show/hide predefined entries.

> * Message system
>   KatePart is missing a nice way of showing messages. I think we should
> do two things:
>   1) provide a simple interface providing setMessage( text, type,
> [button[s]], [timeout] ). The user could be presented with a choice of
> GUI by the application, such as KMessageBox or somthing specific to the
> application. 2) A nice default message view. I suggest that we implement
> something in the style of Mozilla Firefox, a potentially time limited
> message bar in the top or bottom of the view.
>
> Comments are as allways very wellcome :)


_______________________________________________
KWrite-Devel mailing list
KWrite-Devel@kde.org
https://mail.kde.org/mailman/listinfo/kwrite-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic