Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Activity for Newbyte
| Type | On... | Excerpt | Status | Date |
|---|---|---|---|---|
| Edit | Post #296667 | Initial revision | — | 4 days ago |
| Question | — |
Can I execute commands before the build system is invoked at all in a flatpak-builder module? I'm creating a flatpak-builder manifest wherein I want to do some "pre-processing" steps of the source code in a given module before the build system is invoked. In particular, I want to "merge" three codebases into one. I cannot simply use the `dest` directive as flatpak-builder's git handling g... (more) |
— | 4 days ago |
| Edit | Post #296554 | Initial revision | — | about 1 month ago |
| Question | — |
How do I make Phosh consider my app "mobile friendly"? I'm working on an app for Linux phone operating systems like postmarketOS and publishing it as a Flatpak on Flathub. What steps do I need to take to make it appear as a "mobile friendly" app in the Phosh app grid? Currently I need to press the "Show All Apps" button for it to appear, which tells ... (more) |
— | about 1 month ago |
| Edit | Post #294400 | Initial revision | — | about 1 year ago |
| Answer | — |
A: Does GLib's "GTest" testing framework have any filesystem mocking functionality? This won't work for every use-case, but for mine I was able to use the `GTESTOPTIONISOLATEDIRS` flag for `gtestinit ()` like so: ```c gtestinit (&argc, &argv, GTESTOPTIONISOLATEDIRS, NULL); ``` This only affects XDG directories, so if your program doesn't respect those or operates outside... (more) |
— | about 1 year ago |
| Edit | Post #294399 | Initial revision | — | about 1 year ago |
| Question | — |
Does GLib's "GTest" testing framework have any filesystem mocking functionality? I'm writing tests for some code that interacts with the filesystem, and I want to assert that it writes the expected data to disk. My problem is that some of the code I want to test includes hardcoded paths and due to my requirements I cannot avoid these without adding test-specific code paths, w... (more) |
— | about 1 year ago |
| Edit | Post #293236 | Initial revision | — | over 1 year ago |
| Answer | — |
A: How do I get a hexadecimal string representation of a GdkRGBA struct in C? I ended up implementing it like this: ```c #define RGBHEXSTRINGLENGTH 8 gchar gdkrgbatorgbhexstring (const GdkRGBA const from) { guchar red = roundf (from->red 255.0f); guchar green = roundf (from->green 255.0f); guchar blue = roundf (from->blue 255.0f); gchar to = malloc... (more) |
— | over 1 year ago |
| Edit | Post #293231 | Initial revision | — | over 1 year ago |
| Question | — |
How do I get a hexadecimal string representation of a GdkRGBA struct in C? I have a program that reads a hexadecimal string representation from a configuration file, turns it into a GdkRGBA struct from Gdk, uses `gtkcolordialogbuttonsetrgba ()` to set it as the default colour of a GtkColorDialogButton, and then listens to user changes to the aforementioned button. On... (more) |
— | over 1 year ago |
