-
Notifications
You must be signed in to change notification settings - Fork 4
ImGui upgrade + full EzyCad GUI integration, Lua/TextEditor console, optional embedded Python console (native), and wasm HiDPI/font fixes #57
Copy link
Copy link
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
High-level themes
- Dear ImGui upgrade — Substantial update across
third_party/imgui/*(version file, backends, core). Review risk: API/behavior changes, font/layout, input. - EzyCad + ImGui integration —
main.cppdrives fullGUIflow (init, render, settings save on exit, GLFW callback chaining, wasm vs native font paths). - HiDPI / Emscripten — Content scale, font loading without double-scaling,
imgui_impl_glfwcanvas/DPR-related behavior;web/EzyCad.htmltweaks. - Lua script console — ImGuiColorTextEdit for
.luatabs; monospace console font (Cousine) where applied; menu/shortcuts for script console visibility. - Python console (native) — Optional embedded CPython via pybind11,
Python_console,cmake/EzyCadPython.cmake,res/scripts/python/basic.py, CMake copy of Python DLL on Windows. - Settings / UX — GUI pane persistence includes Python console visibility; log messages for settings load/save (see
gui.cpphistory in diff). - Misc —
occt_view.cppsmall wasm-related tweak;main_orig.cppstub;.gitignoreentries.
Files changed (excluding vendored ImGui)
These are the application / build files that typically matter most in review:
| Path | Role |
|---|---|
CMakeLists.txt |
Python optional embed, pybind11 FetchContent, font/preload/copy steps, link targets |
cmake/EzyCadPython.cmake |
Windows-friendly Python dev lib / DLL resolution for embedding |
src/main.cpp |
Window creation, scaling, fonts (DroidSans + Cousine), ImGui backends, GUI lifecycle, input chaining |
src/gui.cpp, src/gui.h |
Menus, panes, script/Python console toggles, settings JSON fields |
src/lua_console.cpp, src/lua_console.h |
Lua REPL + script tabs (TextEditor), monospace font usage |
src/python_console.cpp, src/python_console.h |
Python REPL + ezycad_native bindings + script tabs |
res/scripts/python/basic.py |
Sample Python script shipped under res/scripts/python |
web/EzyCad.html |
Wasm shell / layout |
src/occt_view.cpp |
Minor platform-specific rendering note |
src/main_orig.cpp |
Stub / pointer to history |
.gitignore |
Ignore rules |
Vendored subtree (large diff): third_party/imgui/** — treat as upstream ImGui import; validate against your expected ImGui version in third_party/imgui/IMGUI_VERSION.txt.
Python console (build & runtime)
- CMake option:
EZYCAD_ENABLE_PYTHON(ON by default for non-Emscripten builds in this branch). - Requires: Python 3 development headers/libs discoverable by
find_package(Python3 COMPONENTS Development). - Not for wasm: Embedding CPython like this is native-only; Emscripten path should still build without Python.
- Windows: Post-build can copy
python3xx.dllnext toEzyCad.exewhen resolved (seeEzyCadPython.cmake).
Suggested review checklist
- ImGui regression pass — docking-free layout, fonts, widgets, file dialogs, log window.
- Native — Debug/Release, Python ON/OFF (
-DEZYCAD_ENABLE_PYTHON=OFF), missing Python dev kit → clean disable message. - Wasm — Canvas size, mouse/keyboard, fonts, Lua console (no Python).
- Settings —
ezycad_settings.jsonround-trip; new keys (show_python_console, etc.) don’t break older files. - Consoles — Lua + Python bindings (
ezy,view, shape wrappers), script tab save/load paths underres/scripts/*.
Follow-ups (optional)
- Squash commits and replace “WIP” messages with a single conventional summary.
- Document Python embedding prerequisites in
README.md(if you want users to build with Python by default). - Add CI matrix: build with
EZYCAD_ENABLE_PYTHON=OFFto avoid hard dependency on Python dev packages.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request