OpenDyslexic version
While estimates differ, its safe to say that somewhere between 10% and 20% of people suffer from some kind of cognitive impairment that hinders their reading. Although there are clear signs that there are some quite distinct forms of cognitive impairment and that for some, definitely not all forms, there are things publishers and eReading device designers could do, helping to give large groups of people access to the joys of reading. For me, font size doesn't really affect my ability to read in any way. The font does however and what for me personally is the most essential is line spacing. For other people, the font isn't really that much of a factor but font size helps tremendously. With technology at our disposal, there should be much room for individual tuning, right? Unfortunately the industry doesn't seem to think so. My first android phone allowed me to buy friendly fonts in the application store and I was quite happy about that. Than Google released a new android version and guess what, they removed the possibility of using custom fonts. Why Google? Why? Being technically savvy, I managed to install my personal favorite font on my own old ereader that wasn't designed to support system wide custom fonts and that didn't respect embedded fonts in my favorite books either. For many people though, such things are outside of reach. The default eReading app on Android, Play Books, has the reverse problem, it does not allow adding a custom system wide font, yet it respects embedded fonts in epubs. FBReader, same problem. Other solutions like Aldiko are the worst of both worlds. No custom fonts and embedded fonts are not respected. The problems for line are often similar. As I recently turned from just being a reader to publishing my own short stories, I have set out to look what I can do to somewhat help improve the situation at least for my own products. In this blog post I'll try to describe the steps I took in creating a special edition of Orussian Quarantine aimed at the part of the cognitively impaired that benefit from special fonts, increased line spacing and/or larger font sizes. hopefully other authors will read this blog post and think to themselves; hey, these people need all the help and encouragement they can get in making reading fiction a fun experience.
The first thing I did was simply publish my short story on smashwords and download the epub file that smashwords generated.
Now an epub is nothing but a zip file. Note that unzipping won't put things needly into a single directory, so first create a directory yourself before you use unzip to unzip the epub file.
After unzipping the epub, we should add our custom font to the directory. Create a sub directory named 'fonts' and put the otf files of your preferred font into that directory.
Now we need to add the font files to something called the manifest. The manifest is a section of the XML file "content.opf". Open the file in your editor, you should see a section that starts with <manifest> that holds a set of 'item' XML tags. You will need to create an item tag for each of the otf files you just added. These should look something like this:
<item href="fonts/OpenDyslexic-Regular.otf" id="odfont" media-type="application/x-font-opentype"/>
Stay in the "content.opf" file for a moment, it has also got a tag that defines the id "uuid_id", given that universally unique identifiers are supposed to be universally unique, make a few changes to the content of this tag to make it unique. Keep to the format as originally used but change the content so you are sure it will also be unique by itself. Now copy the id and safe the file.
Now open the table of content file "toc.ncx" and look for the tag named "dtb:uid". Replace the content with the universally unique identifier you just created and safe the file.
So now we've added the new font and we have given the future epub its own unique identifier. We haven't yet changed anything about its appearance though. To do that we need to look at the file "stylesheet.css". Open this file, we are going to do quite some editing.
First thing we need to do in our stylesheet is allow it to find our font. We do this by creating a number of @font-face entries. Here is an example:
@font-face {
font-family: 'OpenDyslexic';
src:url(fonts/OpenDyslexic-Regular.otf);
}
@font-face {
font-family: "OpenDyslexic";
src: url("fonts/OpenDyslexic-Bold.otf");
font-weight: bold;
}
@font-face {
font-family: "OpenDyslexic";
src: url("fonts/OpenDyslexic-Italic.otf");
font-style: italic, oblique;
}
@font-face {
font-family: "OpenDyslexic";
src: url("fonts/OpenDyslexic-BoldItalic.otf");
font-weight: bold;
font-style: italic, oblique;
}
So now we are ready to make the ebook use our custom font. There are a number of rules in our stylesheet that we all need to look at. Remove any 'font-family' line in any of the rules and add a new line to each rule that names your font family above;
font-family: "OpenDyslexic";
So now we have taken care about the font, lets look at the line spacing. For every rule with a "line-height" definition, add 30% to the definition. For every rule that doesn't yet have an explicit "line-height" definition, add one that states 130%.
So now for the last change, font size. For every rule with a "font-size" definition, add 0.5 to the definition. For every rule that doesn't yet have an explicit "line-height" definition, add one that states 1.5 .
One final step you may wish to take is update the copyright notice (for example stating the book is free but only for people with a cognitive disability who benefit from the changes you just made.
You may also want to update the cover image to contain information on it being a special edition.
So now basically we are done with the content. Time to go build our new epub.
This is a two step process. First you should create a zip file from just the mimetype file using a flag to state the content should NOT be compressed. After that, you can add the rest of the directory to the zip file (this part should compress), and rename the zip file to have an appropriate name and epub extension.
So now you are ready, go and test your epub on your epub reader or reading app, and if things check out, go back to smashwords and publish the epub as special edition.
I truly hope this post encourages other authors to try and do something similar. If you know of any ways to improve this process or the resulting epub, please let me know.
The first thing I did was simply publish my short story on smashwords and download the epub file that smashwords generated.
Now an epub is nothing but a zip file. Note that unzipping won't put things needly into a single directory, so first create a directory yourself before you use unzip to unzip the epub file.
After unzipping the epub, we should add our custom font to the directory. Create a sub directory named 'fonts' and put the otf files of your preferred font into that directory.
Now we need to add the font files to something called the manifest. The manifest is a section of the XML file "content.opf". Open the file in your editor, you should see a section that starts with <manifest> that holds a set of 'item' XML tags. You will need to create an item tag for each of the otf files you just added. These should look something like this:
<item href="fonts/OpenDyslexic-Regular.otf" id="odfont" media-type="application/x-font-opentype"/>
Stay in the "content.opf" file for a moment, it has also got a tag that defines the id "uuid_id", given that universally unique identifiers are supposed to be universally unique, make a few changes to the content of this tag to make it unique. Keep to the format as originally used but change the content so you are sure it will also be unique by itself. Now copy the id and safe the file.
Now open the table of content file "toc.ncx" and look for the tag named "dtb:uid". Replace the content with the universally unique identifier you just created and safe the file.
So now we've added the new font and we have given the future epub its own unique identifier. We haven't yet changed anything about its appearance though. To do that we need to look at the file "stylesheet.css". Open this file, we are going to do quite some editing.
First thing we need to do in our stylesheet is allow it to find our font. We do this by creating a number of @font-face entries. Here is an example:
@font-face {
font-family: 'OpenDyslexic';
src:url(fonts/OpenDyslexic-Regular.otf);
}
@font-face {
font-family: "OpenDyslexic";
src: url("fonts/OpenDyslexic-Bold.otf");
font-weight: bold;
}
@font-face {
font-family: "OpenDyslexic";
src: url("fonts/OpenDyslexic-Italic.otf");
font-style: italic, oblique;
}
@font-face {
font-family: "OpenDyslexic";
src: url("fonts/OpenDyslexic-BoldItalic.otf");
font-weight: bold;
font-style: italic, oblique;
}
So now we are ready to make the ebook use our custom font. There are a number of rules in our stylesheet that we all need to look at. Remove any 'font-family' line in any of the rules and add a new line to each rule that names your font family above;
font-family: "OpenDyslexic";
So now we have taken care about the font, lets look at the line spacing. For every rule with a "line-height" definition, add 30% to the definition. For every rule that doesn't yet have an explicit "line-height" definition, add one that states 130%.
So now for the last change, font size. For every rule with a "font-size" definition, add 0.5 to the definition. For every rule that doesn't yet have an explicit "line-height" definition, add one that states 1.5 .
One final step you may wish to take is update the copyright notice (for example stating the book is free but only for people with a cognitive disability who benefit from the changes you just made.
You may also want to update the cover image to contain information on it being a special edition.
So now basically we are done with the content. Time to go build our new epub.
This is a two step process. First you should create a zip file from just the mimetype file using a flag to state the content should NOT be compressed. After that, you can add the rest of the directory to the zip file (this part should compress), and rename the zip file to have an appropriate name and epub extension.
So now you are ready, go and test your epub on your epub reader or reading app, and if things check out, go back to smashwords and publish the epub as special edition.
I truly hope this post encourages other authors to try and do something similar. If you know of any ways to improve this process or the resulting epub, please let me know.
Published on March 20, 2015 01:10
•
Tags:
dyslexia
No comments have been added yet.


