Hi, folks.
Dimitar Zhekov wrote:
Better for what? I use tabs for indentation because with the tab size, I can easily control the screen ammount of indentation, depending on the font and display. Saving disk space has nothing to do with that, I'll have to live very long to write 1GB of source code. :)
Likewise. I like tabs for indentation because 1 indent = 1 character, and everyone can have different ideas about how big that indent should be.
Lex Trotman wrote:
- There has been much discussion on the ML and several actual prototypes
of improved indentation/alignment schemes that are flexible enough to address many languages (even just many C style languages is a hard problem). None of them have been sufficiently correct, enough of the time, to overcome the problems of being really annoying when they are incorrect.
Yeah, I've seen a little of that discussion, and I'm not looking to solve it in 5 minutes :).
- But there is no way to tell Geany to not apply indentation per file, so
Geany will still do its thing independent of the plugin (and that includes moving } not just on enter).
Maybe what is needed is not a configuration file per language, but instead a code snippet per language? But I guess Geany would then have to rely on the presence of a dynamic language on the system, or else write it in C and have to rebuild from source to change it :s.
Splitting a line on user command is certainly an easier way to do it, I assume you mean last *unmatched* bracket on the line (that is not in a string or comment). Oh and don't forget C++ uses <> as brackets for templates, but don't confuse that with the places it uses them for gt and lt :)
Good point. I might actually ignore the angle bracket issue, unless it's really likely that people will have so many entries in a template that they'll want to split the line. Otherwise...I guess when it found a < it could search the rest of the line for a matching > and decide based on that.
Finally plugins should *not* bind keys by default, they have no way of knowing if the user has already bound that key to something else (and of course multiple plugins binding the same key :).
Oh, I know, I was just thinking aloud about which keybinding I might use.
Adding such analysis could be a big job but in my experience Emacs does produce a reasonable result.
Yeah, that looks too big for what I was thinking of, but thanks for pointing it out. I might use it as a reference.
Thomas Martitz wrote:
Bah, this "everything must be a plugin" really annoys me... What's wrong with you accepting new code in the core?
Actually, I agree that custom indentation schemes are too troublesome to include in core... unless someone, somehow, has a spark of genius allowing them to invent a perfect one-scheme-fits-all approach. This idea - particularly the Lua script - is far from that.