Skip to content

Commit a4b9cc2

Browse files
committed
squashed rebase from master
1 parent 2d6f517 commit a4b9cc2

135 files changed

Lines changed: 18682 additions & 16126 deletions

File tree

Some content is hidden

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

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,4 @@ xcuserdata/
3131
/cmake-build-release/
3232
/.vs/
3333
/CMakeSettings.json
34+
/lib/artist/

.gitmodules

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,3 @@
44
[submodule "lib/external/asio"]
55
path = lib/external/asio
66
url = https://github.com/chriskohlhoff/asio.git
7-
[submodule "lib/artist"]
8-
path = lib/artist
9-
url = https://github.com/cycfi/artist.git

cmake/ElementsConfigApp.cmake

Lines changed: 3 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -43,14 +43,6 @@ else()
4343
endif()
4444
endif()
4545

46-
###############################################################################
47-
# Linux Open GL
48-
49-
if (UNIX AND NOT APPLE)
50-
find_package(PkgConfig REQUIRED)
51-
find_package(OpenGL REQUIRED COMPONENTS OpenGL)
52-
endif()
53-
5446
###############################################################################
5547
# Sources (and Resources)
5648

@@ -120,29 +112,25 @@ elseif (WIN32)
120112
)
121113

122114
if (MSVC)
123-
124-
set_property(TARGET ${ELEMENTS_APP_PROJECT} PROPERTY
125-
MSVC_RUNTIME_LIBRARY "MultiThreaded"
126-
)
127-
128115
target_link_options(${ELEMENTS_APP_PROJECT} PRIVATE
129116
/SUBSYSTEM:WINDOWS /ENTRY:mainCRTStartup shcore.lib
130117
)
131118

132-
add_dependencies(${PROJECT_NAME} windows_dlls)
133-
134119
if (CMAKE_SIZEOF_VOID_P EQUAL 8) # 64 bits?
120+
set(CAIRO_DLL ${ELEMENTS_ROOT}/lib/external/cairo/lib/x64/cairo.dll)
135121
set(FREETYPE_DLL ${ELEMENTS_ROOT}/lib/external/freetype/win64/freetype.dll)
136122
set(FONTCONFIG_DLL ${ELEMENTS_ROOT}/lib/external/fontconfig/x64/fontconfig.dll)
137123
set(ICONV_DLL ${ELEMENTS_ROOT}/lib/external/fontconfig/x64/libiconv.dll)
138124
set(XML2 ${ELEMENTS_ROOT}/lib/external/fontconfig/x64/libxml2.dll)
139125
else()
126+
set(CAIRO_DLL ${ELEMENTS_ROOT}/lib/external/cairo/lib/x86/cairo.dll)
140127
set(FREETYPE_DLL ${ELEMENTS_ROOT}/lib/external/freetype/win32/freetype.dll)
141128
set(FONTCONFIG_DLL ${ELEMENTS_ROOT}/lib/external/fontconfig/x86/fontconfig.dll)
142129
set(ICONV_DLL ${ELEMENTS_ROOT}/lib/external/fontconfig/x86/libiconv.dll)
143130
set(XML2 ${ELEMENTS_ROOT}/lib/external/fontconfig/x86/libxml2.dll)
144131
endif()
145132

133+
file(COPY ${CAIRO_DLL} DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
146134
file(COPY ${FREETYPE_DLL} DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
147135
file(COPY ${FONTCONFIG_DLL} DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
148136
file(COPY ${ICONV_DLL} DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
@@ -170,7 +158,6 @@ endif()
170158
target_link_libraries(${ELEMENTS_APP_PROJECT} PRIVATE
171159
${ELEMENTS_APP_DEPENDENCIES}
172160
elements
173-
${OPENGL_LIBRARIES}
174161
)
175162

176163
if (NOT DEFINED ELEMENTS_APP_INCLUDE_DIRECTORIES)

examples/CMakeLists.txt

100755100644
Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,13 @@ add_subdirectory(dialogs)
1212
add_subdirectory(scale)
1313
add_subdirectory(notebook)
1414
add_subdirectory(doc_aspects)
15-
add_subdirectory(rain)
15+
add_subdirectory(simple_animation)
1616
add_subdirectory(thumbwheels)
1717
add_subdirectory(tooltip)
18-
add_subdirectory(list)
19-
add_subdirectory(active_list)
20-
add_subdirectory(list_arranger)
18+
add_subdirectory(dynamic_list)
19+
add_subdirectory(active_dynamic_list)
2120
add_subdirectory(custom_control)
2221
add_subdirectory(child_window)
2322
add_subdirectory(sync_scrollbars)
2423
add_subdirectory(icons_list)
25-
add_subdirectory(table_list)
2624
add_subdirectory(drop_file)

examples/active_list/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
#include <elements.hpp>
77

88
using namespace cycfi::elements;
9-
using cycfi::artist::rgba;
109

1110
// Main window background color
1211
auto constexpr bkd_color = rgba(35, 35, 37, 255);

examples/basic_sliders_and_knobs/main.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
#include <elements.hpp>
77

88
using namespace cycfi::elements;
9-
using cycfi::artist::rgba;
109

1110
// Main window background color
1211
auto constexpr bkd_color = rgba(35, 35, 37, 255);
@@ -84,8 +83,8 @@ auto make_dial(int index)
8483

8584
auto markers = radial_labels<15>(
8685
hold(dials[index]),
87-
0.7, // Label font size (relative size)
88-
"0", "1", "2", "3", "4", // Labels
86+
0.7, // Label font size (relative size)
87+
"0", "1", "2", "3", "4", // Labels
8988
"5", "6", "7", "8", "9", "10"
9089
);
9190

examples/buttons/main.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@
88
#include <random>
99

1010
using namespace cycfi::elements;
11-
using cycfi::artist::rgba;
12-
namespace colors = cycfi::artist::colors;
1311

1412
// Main window background color
1513
auto constexpr bkd_color = rgba(35, 35, 37, 255);
@@ -43,7 +41,7 @@ view_limits my_custom_button::limits(basic_context const& ctx) const
4341

4442
void my_custom_button::draw(context const& ctx)
4543
{
46-
auto& cnv = ctx.canvas; // The artist canvas
44+
auto& cnv = ctx.canvas; // The canvas
4745
auto bounds = ctx.bounds; // The bounding rectangle
4846

4947
// This is the state of the button. Adjust the rendering based on these if
@@ -59,7 +57,7 @@ void my_custom_button::draw(context const& ctx)
5957
if (value)
6058
bounds = bounds.move(1, 1); // Simulate click
6159

62-
// Render the button using the artist library
60+
// Render the button using the library
6361
cnv.fill_style(colors::dark_slate_blue);
6462
cnv.fill_round_rect(bounds, 8);
6563
cnv.line_width(1);

examples/child_window/main.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,13 @@
66
#include <elements.hpp>
77

88
using namespace cycfi::elements;
9-
using namespace cycfi::artist;
109

1110
// Main window background color
1211
auto constexpr bkd_color = rgba(35, 35, 37, 255);
1312
auto background = box(bkd_color);
1413

1514
auto make_child_window(rect bounds, char const* title)
1615
{
17-
using cycfi::elements::image;
1816
return closable_child_window(
1917
title,
2018
bounds,

examples/custom_control/main.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
#include <infra/support.hpp>
88

99
using namespace cycfi::elements;
10-
using namespace cycfi::artist;
1110
using namespace cycfi;
1211

1312
auto constexpr bkd_color = rgba(35, 35, 37, 255);
@@ -216,7 +215,6 @@ class my_app : public app
216215

217216
auto my_app::make_control()
218217
{
219-
using cycfi::elements::image;
220218
return
221219
layer(
222220
align_center_middle(

examples/dialogs/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77

88
using namespace cycfi::elements;
99
using namespace std::chrono_literals;
10-
using cycfi::artist::rgba;
1110

1211
// Main window background color
1312
auto constexpr bkd_color = rgba(35, 35, 37, 255);

0 commit comments

Comments
 (0)