Skip to content

Commit 659f2f3

Browse files
committed
Merge Develop Branch
Various Improvements/Fixes: - Better Cursor support; the cursor now always shows through the character underneath it. - Fixed deploy/build on Mac. Doesn't build on travis yet due to the latest compiler not on there. But Mac does currently build and run. - Added version and bundle info and icons to the demos. This is just for my own learning to understand how to properly package things; but it makes the build of the demos cleaner - Demos are moved into their own folder - Moved the extension code for Orca/Repl out of the main source tree and into extensions. - DPI Fixes/Tweaks to get consistent font sizing/scaling on Mac and windows. - Various work in progress improvements to the Orca extension. This is just for the live coding tool.
1 parent 77dfcbd commit 659f2f3

File tree

132 files changed

+2571
-426
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

132 files changed

+2571
-426
lines changed

.vscode/launch.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,11 @@
88
"name": "(lldb) Launch",
99
"type": "cppdbg",
1010
"request": "launch",
11-
"program": "${workspaceFolder}/build/ZepDemo",
11+
//"program": "${workspaceFolder}/build/demos/demo_qt/ZepDemo-qt",
12+
"program": "${workspaceFolder}/build/demos/demo_imgui/ZepDemo",
1213
"args": [],
1314
"stopAtEntry": false,
14-
"cwd": "${workspaceFolder}",
15+
"cwd": "${workspaceFolder}/build",
1516
"environment": [],
1617
"externalConsole": false,
1718
"MIMode": "lldb"

CMakeLists.txt

+10-13
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
cmake_minimum_required(VERSION 3.2)
22

3-
message(STATUS " CMakeLists: Zep")
3+
message(STATUS "CMakeLists: Zep")
4+
message(STATUS "Build Type: " ${CMAKE_BUILD_TYPE})
5+
6+
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR}/cmake)
47

58
# Global Options
69
option(BUILD_QT "Make Qt Library" OFF)
@@ -32,7 +35,6 @@ include(CMakePackageConfigHelpers)
3235
if (ZEP_FEATURE_CPP_FILE_SYSTEM)
3336
add_definitions(-DZEP_FEATURE_CPP_FILE_SYSTEM)
3437
endif()
35-
add_definitions(-DZEP_USE_SDL)
3638

3739
# config_app.h checks
3840
# This makes a config_shared.h file which can be included for system settings
@@ -49,17 +51,10 @@ include(cmake/all.cmake)
4951
include(m3rdparty/cmake/copy_files.cmake)
5052

5153
# The main library
52-
include(${ZEP_ROOT}/extensions/CMakeLists.txt)
53-
include(src/CMakeLists.txt)
54-
55-
include (tests/CMakeLists.txt)
56-
57-
# Demos require example interpreter and other 3rdparty
58-
IF (BUILD_DEMOS)
59-
include(${M3RDPARTY_DIR}/list.cmake)
60-
include(demo_imgui/CMakeLists.txt)
61-
include(demo_qt/CMakeLists.txt)
62-
ENDIF()
54+
add_subdirectory(extensions)
55+
add_subdirectory(src)
56+
add_subdirectory(tests)
57+
add_subdirectory(demos)
6358

6459
# Make the CMake bits that ensure find_package does the right thing
6560
install(EXPORT zep-targets
@@ -87,3 +82,5 @@ install(
8782
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/zep
8883
)
8984

85+
include(${CMAKE_CURRENT_LIST_DIR}/cmake/cpack_installer.cmake)
86+

Info.plist

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>NSHighResolutionCapable</key>
6+
<true/>
7+
</dict>
8+
</plist>

build_all.sh

+7
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
1+
#!/bin/bash
2+
3+
if [ "$1" != "" ] ; then
14
source config_all.sh
5+
else
6+
source config_all.sh $1
7+
fi
8+
29
cd build
310
make --debug
411
sudo make install

cmake/cpack_installer.cmake

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
#installer rules.
2+
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Zep Installer")
3+
set(CPACK_PACKAGE_VENDOR "Zep")
4+
set(CPACK_PACKAGE_VERSION ${PROJECT_VER})
5+
set(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VER_MAJOR})
6+
set(CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VER_MINOR})
7+
set(CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VER_PATCH})
8+
set(CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL OFF)
9+
set(CPACK_NSIS_MODIFY_PATH ON)
10+
#if you have an icon set the path here
11+
# SET(CPACK_NSIS_MUI_ICON "${CMAKE_CURRENT_SOURCE_DIR}/my_cool_icon.ico")
12+
set(CPACK_PACKAGE_INSTALL_DIRECTORY "Zep\\\\Zep")
13+
set(CPACK_NSIS_INSTALLED_ICON_NAME "bin\\\\ZepDemo.exe")
14+
set(CPACK_NSIS_DISPLAY_NAME "ZepDemo ${PROJECT_VER}")
15+
#set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/EULA.txt")
16+
17+
# set component installation rules
18+
set(CPACK_COMPONENT_BINARIES_DISPLAY_NAME "Main application")
19+
set(CPACK_COMPONENT_BINARIES_DESCRIPTION "This will install the main application.")
20+
set(CPACK_COMPONENT_DATA_FILES_DISPLAY_NAME "Data files for this application.")
21+
set(CPACK_COMPONENT_DATA_FILES_DESCRIPTION "This will install random data files.")
22+
set(CPACK_ALL_INSTALL_TYPES Full Upgrade) #set installation types
23+
set(CPACK_COMPONENT_BINARIES_INSTALL_TYPES Full Upgrade)
24+
set(CPACK_COMPONENT_DATA_FILES_INSTALL_TYPES Full)
25+
set(CPACK_COMPONENTS_ALL binaries)
26+
if (CMAKE_CL_64)
27+
set(CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES64")
28+
else (CMAKE_CL_64)
29+
set(CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES")
30+
endif (CMAKE_CL_64)
31+
include(CPack)

cmake/mac.cmake

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ LIST(APPEND PLATFORM_LINKLIBS
1616
dl
1717
"-framework CoreFoundation"
1818
z
19-
libbz2.dylib
20-
libiconv.dylib
19+
libbz2.a
20+
libiconv.a
2121
)
2222

config_all.sh

+5-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,9 @@
22

33
mkdir build
44
cd build
5-
cmake -G "Unix Makefiles" -DBUILD_QT=ON -DBUILD_IMGUI=ON ../
5+
if [ "$1" != "" ] ; then
6+
cmake -G "Unix Makefiles" -DBUILD_QT=ON -DBUILD_IMGUI=ON -DCMAKE_BUILD_TYPE=$1 ../
7+
else
8+
cmake -G "Unix Makefiles" -DBUILD_QT=ON -DBUILD_IMGUI=ON -DCMAKE_BUILD_TYPE=Release ../
9+
fi
610
cd ../

demo_imgui/CMakeLists.txt

-84
This file was deleted.

demo_qt/app.exe.manifest

-5
This file was deleted.

demo_qt/app.qrc

-10
This file was deleted.

demo_qt/app.rc

-1.72 KB
Binary file not shown.

demo_qt/main-qt.cpp

-16
This file was deleted.

demo_qt/qml.qrc

-8
This file was deleted.

demo_qt/res/AppIcon.icns

-183 KB
Binary file not shown.

demo_qt/res/AppIcon.ico

-106 KB
Binary file not shown.

demo_qt/res/AppIcon128.png

-6.33 KB
Binary file not shown.

demo_qt/res/AppIcon32.png

-1.39 KB
Binary file not shown.

demo_qt/res/screwdriver.ico

-113 KB
Binary file not shown.

demo_qt/res/textured-paper.png

-137 KB
Binary file not shown.

demo_qt/res/white-sand.png

-17.1 KB
Binary file not shown.

demos/CMakeLists.txt

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
if (BUILD_DEMOS)
2+
3+
# Set additional project information
4+
set(COMPANY "Zep")
5+
set(COPYRIGHT "Copyright (c) 2019 Chris Maughan. All rights reserved.")
6+
set(IDENTIFIER "com.zep")
7+
8+
list(INSERT CMAKE_MODULE_PATH 0 ${CMAKE_CURRENT_LIST_DIR}/cmake)
9+
10+
include(${M3RDPARTY_DIR}/list.cmake)
11+
include(${CMAKE_CURRENT_LIST_DIR}/cmake/demo_common.cmake)
12+
add_subdirectory(demo_imgui)
13+
add_subdirectory(demo_qt)
14+
15+
endif()

demos/cmake/MacOSXBundleInfo.plist.in

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleDevelopmentRegion</key>
6+
<string>English</string>
7+
<key>CFBundleExecutable</key>
8+
<string>${MACOSX_BUNDLE_EXECUTABLE_NAME}</string>
9+
<key>CFBundleGetInfoString</key>
10+
<string>${MACOSX_BUNDLE_INFO_STRING}</string>
11+
<key>CFBundleIconFile</key>
12+
<string>${MACOSX_BUNDLE_ICON_FILE}</string>
13+
<key>CFBundleIdentifier</key>
14+
<string>${MACOSX_BUNDLE_GUI_IDENTIFIER}</string>
15+
<key>CFBundleInfoDictionaryVersion</key>
16+
<string>6.0</string>
17+
<key>CFBundleLongVersionString</key>
18+
<string>${MACOSX_BUNDLE_LONG_VERSION_STRING}</string>
19+
<key>CFBundleName</key>
20+
<string>${MACOSX_BUNDLE_BUNDLE_NAME}</string>
21+
<key>CFBundlePackageType</key>
22+
<string>APPL</string>
23+
<key>CFBundleShortVersionString</key>
24+
<string>${MACOSX_BUNDLE_SHORT_VERSION_STRING}</string>
25+
<key>CFBundleSignature</key>
26+
<string>????</string>
27+
<key>CFBundleVersion</key>
28+
<string>${MACOSX_BUNDLE_BUNDLE_VERSION}</string>
29+
<key>CSResourcesFileMapped</key>
30+
<true/>
31+
<key>LSRequiresCarbon</key>
32+
<true/>
33+
<key>NSHumanReadableCopyright</key>
34+
<string>${MACOSX_BUNDLE_COPYRIGHT}</string>
35+
<key>NSPrincipalClass</key>
36+
<string>NSApplication</string>
37+
<key>NSHighResolutionCapable</key>
38+
<string>True</string>
39+
</dict>
40+
</plist>

0 commit comments

Comments
 (0)