The cup ring shows only where the lower right corner of the page is free
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
1 parent
ee2968d1a3
commit
26e975ac9d
1 file changed
+9
-1
@@ -218,7 +218,15 @@ std::string App::notebook_shell(const std::function<bool(const std::string &)> &
|
||||
lines += "<path d=\"M66 8V858\" stroke=\"" + margin + "\" stroke-opacity=\"" + (light ? "1" : ".4") + "\" stroke-width=\"2\"/>";
|
||||
// the ring a cup left in the lower right corner: only where the page keeps that corner free or covers it
|
||||
// with a panel of its own, never under bare writing or an older sheet
|
||||
const bool stain = menu_.empty() || (page_native() && menu_ != "tactics");
|
||||
// (the transfer market keeps it free; on the home page it shows while no card lies on the last two cells of the bottom row)
|
||||
bool stain = menu_ == "transfer" && page_native();
|
||||
if (menu_.empty()) {
|
||||
stain = true;
|
||||
const auto &pages = notebook_pages().at("pages");
|
||||
if (home_page_ >= 0 && home_page_ < int(pages.size()))
|
||||
for (const auto &card : pages[size_t(home_page_)].at("cards"))
|
||||
if (card.at("row").get<int>() + card.at("rows").get<int>() - 1 >= 5 && card.at("col").get<int>() + card.at("cols").get<int>() - 1 >= 7) stain = false;
|
||||
}
|
||||
if (stain) lines += "<g fill=\"none\" stroke=\"" + ring + "\"><path d=\"M1183 800A61 61 0 1 1 1257 786\" stroke-width=\"6\" stroke-opacity=\".13\" stroke-linecap=\"round\"/><path d=\"M1200 720A58 58 0 1 0 1290 716\" stroke-width=\"2\" stroke-opacity=\".1\"/></g>";
|
||||
out += "<div class=\"nb-paper\">" + picture(paper, 3163.5, 1948.5, true) + "<div class=\"nb-paper-edge\"></div>";
|
||||
if (const auto art = notebook_art(); !art.token.empty()) out += "<div class=\"nb-paper-art\">" + picture(art, 3163.5, 1948.5, true) + "</div>";
|
||||
|
||||
Reference in new issue
Block a user