Writable Books #27
Labels
area: Gameplay Scalability
area: GUI
area: Player Ability
area: QoL/UX
area: Rendering
engine: Graphics
engine: Menu
feature: Addition
feature: Expansion
feature: Update
gameplay: Enhancement
scope: Feature
status: Advisory
Requiring more ideas or brainstorming about issue.
status: Blocked
status: Sketchy
Requiring more details and/or examples about issue.
type: Migrated
type: Plan
Milestone
Original: MinicraftPlus/minicraft-plus-revived#319
Requires #26 and #53
Background
The current book item is not editable and useable for players, but just placeholders.
Details
Instead of just single
BookItem
, we would haveWrittenBook
andEditableBook
for both written version (read-only) and writable version (read-write). Both types can be used in structures for loots with written contents. However, writable books would allow players to author, sign and complete the books as written ones. The actual implementation might be similar to Minecraft, but adding that there might be more formattable parts like page linking in the content page. Other than book-favoured syntaxes, the general text formatting codes (#53) would be available.Markup
The formatting codes in #53 would be supported, plus hyperlinks. Complex markups like lists or tables could not be supported, but simple links could be supported. They could either by website URLs (i.e. protocol with HTTP or HTTPS) or page numbers (a specific page in the book). Others would not be supported. If the links are websites, a warning is always popped up and could not be disabled for security concerns. Anyway, even keyboard-only controls would be able to access the hyperlinks, by iterating over available hyperlinks on the current page. An unselected one would be displayed with an inverted-colored underline for distinguishment and identification; a selected one would be displayed without the underline (or blinking the underline) informing the user. The syntax might just be extended from the formatting codes without having to bother more escapable sequences.
Editing
Due to the above complexity, having a live preview is pretty challenging in this menu style. So, other than editing previewing text, there could still be a toggle to preview on the editing menu of an editable book.
If using a mouse, the user could click on empty area to hide the caret but it still functions at the position. In addition, regardless of controls, if the caret has been rest for a few seconds, it stops blinking but stays visible. This behavior would be configurable in accessibility settings.
Lines & Pages
Line breaks (ENTER) and form feeds (SHIFT+ENTER) would display as is. However, if certain lines are long in editor, the lines may not be broken, but depending on the resulting length on display. If there are lines across page without any form feed, the lines may be merged onto the page in the front, depending how many lines are displayed in the pages, but a form feed is not affected by this. A line break or a form feed can be deleted by DELETE or BACKSPACE according to the position of cursor.
See Also
The text was updated successfully, but these errors were encountered: