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 764675 - Follow GNOME coding style for examples
Follow GNOME coding style for examples
Status: RESOLVED OBSOLETE
Product: gnome-devel-docs
Classification: Applications
Component: platform-demos
3.20.x
Other Linux
: Normal minor
: ---
Assigned To: gnome-devel-docs maintainers
gnome-devel-docs maintainers
Depends on:
Blocks:
 
 
Reported: 2016-04-06 10:22 UTC by Mohammed Sadiq
Modified: 2021-07-05 10:53 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Follow GNOME C coding style. (aboutdialog.c) (7.68 KB, patch)
2016-04-06 10:22 UTC, Mohammed Sadiq
none Details | Review
Follow GNOME C coding style. (aboutdialog.c) (7.67 KB, patch)
2016-04-06 10:58 UTC, Mohammed Sadiq
committed Details | Review
replace deprecated gtk_scrolled_window_add_with_viewport (1.13 KB, patch)
2016-04-09 04:47 UTC, Mohammed Sadiq
committed Details | Review

Description Mohammed Sadiq 2016-04-06 10:22:16 UTC
Created attachment 325468 [details] [review]
Follow GNOME C coding style. (aboutdialog.c)

Though several things seem trivial, as these examples are intended to teach, it should be written as good as possible.

Fixing one of the file (aboutdialog.c).

I shall add more patches if someone says its worth.

Thank you.
Comment 1 David King 2016-04-06 10:31:44 UTC
Review of attachment 325468 [details] [review]:

Rather than improving the coding style of the examples, it owuld be more productive to remove the outdated content and start from scratch. However, the patch is fine.

::: platform-demos/C/samples/aboutdialog.c
@@ +42,3 @@
+
+  /* We do not wish to show the title, which in this case would be
+   * "AboutDialog Example".  We have to reset the title of the messagedialog

I do not think that leaving two spaces after a full stop in comments is mentioned in the programming guidelines, although I might have missed it. In any case, I would be against making such a change.
Comment 2 Mohammed Sadiq 2016-04-06 10:38:09 UTC
Two spaces after end of a sentence is common for English.  It's also standardized in GNU standards.  See http://www.gnu.org/prep/standards/standards.html#Comments

Also, some editors (like GNU Emacs) take care about such conditions as end of a sentence.
Comment 3 David King 2016-04-06 10:49:17 UTC
OK, that is good for a reference, but does not change my opinion about the number of spaces after a full stop. Please change it to one.
Comment 4 Mohammed Sadiq 2016-04-06 10:58:23 UTC
Created attachment 325470 [details] [review]
Follow GNOME C coding style. (aboutdialog.c)

Two spaces now reduced to one.

Anyway, as you said, I shall try to find outdated contents and fix, where I can.

Thank you.
Comment 5 David King 2016-04-06 14:19:34 UTC
Review of attachment 325470 [details] [review]:

Thanks for the updated patch. I modified the commit message slightly, and pushed it to master as commit cf4ef5cf42e5a33009e5a25b764ed34b40dabc13.
Comment 6 Mohammed Sadiq 2016-04-09 04:47:42 UTC
Created attachment 325624 [details] [review]
replace deprecated gtk_scrolled_window_add_with_viewport
Comment 7 David King 2016-04-09 18:06:10 UTC
Review of attachment 325624 [details] [review]:

Sure, seems fine.
Comment 8 André Klapper 2017-08-01 10:23:11 UTC
Comment on attachment 325624 [details] [review]
replace deprecated gtk_scrolled_window_add_with_viewport

Pushed that last "accepted commit now" patch as git commit ce91dfd9.

Anything else left to do here?
Comment 9 GNOME Infrastructure Team 2021-07-05 10:53:37 UTC
GNOME is going to shut down bugzilla.gnome.org in favor of  gitlab.gnome.org.
As part of that, we are mass-closing older open tickets in bugzilla.gnome.org
which have not seen updates for a longer time (resources are unfortunately
quite limited so not every ticket can get handled).

If you can still reproduce the situation described in this ticket in a recent
and supported software version, then please follow
  https://wiki.gnome.org/GettingInTouch/BugReportingGuidelines
and create a new ticket at
  https://gitlab.gnome.org/GNOME/gnome-devel-docs/-/issues/

Thank you for your understanding and your help.