将SFML从cmake的依赖项改为git的依赖项
This commit is contained in:
parent
77d2d45b20
commit
781e62f041
|
@ -0,0 +1,3 @@
|
|||
[submodule "deps/SFML"]
|
||||
path = deps/SFML
|
||||
url = https://github.com/SFML/SFML.git
|
|
@ -3,11 +3,7 @@ project(SFTK LANGUAGES CXX)
|
|||
|
||||
set(CXX_STANDARD_REQUIRED 23)
|
||||
|
||||
include(FetchContent)
|
||||
FetchContent_Declare(SFML
|
||||
GIT_REPOSITORY https://github.com/SFML/SFML.git
|
||||
GIT_TAG 2.6.x)
|
||||
FetchContent_MakeAvailable(SFML)
|
||||
add_subdirectory(./deps/SFML)
|
||||
|
||||
set(ROOT src/)
|
||||
set(CONTAINER src/containers)
|
||||
|
|
Binary file not shown.
|
@ -5,8 +5,9 @@
|
|||
int main()
|
||||
{
|
||||
auto &window = sftk::Window::create(800, 600, L"demo1");
|
||||
auto &label = sftk::Label::create(L"hello SFTK.", sftk::Font("SarasaUiSC-Regular.ttf", "", 18));
|
||||
label.setColor(sf::Color::White);
|
||||
window.setBackgroudColor(sf::Color::White);
|
||||
auto &label = sftk::Label::create(L"hello SFTK.", sftk::Font("../demo/SarasaUiSC-Regular.ttf", "", 18));
|
||||
label.setColor(sf::Color::Black);
|
||||
label.setPosition(vec(100.f, 100.f));
|
||||
window.exec();
|
||||
}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 69ea0cd863aed1d4092b970b676924a716ff718b
|
Loading…
Reference in New Issue