Here is python triple quote completion (it requires the patch from my last post be applied to everything but PythonSmartIndent.cpp).
Index: src/plugins/contrib/SmartIndent/PythonSmartIndent.cpp
===================================================================
--- src/plugins/contrib/SmartIndent/PythonSmartIndent.cpp (revision 8500)
+++ src/plugins/contrib/SmartIndent/PythonSmartIndent.cpp (working copy)
@@ -71,6 +71,18 @@
}
}
+ bool braceCompleted = false;
if ( SelectionBraceCompletionEnabled() || stc->IsBraceShortcutActive() )
- ed->DoSelectionBraceCompletion(stc, ch);
+ braceCompleted = ed->DoSelectionBraceCompletion(stc, ch);
+ if (!braceCompleted && BraceCompletionEnabled())
+ {
+ ed->DoBraceCompletion(stc, ch);
+ if ( !(stc->IsComment(stc->GetStyleAt(pos)) || stc->IsComment(stc->GetStyleAt(pos - 2)))
+ && (ch == wxT('"') || ch == wxT('\'')) )
+ {
+ const wxString tripleQuote(3, ch);
+ if (stc->GetTextRange(pos - 3, pos) == tripleQuote && !stc->IsString(stc->GetStyleAt(pos - 4)))
+ stc->InsertText(pos, tripleQuote);
+ }
+ }
}
I also wanted to add term -> end term "brace" completion (similar to how C++ matches PP directives, and XML matches tags), but I realized that I do not use/understand those languages enough to be able to create something that functions as expected.