yaze 0.3.2
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
welcome_screen.cc File Reference
#include "app/editor/ui/welcome_screen.h"
#include <algorithm>
#include <array>
#include <cctype>
#include <chrono>
#include <cmath>
#include <cstdint>
#include <filesystem>
#include <fstream>
#include <limits>
#include <vector>
#include "absl/strings/str_format.h"
#include "absl/time/clock.h"
#include "absl/time/time.h"
#include "app/gui/core/icons.h"
#include "app/gui/core/style_guard.h"
#include "app/gui/core/theme_manager.h"
#include "app/gui/core/ui_helpers.h"
#include "app/gui/widgets/themed_widgets.h"
#include "app/platform/timing.h"
#include "core/project.h"
#include "imgui/imgui.h"
#include "imgui/imgui_internal.h"
#include "util/file_util.h"
#include "util/rom_hash.h"

Go to the source code of this file.

Classes

struct  yaze::editor::anonymous_namespace{welcome_screen.cc}::SnesHeaderMetadata
 
struct  yaze::editor::anonymous_namespace{welcome_screen.cc}::GridLayout
 

Namespaces

namespace  yaze
 
namespace  yaze::editor
 Editors are the view controllers for the application.
 
namespace  yaze::editor::anonymous_namespace{welcome_screen.cc}
 

Macros

#define M_PI   3.14159265358979323846
 

Functions

void yaze::editor::anonymous_namespace{welcome_screen.cc}::UpdateWelcomeAccentPalette ()
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::GetRelativeTimeString (const std::filesystem::file_time_type &ftime)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::ToLowerAscii (std::string value)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::TrimAscii (const std::string &value)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::FormatFileSize (uintmax_t bytes)
 
bool yaze::editor::anonymous_namespace{welcome_screen.cc}::IsRomPath (const std::filesystem::path &path)
 
bool yaze::editor::anonymous_namespace{welcome_screen.cc}::IsProjectPath (const std::filesystem::path &path)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::DecodeSnesRegion (uint8_t code)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::DecodeSnesMapMode (uint8_t code)
 
bool yaze::editor::anonymous_namespace{welcome_screen.cc}::ReadFileBlock (std::ifstream *file, std::streamoff offset, char *out, size_t size)
 
bool yaze::editor::anonymous_namespace{welcome_screen.cc}::LooksLikeSnesTitle (const std::string &title)
 
SnesHeaderMetadata yaze::editor::anonymous_namespace{welcome_screen.cc}::ReadSnesHeaderMetadata (const std::filesystem::path &path)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::ReadFileCrc32 (const std::filesystem::path &path)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::ParseConfigValue (const std::string &line)
 
std::string yaze::editor::anonymous_namespace{welcome_screen.cc}::ExtractLinkedProjectRomName (const std::filesystem::path &path)
 
void yaze::editor::anonymous_namespace{welcome_screen.cc}::DrawTriforceBackground (ImDrawList *draw_list, ImVec2 pos, float size, float alpha, float glow)
 
GridLayout yaze::editor::anonymous_namespace{welcome_screen.cc}::ComputeGridLayout (float avail_width, float min_width, float max_width, float min_height, float max_height, float preferred_width, float aspect_ratio, float spacing)
 
void yaze::editor::anonymous_namespace{welcome_screen.cc}::DrawThemeQuickSwitcher (const char *popup_id, const ImVec2 &button_size)
 
float yaze::editor::GetStaggeredEntryProgress (float entry_time, int section_index, float duration, float stagger_delay)
 

Variables

const ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kTriforceGoldFallback = ImVec4(1.0f, 0.843f, 0.0f, 1.0f)
 
const ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kHyruleGreenFallback = ImVec4(0.133f, 0.545f, 0.133f, 1.0f)
 
const ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kMasterSwordBlueFallback = ImVec4(0.196f, 0.6f, 0.8f, 1.0f)
 
const ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kGanonPurpleFallback = ImVec4(0.502f, 0.0f, 0.502f, 1.0f)
 
const ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kHeartRedFallback = ImVec4(0.863f, 0.078f, 0.235f, 1.0f)
 
const ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kSpiritOrangeFallback = ImVec4(1.0f, 0.647f, 0.0f, 1.0f)
 
const ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kShadowPurpleFallback = ImVec4(0.416f, 0.353f, 0.804f, 1.0f)
 
constexpr float yaze::editor::anonymous_namespace{welcome_screen.cc}::kRecentCardBaseWidth = 240.0f
 
constexpr float yaze::editor::anonymous_namespace{welcome_screen.cc}::kRecentCardBaseHeight = 128.0f
 
constexpr float yaze::editor::anonymous_namespace{welcome_screen.cc}::kRecentCardWidthMaxFactor = 1.30f
 
constexpr float yaze::editor::anonymous_namespace{welcome_screen.cc}::kRecentCardHeightMaxFactor = 1.30f
 
ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kTriforceGold = kTriforceGoldFallback
 
ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kHyruleGreen = kHyruleGreenFallback
 
ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kMasterSwordBlue = kMasterSwordBlueFallback
 
ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kGanonPurple = kGanonPurpleFallback
 
ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kHeartRed = kHeartRedFallback
 
ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kSpiritOrange = kSpiritOrangeFallback
 
ImVec4 yaze::editor::anonymous_namespace{welcome_screen.cc}::kShadowPurple = kShadowPurpleFallback
 

Macro Definition Documentation

◆ M_PI