After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 676084 - split language-support-cpp-java plugin in an indentation part and a new language-support-cpp-java part
split language-support-cpp-java plugin in an indentation part and a new langu...
Status: RESOLVED FIXED
Product: anjuta
Classification: Applications
Component: plugins: language-support-c-cpp-java
git master
Other Linux
: Normal normal
: ---
Assigned To: Naba Kumar
Anjuta maintainers
: 676305 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2012-05-15 09:45 UTC by Moritz Lüdecke
Modified: 2012-07-26 14:44 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
split old language-support-cpp-java plugin in indentation-c-style and new language-support-cpp-java (273.95 KB, patch)
2012-05-15 09:45 UTC, Moritz Lüdecke
reviewed Details | Review
split language-support-cpp-java and language-support-python plugin in an indentation part and a new language-support part (434.96 KB, patch)
2012-05-18 14:01 UTC, Moritz Lüdecke
none Details | Review
fix preferences string in indentation-c-style and indentation-python-style (1.12 KB, patch)
2012-05-23 22:14 UTC, Moritz Lüdecke
none Details | Review
Some trivial fixes in indentation plugins and cpp-java plugin (3.38 KB, patch)
2012-06-22 11:45 UTC, Moritz Lüdecke
committed Details | Review
fix ui file of cpp-java plugin (852 bytes, patch)
2012-06-24 12:09 UTC, Moritz Lüdecke
reviewed Details | Review

Description Moritz Lüdecke 2012-05-15 09:45:44 UTC
Created attachment 214073 [details] [review]
split old language-support-cpp-java plugin in indentation-c-style and new language-support-cpp-java

I'd split the old language-support-cpp-java plugin in an indentation part and a new language-support-cpp-java part.
Comment 1 Johannes Schmid 2012-05-16 18:19:50 UTC
Review of attachment 214073 [details] [review]:

Thanks, looks good overall, please have a look at the detailed comments below.

::: plugins/indentation-c-style/anjuta-indentation-c-style.plugin.in
@@ +4,3 @@
+_Name=C style indentation Plugin
+_Description=auto-indentation for c style code
+Interfaces=IAnjutaLanguageSupport,IAnjutaIndenter

Not sure if you need IAnjutaLanguageSupport here.

::: plugins/indentation-c-style/utils.c
@@ +19,3 @@
+*/
+
+#include <libanjuta/interfaces/ianjuta-editor-cell.h>

utils.c and utils.h should probably just be integrated into libanjuta/anjuta-utils.c/h so you can use them from both, c and python plugin.

::: plugins/language-support-js/lex.yy.c
@@ +2857,3 @@
 static int yy_get_next_buffer (void)
 {
+    register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;

were the changes to this file intentional?
Comment 2 Moritz Lüdecke 2012-05-18 13:52:53 UTC
*** Bug 676305 has been marked as a duplicate of this bug. ***
Comment 3 Moritz Lüdecke 2012-05-18 14:01:23 UTC
Created attachment 214311 [details] [review]
split language-support-cpp-java and language-support-python plugin in an indentation part and a new language-support part

I made one patch for both plugins, language-support-cpp-java and language-support-python.

> Not sure if you need IAnjutaLanguageSupport here.
* If I remove IAnjutaLanguageSupport, the indentation doesn't work.
> utils.c and utils.h should probably just be integrated into libanjuta/anjuta-utils.c/h so you can use them from both, c and python plugin.
* The plugins use libanjuta/anjuta-utils.c/h now.
> were the changes to this file intentional?
* Yes, but this is only cosmetic. So in the new patch this file is untouched.
Comment 4 Johannes Schmid 2012-05-23 18:51:37 UTC
Fantastic work - thanks!

There is a small problem though when the preferences are openen while a python file open I get the following:

GLib-GIO-ERROR **: Settings schema 'org.gnome.anjuta.plugins.python' does not contain a key named 'indent-automatic'

Can you please check that? I pushed the other changes so you can create a subsequent patch.
Comment 5 Moritz Lüdecke 2012-05-23 22:14:03 UTC
Created attachment 214821 [details] [review]
fix preferences string in indentation-c-style and indentation-python-style

This shouldn't happen. I tried to reproduce the error, but I didn't get it displayed.

language-support-python plugin never uses the key "indent-automatic" and indentation-python-style uses the settings schema "org.gnome.anjuta.plugins.indent-python".

Are you sure that you build the plugins in a clean environment without old temporary files?

I recognize that you forgot to rename two strings. (see attached patch)
Comment 6 Moritz Lüdecke 2012-06-22 11:45:18 UTC
Created attachment 217017 [details] [review]
Some trivial fixes in indentation plugins and cpp-java plugin

Additionally to the old patch I removed IAnjutaIndenter in the python and the cpp-java plugin and vala support in thecpp-java plugin.
Comment 7 Moritz Lüdecke 2012-06-24 12:09:00 UTC
Created attachment 217111 [details] [review]
fix ui file of cpp-java plugin

I found three lines in the code, which I forgot to delete.
Comment 8 Johannes Schmid 2012-06-24 12:14:31 UTC
Review of attachment 217017 [details] [review]:

Thanks!
Comment 9 Johannes Schmid 2012-06-24 12:35:39 UTC
Review of attachment 217111 [details] [review]:

Hmm, the patch doesn't apply and seems to work without problems here.
Comment 10 Moritz Lüdecke 2012-06-24 12:56:49 UTC
(In reply to comment #9)
> Review of attachment 217111 [details] [review]:
> 
> Hmm, the patch doesn't apply and seems to work without problems here.
Ohh, I forgot that this patch fixes a problem which affects only my work branch. So forget this patch. :-)
Comment 11 Johannes Schmid 2012-07-26 14:44:55 UTC
This is all in master.