[Github-comments] [geany/geany] Stash Settings: Add double key type (PR #3004)

xiota notifications at xxxxx
Tue Nov 16 08:41:11 UTC 2021


@xiota commented on this pull request.



> @@ -476,6 +497,20 @@ void stash_group_add_boolean(StashGroup *group, gboolean *setting,
 }
 
 
+/** Adds double setting.
+ * @param group .
+ * @param setting Address of setting variable.
+ * @param key_name Name for key in a @c GKeyFile.
+ * @param default_value Value to use if the key doesn't exist when loading. */
+GEANY_API_SYMBOL
+void stash_group_add_double(StashGroup *group, gdouble *setting,
+		const gchar *key_name, gdouble default_value)
+{
+	gulong *default_long = (gulong*) &default_value;
+	add_pref(group, G_TYPE_DOUBLE, setting, key_name, (gpointer) *default_long);

Will rebase when it's available.  Thank you.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3004#discussion_r750034961
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20211116/2450c8ac/attachment.htm>


More information about the Github-comments mailing list