21 Replies Latest reply: May 11, 2011 5:44 PM by SteveC100 RSS

    CSS for Book Document in 5.5

    SteveC100

      I believe I've just found another glaring problem with the epub implementation in CS5.5.

       

      I have a 20 chapter book. Created with very consistent styles for everything and using a book file to keep all styles synchronized.

       

      But when I create the epub -- I get a new set of styles for every chapter. One CSS style sheet doc. But 20 copies of every style. Body-Text, Body-Text-1, Body-Text-2, etc.

       

      Just to be sure I wasn't causing this, I just resynched all paragraph styles. No change.

       

      This takes away a whole lot of the value of styles. Now if I want to edit the CSS I have to edit every entry 20 times. This is nuts.

       

      Is there a place where I should be complaining about this? (The other glaring error I'd love to talk about is the way images are handled. Adobe insists on creating height/width descriptors based on a 72 dpi screen (which doesn't exist anymore) rather than the pixel dimensions of the image -- which is what all ereaders expect. Absolute dimensions ought to be an option, at least.)

       

      I was very optimistic about this version of ID. But the deeper I get into it the more disappointed I am.

       

      Thanks to anybody who can help --

      Steve

        • 1. Re: CSS for Book Document in 5.5
          marcusstringer Community Member

          SteveC100 wrote:

           

          I believe I've just found another glaring problem with the epub implementation in CS5.5.

           

          I have a 20 chapter book. Created with very consistent styles for everything and using a book file to keep all styles synchronized.

           

          But when I create the epub -- I get a new set of styles for every chapter. One CSS style sheet doc. But 20 copies of every style. Body-Text, Body-Text-1, Body-Text-2, etc.

           

          Yes I had that as well. But unfortunatly I haven't found the time to go into more with testing. If that IS a bug, its a massive problem

           

          These and other reasons are why I still make epubs using CS3. (200 epubs and counting )

          • 2. Re: CSS for Book Document in 5.5
            BobLevine UGM-MVPs

            The place to report bugs is here: https://www.adobe.com/cfusion/mmform/index.cfm?name=wishform

             

            That said, what happens if you just assign an already existing CSS file?

             

            Bob

            • 3. Re: CSS for Book Document in 5.5
              SteveC100 Community Member

              Marcus -- the fact that you are seeing this, as well, makes me think it's not something I've done. I think it's a pretty serious problem.

               

              What you get in the CSS is a new style for every style in every chapter. I use a particular style in only one chapter. The style definition appears in all, but the style itself is only used once. And, sure enough, that style appears only once in the CSS. (I need to double check this, but I believe I am correct).

               

              Bob -- I can't use another style sheet with singular definitions because all the chapter files USE the separate styles. Chapter 1 uses "Body-Text", Chapter 2 uses "Body-Text-1" etc. If I use a style sheet without Body-Text-1 then no style will be applied.

               

              I'll report the bug. I wonder if it's really a bug, or more of a "we couldn't deal with it and will get to it when we can" kind of thing. It's working too consistently.

               

              Steve

              • 4. Re: CSS for Book Document in 5.5
                BobLevine UGM-MVPs

                Why don't you just map the p tag to those styles and then create a CSS rule for the p tag?

                 

                Bob

                • 5. Re: CSS for Book Document in 5.5
                  SteveC100 Community Member

                  Well, I just reported two bugs. Sure feels like I am sending my thoughts into the deep dark ether. The support folks I have spoke to in India are thoroughly clueless. hope the bug fix people are more savvy.

                   

                  And the kicker -- you can't create a bug description longer than 2000 words. Pretty silly.

                   

                  S

                  • 6. Re: CSS for Book Document in 5.5
                    SteveC100 Community Member

                    >Why don't you just map the p tag to those styles and then create a CSS rule for the p tag?

                     

                    Bob,

                    Sorry to be dense, but I don't know how to do this. Can you explain?

                     

                    S

                    • 7. Re: CSS for Book Document in 5.5
                      BobLevine UGM-MVPs

                       

                      New to CS5.5 is the ability to map any paragraph style to any HTML tag.

                       

                      Capture.PNG

                      Once you've done that it's a simple matter of defining the tag in the CSS.

                       

                      Bob

                      • 8. Re: CSS for Book Document in 5.5
                        SteveC100 Community Member

                        I could try it, and I probably will, but I don't see how this is really much of an advantage -- I still have to edit every style 20 times, just to rename them all.

                         

                        After that, I guess it would be easier to make changes.

                         

                        It would be slicker if I could actually change the style parameters. But ID insists on creating them for you.

                         

                        Steve

                        • 9. Re: CSS for Book Document in 5.5
                          BobLevine UGM-MVPs

                          You won't get any of that if you don't specify classes when you export. It's way cleaner that way but you have to be able to write your own CSS.

                           

                          Bob

                          • 10. Re: CSS for Book Document in 5.5
                            SteveC100 Community Member

                            I will try it. I realize that I don't have to make the change in each chapter. Just once in the style source, and then sync the paragraph styles.

                             

                            Do you think that Adobe actually designed the thing so that the only way to coordinate styles across a book is to insist that all styles are consistently named by doing it yourself in the style definition? Boy, would that be dense.

                             

                            But here's the problem. In 5.5 when I sync paragraph styles, I'm getting problems with overset text. As I go through the problem areas, I see that text is being set very slightly wider than it was before the synch. And this means that occassionally line breaks change. For the life of me, I can't see the difference or why this is happening. Kerning is the same, tracking is the same, the whole style definition, as far as I can tell, has not changed. But the text doesn't fit on the line, a line is added, and the file changes. I've already published the book in print and all the page layout is done and I don't want to muck with it if I don't have to. I would prefer to have one version that works for print and epub, so when lines break, I have to go back and fix them by changing the tracking. Not fun. And it makes me wonder what the heck is happening or might be happening with other style definitions.

                             

                            Can you think of a reason that text that fit before wouldn't fit -- would get wider -- after a synch? Size, line height and tracking have not changed.

                             

                            Steve

                            • 11. Re: CSS for Book Document in 5.5
                              BobLevine UGM-MVPs

                              You could be losing some manual overrides, but other than that, I don't know.

                               

                              Bob

                              • 12. Re: CSS for Book Document in 5.5
                                SteveC100 Community Member

                                Okay, after some testing:

                                 

                                Your idea of renaming the exported styles works. And apparently you must do this for every style. ID will not put it all together into a single style unless you do so. That is nuts.

                                 

                                Second, I'm attaching an image that shows what's happening when I sync the paragraph styles. Changes in the way lines break occur in paragraphs where a cross reference appears at the end of the paragraph. A line that fits fine will suddenly not fit and breaks in a way that doesn't really make sense. There is room on the line for the text, but ID won't allow it and creates a new line. To make the text fit after the sync you have to delete characters, sometimes as many as four. Three examples are in the attached image. Weird. (And per your suggestion -- there are no overrides.)

                                 

                                This seems like a bug because a) there's room on the line for the text, and b) if I first sync in the reverse direction, that is, making the problem document the sync source -- which means the styles are then identical -- if I then sync in the normal way, the line still changes.

                                 

                                My guess is something is happening with those cross references that is a side-effect of syncing. But remaking the cross reference does not solve the problem.

                                 

                                Steve       

                                synch-problems.jpg

                                • 13. Re: CSS for Book Document in 5.5
                                  marcusstringer Community Member

                                  Gaaaaa...

                                   

                                  If this really is the case, (because I havn't tested it yet) There is no way in hell I want to go and map style names to tag name, (does Adobe not understand how many that could be) That's insane the amount of time I'm going to spend on that task when it was working just fine thank you in every other edition...

                                   

                                  I'm off to test and retest...if this really is the case, does Adobe offer refunds, as this is a deal breaker...

                                  • 14. Re: CSS for Book Document in 5.5
                                    BobLevine UGM-MVPs

                                    30 day money back policy, but if you simply open the Paragraph Styles menu you'll find a command called Edit All Export Tags. Shouldn't take you but a couple of minutes to do every style.

                                     

                                    Bob

                                    • 15. Re: CSS for Book Document in 5.5
                                      SteveC100 Community Member

                                      Thanks, Bob. That's helpful. And it will save a few keystrokes. And I will end up editing the export tags for every single chapter, rather than sync the book.

                                       

                                      But the point is that you can't sync your book files if they have cross references in them without having to check the whole bloody book for lines that have broken differently or wrong because of some weird bug.

                                       

                                      I'm going to start a new thread about this. It's not really about epubs or CSS, it's about syncing in general.

                                       

                                      Steve

                                      • 16. Re: CSS for Book Document in 5.5
                                        Willi Adelberger MVP

                                        You can do them all together without opening the styles definition at all:

                                        1. Go to the paragraph style panel or to the character style panel
                                        2. In the panel menu > Edit akk Export Tags…

                                        Here you find a list of all Paragraph styles and you can edit all export tags in only one step. This done in one document lets synchronize the whole book.

                                        • 17. Re: CSS for Book Document in 5.5
                                          SteveC100 Community Member

                                          Well, I've done created custom tags -- and there are still problems.

                                           

                                          I  went through all chapters and added "export tags" using the "Edit All  Export Tags" flyout menu in Paragraph Styles. A brief test convinced me that I cannot do this once as  Willi suggested. You have to do it for every chapter. Or sync the  chapters, but, as mentioned, syncing runs me right into the  'reformat-the-cross-references bug' which I'd rather avoid at this  point.

                                           

                                          Before the styles were edited I had 20 copies of every style, one for every chapter where that style is used.

                                           

                                          Body-Text

                                          Body-Text-1

                                          Body-Text-2

                                          etc.

                                           

                                          Now  I have only one copy of each renamed style, but instead I have dozens  and dozens of new styles that are named only with a number. Paragraph and span tags, some completely empty.

                                           

                                          For example:

                                          span.italic {
                                               font-weight : normal;
                                               font-style : italic;
                                          }
                                          span.-2 {
                                          }
                                          span.-3 {
                                          }
                                          span.-4 {
                                               font-weight : normal;
                                               font-style : italic;

                                          And:

                                          }
                                          p.-2 {
                                               font-family : "Gill Sans", sans-serif;
                                               font-weight : bold;
                                               font-style : normal;
                                               font-size : 2.83em;
                                               text-decoration : none;
                                               font-variant : normal;
                                               line-height : 1.2;
                                               text-align : right;
                                               color : #000000;
                                               text-indent : 0px;
                                               margin : 0px 0px 191px 0px;
                                          }
                                          p.-3 {
                                               font-family : "Futura Bold", sans-serif;
                                               font-weight : bold;
                                               font-style : normal;
                                               font-size : 1.08em;
                                               text-decoration : none;
                                               font-variant : normal;
                                               line-height : 1.2;
                                               text-align : left;
                                               color : #0019e6;
                                               text-indent : 0px;
                                               margin : 4px 0px 9px 0px;
                                          }


                                          Before I renamed everything, the HTML looked like this:

                                           

                                                      <p class="Body-Text-7">The Project window is divid
                                                       <p class="Images-1--indent-1--6"><span><img class=
                                                       <p id="toc_marker-3-2" class="Subhead-7">Projects<
                                                       <p class="Body-Text-7">Your materials will normall
                                                       <p class="Images-1--indent-1--6"><span><img class=
                                                       <p class="Body-Text-7">To switch projects, close t
                                                       <p id="toc_marker-3-3" class="Subhead-7">Modes and
                                                       <p class="Body-Text-7">The user interface is struc
                                                       <p class="Body-Text-7">In Version 4, these modes a
                                                       <p class="Images-2--indent--75--5"><a id="Mode-But
                                                       <p class="Body-Text-7">The Smart Tool will be cove

                                           

                                          Now that same section looks like this:

                                           

                                                      <p class="-77">The Project window is divi
                                                       <p class="-79"><span><img class="image" w
                                                       <p id="toc_marker-3-2" class="-76">Projec
                                                       <p class="-77">Your materials will normal
                                                       <p class="-79"><span><img class="image" w
                                                       <p class="-77">To switch projects, close
                                                       <p id="toc_marker-3-3" class="-76">Modes
                                                       <p class="-77">The user interface is stru
                                                       <p class="-77">In Version 4, these modes
                                                       <p class="-80"><a id="Mode-Buttons"/><spa
                                                       <p class="-77">The Smart Tool will be cov

                                           

                                          What could be going on here? Am I doing something wrong? I think I was better off before adding the tags.

                                           

                                          Steve

                                          • 18. Re: CSS for Book Document in 5.5
                                            BobLevine UGM-MVPs

                                            I will ask what I asked before (since I don't remember the answer). Have these documents been edited in CS5 or CS5.5 before synching? If not, I'm not so sure this a bug as it is the text reflowing because of the difference in text engines.

                                             

                                            Bob

                                            • 19. Re: CSS for Book Document in 5.5
                                              SteveC100 Community Member

                                              Bob,

                                              (I see your last comment in my email, but it doesn't show up in the forum itself (this has been happening for days) -- it takes a good hour or more to show up online. So I'm answering "blind" as it were.)

                                               

                                              In any event, yes, all these docs were created and edited in CS4. Now they are being opened in CS5.5. Recomposing does not cause the lines to break. Only syncing does.

                                               

                                              That is, if I edit the text in 5.5 and then save, I see the warning that everything is being recomposed. But the lines don't move.

                                               

                                              Moreover, if I simply type the text of the cross reference, there is no problem and it fits on the line just fine.

                                               

                                              Steve

                                              • 20. Re: CSS for Book Document in 5.5
                                                BobLevine UGM-MVPs

                                                Very strange behavior. I wish I had an explanation for you.

                                                 

                                                Bob

                                                • 21. Re: CSS for Book Document in 5.5
                                                  SteveC100 Community Member

                                                  For what it's worth, syncing the file makes no difference. ID just does not want to unify those styles, no matter what you do.

                                                   

                                                  And what's worse, somewhere along the line all the cross-references stopped working in the epub. They work in ID okay, and ID could export them just fine last week, but not now.

                                                   

                                                  I reached the end of my rope earlier today and just started editing the HTML and CSS. I really did not want to do that, but it seemed like there was no choice. Neck deep in GREP.

                                                   

                                                  Now if I could just figure out what happened to all those cross references, I'd be a lot happier. One thing I notice is that x-refs that you create in CS5.5 look different than those created in 4. They don't display the rectangle, but just a very light, almost indistinguishable blue bounding box around the page number.

                                                   

                                                  I have reported the bug with the non-unified styles and have already had a preliminary email from somebody at Adobe. Apparently they think the styles should combine without renaming them.

                                                   

                                                  Cross References between chapter files are no end of trouble. And 5.5 is worse.

                                                   

                                                  Thanks for all the help!

                                                  Steve