diff --git a/flatpak/build-flatpak.sh b/flatpak/build-flatpak.sh new file mode 100755 index 0000000..4d08abf --- /dev/null +++ b/flatpak/build-flatpak.sh @@ -0,0 +1,13 @@ +#!/bin/bash +# Build the LightGUI (C) Flatpak and a single-file bundle. +# Run from the repo root: bash flatpak/build-flatpak.sh +# Outputs: LightGUI.flatpak (single-file bundle) in the repo root. +set -e +cd "$(dirname "$0")/.." +MANIFEST=flatpak/com.hotconfig.LightGUI.yaml +APP_ID=com.hotconfig.LightGUI +BUILD_DIR=${BUILD_DIR:-/tmp/flatpak-build-lightgui} +REPO_DIR=${REPO_DIR:-/tmp/flatpak-repo-lightgui} +flatpak-builder --force-clean --repo="$REPO_DIR" "$BUILD_DIR" "$MANIFEST" +flatpak build-bundle "$REPO_DIR" LightGUI.flatpak "$APP_ID" --runtime-repo=https://dl.flathub.org/repo/flathub.flatpakrepo +ls -lh LightGUI.flatpak diff --git a/flatpak/com.hotconfig.LightGUI.desktop b/flatpak/com.hotconfig.LightGUI.desktop new file mode 100644 index 0000000..994b9aa --- /dev/null +++ b/flatpak/com.hotconfig.LightGUI.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Type=Application +Name=LightGUI +GenericName=GUI Designer +Comment=Visual GUI designer for GTK 3 in C++ +Exec=lightgui +Icon=com.hotconfig.LightGUI +Terminal=false +Categories=Development;IDE;GUIDesigner; +Keywords=GTK;GUI;designer;widgets;IDE; diff --git a/flatpak/com.hotconfig.LightGUI.metainfo.xml b/flatpak/com.hotconfig.LightGUI.metainfo.xml new file mode 100644 index 0000000..0b01358 --- /dev/null +++ b/flatpak/com.hotconfig.LightGUI.metainfo.xml @@ -0,0 +1,18 @@ + + + com.hotconfig.LightGUI + MIT + MIT + LightGUI + Visual GUI designer for GTK 3 in C++ + +

LightGUI is a visual designer for building GTK 3 applications in C++. Place widgets on a canvas at absolute positions, edit their properties in the Object Inspector, and generate runnable C++/GTK source code — a Glade layout file plus a C++ class with stub signal handlers, a Makefile and a CMakeLists.txt.

+

It ships 547 hand-drawn XFrame widgets in a 583-entry combined palette, a GDB stepping debugger (Run, Step Over/Into/Out, breakpoints, watches, locals), an editable code view with Ctrl+S save, and a UI theme editor with five coding presets.

+
+ com.hotconfig.LightGUI.desktop + https://github.com/cnmcdee/lightgui + https://github.com/cnmcdee/lightgui + + com.hotconfig.LightGUI.desktop + +
diff --git a/flatpak/com.hotconfig.LightGUI.yaml b/flatpak/com.hotconfig.LightGUI.yaml new file mode 100644 index 0000000..7b97815 --- /dev/null +++ b/flatpak/com.hotconfig.LightGUI.yaml @@ -0,0 +1,35 @@ +app-id: com.hotconfig.LightGUI +runtime: org.gnome.Platform +runtime-version: '48' +sdk: org.gnome.Sdk +command: lightgui +finish-args: + - --share=ipc + - --socket=fallback-x11 + - --socket=wayland + - --device=dri + - --filesystem=home +modules: + - name: lightgui + buildsystem: simple + sources: + - type: git + url: https://github.com/cnmcdee/lightgui.git + branch: main + build-commands: + - make lightgui -j$(nproc) + - cmake -S widgets -B widgets/build -DCMAKE_BUILD_TYPE=Release + - cmake --build widgets/build -j$(nproc) --target lightgui_palette lightgui_layout + - install -Dm755 lightgui /app/share/lightgui/lightgui + - install -Dm755 ide /app/share/lightgui/ide + - install -Dm644 ui/designer.ui /app/share/lightgui/ui/designer.ui + - mkdir -p /app/share/lightgui/icons + - cp icons/*.png /app/share/lightgui/icons/ + - install -Dm755 widgets/build/palette/lightgui_palette /app/share/lightgui/widgets/build/palette/lightgui_palette + - install -Dm755 widgets/build/layout/lightgui_layout /app/share/lightgui/widgets/build/layout/lightgui_layout + - mkdir -p /app/share/lightgui/widgets/icons + - cp widgets/icons/* /app/share/lightgui/widgets/icons/ + - install -Dm755 flatpak/lightgui-launcher /app/bin/lightgui + - install -Dm644 flatpak/com.hotconfig.LightGUI.desktop /app/share/applications/com.hotconfig.LightGUI.desktop + - install -Dm644 flatpak/com.hotconfig.LightGUI.metainfo.xml /app/share/metainfo/com.hotconfig.LightGUI.metainfo.xml + - install -Dm644 flatpak/icon.png /app/share/icons/hicolor/512x512/apps/com.hotconfig.LightGUI.png diff --git a/flatpak/icon.png b/flatpak/icon.png new file mode 100644 index 0000000..07ca523 Binary files /dev/null and b/flatpak/icon.png differ diff --git a/flatpak/lightgui-launcher b/flatpak/lightgui-launcher new file mode 100755 index 0000000..593df69 --- /dev/null +++ b/flatpak/lightgui-launcher @@ -0,0 +1,5 @@ +#!/bin/sh +# LightGUI Flatpak launcher — start the combined IDE (designer + palette + layout). +# The ide script expects to live next to the binaries, ui/ and widgets/, +# which are installed under /app/share/lightgui/. +exec /app/share/lightgui/ide "$@"