Compare commits

...

7 Commits

Author SHA1 Message Date
e259a55db8 [nostalgia] Make pkg-dmg delete bundle after archive created
All checks were successful
Build / build (push) Successful in 1m14s
2025-05-08 23:30:26 -05:00
4b4831317a [nostalgia] Update release notes
Some checks failed
Build / build (push) Has been cancelled
2025-05-08 23:28:05 -05:00
e015c4e4c7 [studio] Remove ability to re-order Editor tabs 2025-05-08 23:27:11 -05:00
9ff614095f [nostalgia/gfx/studio/tilesheet] Fix Delete Tile functionality
All checks were successful
Build / build (push) Successful in 1m16s
2025-05-08 02:05:58 -05:00
0168c52183 [keel] Cleanup 2025-05-08 02:05:58 -05:00
253455efc4 [keel] Cleanup 2025-05-08 02:05:40 -05:00
9229713ba2 [nostalgia/studio] Set version to d2025.05.0
All checks were successful
Build / build (push) Successful in 1m22s
2025-05-07 20:27:06 -05:00
8 changed files with 26 additions and 17 deletions

View File

@ -1,13 +1,16 @@
# d2025.05.0
* Add app icon for both window and file
* Change application font to Roboto Medium
* Closing application will now confirm with user if any files have unsaved
changes.
* UUID duplicates will now be reported when opening a project
* Deleting a directory now closes files in that directory
* Delete key now initiates deletion of selected directory
* Remove ability to re-order tabs. There were bugs associated with that.
* TileSheetEditor: Fix selection clearing in to work when clicking outside
image.
* TileSheetEditor: Fix Delete Tile functionality, which was completely broken
* PaletteEditor: Fix color number key range in. Previously, pressing A caused
the editor to jump to the last color.
* PaletteEditor: page rename will now take effect upon pressing enter if the

View File

@ -8,14 +8,14 @@
namespace nostalgia::gfx {
gfx::DeleteTilesCommand::DeleteTilesCommand(
DeleteTilesCommand::DeleteTilesCommand(
TileSheet &img,
TileSheet::SubSheetIdx idx,
std::size_t tileIdx,
std::size_t tileCnt) noexcept:
std::size_t const tileIdx,
std::size_t const tileCnt) noexcept:
m_img(img),
m_idx(std::move(idx)) {
const unsigned bytesPerTile = m_img.bpp == 4 ? PixelsPerTile / 2 : PixelsPerTile;
constexpr unsigned bytesPerTile = PixelsPerTile;
m_deletePos = tileIdx * bytesPerTile;
m_deleteSz = tileCnt * bytesPerTile;
m_deletedPixels.resize(m_deleteSz);
@ -31,13 +31,17 @@ gfx::DeleteTilesCommand::DeleteTilesCommand(
ox::Error gfx::DeleteTilesCommand::redo() noexcept {
auto &s = getSubSheet(m_img, m_idx);
auto &p = s.pixels;
auto srcPos = m_deletePos + m_deleteSz;
auto const src = &p[srcPos];
auto const srcPos = m_deletePos + m_deleteSz;
auto const dst1 = &p[m_deletePos];
auto const dst2 = &p[(p.size() - m_deleteSz)];
OX_ALLOW_UNSAFE_BUFFERS_BEGIN
ox::memmove(dst1, src, p.size() - srcPos);
ox::memset(dst2, 0, m_deleteSz * sizeof(decltype(p[0])));
if (srcPos < p.size()) {
auto const src = &p[srcPos];
ox::memmove(dst1, src, p.size() - srcPos);
ox::memset(dst2, 0, m_deleteSz * sizeof(decltype(p[0])));
} else {
ox::memset(dst1, 0, p.size() - m_deletePos);
}
OX_ALLOW_UNSAFE_BUFFERS_END
return {};
}
@ -46,11 +50,14 @@ ox::Error DeleteTilesCommand::undo() noexcept {
auto &s = getSubSheet(m_img, m_idx);
auto &p = s.pixels;
auto const src = &p[m_deletePos];
auto const dst1 = &p[m_deletePos + m_deleteSz];
auto const dst2 = src;
auto const sz = p.size() - m_deletePos - m_deleteSz;
auto const srcPos = m_deletePos + m_deleteSz;
OX_ALLOW_UNSAFE_BUFFERS_BEGIN
ox::memmove(dst1, src, sz);
if (srcPos < p.size()) {
auto const dst1 = &p[m_deletePos + m_deleteSz];
ox::memmove(dst1, src, sz);
}
auto const dst2 = src;
ox::memcpy(dst2, m_deletedPixels.data(), m_deletedPixels.size());
OX_ALLOW_UNSAFE_BUFFERS_END
return {};

View File

@ -15,7 +15,7 @@ target_link_libraries(
target_compile_definitions(
NostalgiaStudio PUBLIC
OLYMPIC_APP_VERSION="dev build"
OLYMPIC_APP_VERSION="d2025.05.0"
)
install(

View File

@ -18,7 +18,7 @@
<string>APPL</string>
<key>CFBundleVersion</key>
<string>dev build</string>
<string>d2025.05.0</string>
<key>LSMinimumSystemVersion</key>
<string>12.0.0</string>

View File

@ -12,8 +12,6 @@
namespace keel {
class Context;
class Context {
public:
ox::UPtr<ox::FileSystem> rom;

View File

@ -182,7 +182,7 @@ ox::Result<ox::CStringView> uuidToPath(Context &ctx, ox::UUID const&uuid) noexce
#endif
}
ox::Error reloadAsset(keel::Context &ctx, ox::StringViewCR assetId) noexcept {
ox::Error reloadAsset(Context &ctx, ox::StringViewCR assetId) noexcept {
if (beginsWith(assetId, "uuid://")) {
return ctx.assetManager.reloadAsset(substr(assetId, 7));
} else {

View File

@ -255,7 +255,7 @@ void StudioUI::drawMenu() noexcept {
void StudioUI::drawTabBar() noexcept {
auto const viewport = ImGui::GetContentRegionAvail();
ImGui::BeginChild("TabWindow##MainWindow##Studio", ImVec2(viewport.x, viewport.y));
constexpr auto tabBarFlags = ImGuiTabBarFlags_Reorderable | ImGuiTabBarFlags_TabListPopupButton;
constexpr auto tabBarFlags = ImGuiTabBarFlags_TabListPopupButton;
if (ImGui::BeginTabBar("TabBar##TabWindow##MainWindow##Studio", tabBarFlags)) {
drawTabs();
ImGui::EndTabBar();

View File

@ -34,3 +34,4 @@ mkdir_p(dmg_dir)
shutil.copytree('dist/darwin-arm64-release/NostalgiaStudio.app', f'{dmg_dir}/NostalgiaStudio.app')
os.symlink('/Applications', f'{dmg_dir}/Applications')
run(['hdiutil', 'create', '-srcfolder', dmg_dir, dmg])
rm(dmg_dir)