For the e-reader, convert the SVG file into a PNG image. Write your own e-book using the menu image as the cover. E-books are written in EPUB format, a standardized format used by all e-readers except Kindles. EPUBs are zip files with a renamed extension. Writing an e-book is similar to writing a website, using HTML, CSS, and images for each chapter. EPUB uses XHTML, with self-closing tags and lowercase names. Include CSS and use tags like H1, P, and image. EPUBs need a content.OPF file that acts as a site map, including metadata, manifest, spying, and guide.
For the e-reader, I convert the SVG file into a PNG image, which you can do using free tools like Inkscape and Squoosh. Some e-readers let you upload a custom locked screen image, I can connect it to my computer, then drag this image onto its hard drive in a screensaver folder.
Other e-readers do not have this feature. However, most of them will show the cover of whatever book you're reading when locked. We can abuse this by writing our own e-book using the menu image as the cover of the book.
Now when I say e-book, you probably think of a digital version of a big book like this with lots of choppers. But our e-book is going to be more like a pamphlet. If you have at least one page, you can write an e-book.
E-books are written in a format called EPUB. This is a standardized format used by all e-readers except Kindles but Amazon lets you easily convert from EPUB into Kindle's custom format. EPUBs are actually just zip files that have their extension renamed.
Just like websites, e-books need to be responsive since you can have different e-reader screen sizes. As a result, writing an e-book is very similar to writing a website. You use familiar HTML, CSS, and images to create each chapter of the book. In a website, each HTML file is a page on your site, but in an e-book, each HTML file is a chapter of your book.
EPUB uses a stricter version of HTML called XHTML. You need to make sure that your self-closing tags have a slash and that your tag names are all lowercase. This might sound familiar because these are the exact same restrictions that JSX has, but other than that, everything is the same. You can include CSS and use the same tags like H1 and P and image.
EPUBs also need a file called content.OPF, which acts like a site map. This file includes data, like the title of the book, every file in the zip folder, the book chapters in order, and bookmarks to some important pages. Here's an example. The content file is written in XML. Let's hide the unimportant parts. You can see it broken down into a few tags, similar to how an HTML file is broken down into head and body tags. Metadata includes the title of the book and the cover image. Manifest includes all the files in the book. Some files have been assigned an id that can be referenced in upper sections. Spying indicates the order of the chapters. And guide points to important pages, like the table of contents.
Comments