For example, check out the following CSS. You would use these media queries when setting up CSS styling for a Web page. amzn-mobi: This media query applies to the Mobi format, which is supported by other devices.amzn-kf8: This media query applies to the Kindle Format 8 (KF8) format, which was introduced for the Kindle Fire devices, and is also supported by Kindle Paperwhite devices.You can determine whether a newer or older Kindle is being used by leveraging Amazon’s CSS media queries.Īmazon supports the following media queries for distinguishing between Kindle Fire-class devices and other Kindle devices: Newer Kindles offer better CSS styling support, which lets you present nicely-formatted code listings. For example, we could present code listings on the Kindle Paperwhite and Kindle Fire devices, which have wider screens, and we could present placeholder image/clickable links for other Kindle devices (with narrower screens). Not only is the resulting e-book smaller (thus minimizing the Amazon delivery charge), that solution lets you leverage the device’s browser to better view the code.īut I think we can do even better. Introducing a clickable placeholder image in lieu of individual code listing images is an improvement. Solution 3: Use Media Queries, CSS, and Links However, relying on this solution for presenting all of your code listings will probably cost you. Placing a few high-quality images in a book typically isn’t a problem. A book with many images may mushroom in size, resulting in a delivery fee that could consume your profit on each book sale. Amazon charges a delivery fee that’s typically 15 cents per megabyte.An image of a lengthy vertical listing may be presented at the top of a subsequent page, leaving lots of vertical whitespace on the previous page.Also, the text may appear fuzzy or blurry making it hard to read and leading to eye strain.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |