Class ThemeEditorExample

java.lang.Object
limn.demo.site.ThemeEditorExample

public final class ThemeEditorExample extends Object
The theme editor as the site captures it: the module's own screen, and nothing this file adds.

The point of publishing it is that limn-theme-editor is a module an application opts into, not a program shipped with the toolkit, so the picture has to be the widget an application would embed, arranged the way that application would arrange it, rather than a demo built around it.

No explanatory text. The demo's own editor scene carries a paragraph describing what the editor does, which belongs there; on the site that sentence is the page's job, in the page's type size and in the reader's language: a capture cannot be translated.

  • Method Details

    • content

      public static Widget content()
      The editor filling the window, under the palette currently in force.

      Theme.current() rather than a palette named here: the capture sets the palette before it builds, and the editor loads whatever it is handed as the palette being edited, so this screen shows the shipped light theme being edited in the light pass and the dark one in the dark pass, which is what a reader would see on their own machine.

    • scene

      public static Scene scene()
      The screen on a canvas, wearing a typeface the palette asked for. Filmed by the capture; see Films.forShowcase.

      A face this repository ships, not one this machine happens to have. The obvious reading of "show it in a system font" is to take the first family the operating system offers, and it cannot be done here: the gallery is captured on a developer's machine and again on a Linux runner with an entirely different font set, so the published picture would depend on which of the two ran last. Inter is committed under limn-demo/fonts/, so every machine renders the same screen, and it is a real family the toolkit had to resolve, not the embedded default under another name.

      The family comes from Fonts.load(java.nio.file.Path), never from a literal: the name a file declares and the name of the file need not agree, and a name that resolved to nothing would render the screen in the default face and publish it without a word in the log.