Skip to content

Theme integration #612

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 7 commits into
base: dev
Choose a base branch
from
Open

Theme integration #612

wants to merge 7 commits into from

Conversation

SK1PPR
Copy link

@SK1PPR SK1PPR commented Apr 30, 2025

No description provided.

@SK1PPR SK1PPR force-pushed the theme-integration branch from 854061d to a0662f4 Compare April 30, 2025 18:42
@SK1PPR SK1PPR force-pushed the theme-integration branch from a0662f4 to 88dcf3e Compare April 30, 2025 18:46
@SK1PPR SK1PPR force-pushed the theme-integration branch from 88dcf3e to a211c1f Compare April 30, 2025 18:47
@SK1PPR
Copy link
Author

SK1PPR commented May 1, 2025

@twaritwaikar I have added a 3rd party header for reading the json files, for now placed it in the same directory only, but should I place it somewhere else? maybe make a 3rdparty folder. Also please review current changes

@twaritwaikar
Copy link
Member

@SK1PPR We already have a JSON library present here - https://github.com/sdslabs/Rootex/tree/dev/rootex%2Fvendor%2FJSON

You can try to find examples of how we use it and just do the same here

@twaritwaikar
Copy link
Member

You probably have the nholmann/json library in the scope. This is how it's utilized in types.h - https://github.com/sdslabs/Rootex/blob/dev/rootex%2Fcommon%2Ftypes.h#L158

types.h should be already included in the scope. If not, just add it and you will have the JSON namespace from there

@SK1PPR SK1PPR force-pushed the theme-integration branch from 52a8dfe to 69811c8 Compare May 4, 2025 10:52
@SK1PPR
Copy link
Author

SK1PPR commented May 4, 2025

Clang-format 11 use ho raha in the gh-action, and currently 20 h isiliye failed aa raha, mai isko theek krne ka dekhta

@SK1PPR SK1PPR force-pushed the theme-integration branch from bcb1c33 to cce0011 Compare May 4, 2025 11:07
@SK1PPR
Copy link
Author

SK1PPR commented May 4, 2025

Ab toh nhi pata why it is failing clang-format ka test, mai isko ete baad dekhta

@@ -170,6 +172,18 @@ bool EditorSystem::initialize(const JSON::json& systemData)
colors[ImGuiCol_ModalWindowDimBg] = ImVec4(1.00f, 0.98f, 0.95f, 0.73f);
}

// Load json theme data
for (const auto& entry : std::filesystem::directory_iterator("editor/themes"))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Register this into types.h too. We avoid writing down std::* around the engine. Typedef it to DirectoryIterator most likely.

struct ThemeDefinition
{
String m_Name;
String m_filePath;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

m_FilePath

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants