[Github-comments] [geany/geany] Plugin-API: extended project API (#2234)

LarsGit223 notifications at xxxxx
Sat Aug 3 07:43:53 UTC 2019


> The new API functions to access `ProjectPrefs` seem weird. For one, the doc-comments are not useful, and might as well just be `/***/` since they don't actual describe what the functions do at all, just what field of some private undocumented struct they access is called. Moreover, usually in Geany (for better or worse) we would expose the struct members directly to the API using doc-comments (and obviously moving the struct out of the `#ifdef GEANY_PRIVATE` guard).

They really do nothing else then changing the value of that struct item. That is part of the ProjectPrefs. The item set belongs to the config option _"Use project-based session files"_. But if usually the structure should be exposed then I will do that and change it.

> I don't feel really strongly about accessor functions vs exposing the struct, but it would be cool to fix the doc-comments so they explain what the functions are for (I genuinely have no idea). Also if keeping the accessor functions or not, it might be useful to take the opportunity to name the functions/field something better since `project_session` as a boolean is not a very good name. Something like `is_project_session` or `project_session_deleted` or `dont_load_project_session` or whatever it's actually for would be better, IMO.

See above. I will remove the functions and try to find a better name for the struct item.

-- 
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/2234#issuecomment-517903494
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20190803/8fd22d09/attachment.html>


More information about the Github-comments mailing list