28 Replies Latest reply on Mar 11, 2015 9:37 AM by MW Design

    Why is my IDML file adding random hexagonal shapes to my artwork files?

    katharinej91298857

      When I generate an IDML file from an Indesign file it seems to add a small hexagonal shape to the artwork file.

      How do I stop this from happening because sometimes our printers need to work off the IDML files if they don't have the latest CC version.

        • 1. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
          MW Design Level 4

          Never had that problem.

           

          Is this with every file you generate an IDML with or a particular file? And is this you opening the IDML and discovering these spurious items or are they being reported to you by the printer?

           

          As regards the printer having the latest CC version, if they have CC at all they can install the newest version. If they don't have CC, have you tried opening the IDML in the same version they are using to check it out before sending it off?

           

          Are there any layers/objects that are not visible in the ID file? Other than that or document corruption, that's about all I can think of.

           

          Mike

          • 2. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
            katharinej91298857 Level 1

            Hi,

            It has happened on a few different files now.

            It has thankfully been picked up by our printers.

            When I go to check the original Indesign file it's not there at all - there are no hidden shapes on any hidden layers and no trace of the small hexagon shape at all.


            I only seem to find it upon opening the IDML file so it must be something to do with saving it out to IDML format?

            Is it normal for things to shift or items to move/appear when doing this?



            • 3. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
              MW Design Level 4

              Hi Katharine,

               

              I've not noticed shifting elements. But about the only time I have done IDML for myself isn't for exchange, it's been for document corruption in templates. The times I have opened IDML files from people here so I or others could look at the file it hasn't been mentioned when I have sent the file back. Same goes with random objects appearing. Just not seen it.

               

              If you have an IDML this happens to, I would be happy to look at it. You would need to upload to dropbox or the like and PM me the link to download it.

               

              Mike

              • 4. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                Joel Cherney Adobe Community Professional & MVP

                I've tested IDML backsave for pretty much every version that has come out since CS5. I have found all kinds of bizarre hard-to-recreate problems. Such problems are rare, but they're more common in some jumps than in others. In other words, CS5.5 to CS5 has a rather small likelihood of error when compared to CC 2014 -> CS5.5.

                 

                Yes, I've noticed small shifts in object position. I've seen all kinds of distortions or odd behaviors on images that cross the spine. I've seen whole stories become corrupt.

                 

                I developed my IDML testing regime so that I could figure out if I could trust various subcontractors who had to backsave CC or CS6 files to older versions of the ME edition of the Creative Suite. I would always resave to deliver in the client's source version, because you can't trust IDML as a delivery format.

                 

                sometimes our printers need to work off the IDML files if they don't have the latest CC version.

                 

                This workflow is pretty dangerous. Are you exporting IDML for target versions that you yourself don't have installed? I'd rather eat glass than trust IDML with my project at the printer. I don't work directly with printers all that often, but when I do I always ask them their target version, and if we can't find a common target version, I don't work with them.

                 

                You should take Mike up on his offer to look at the files. If you can, I encourage you to post source INDD and generated IDML publicly, if you can. Also, if you can tell us the version that was used to open your IDML at the printer where the stray hexagons were generated, I can try to recreate the error over here. I have pretty much everything back to CS3 installed right now.

                • 5. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                  katharinej91298857 Level 1

                  Thanks! I think I've just sent you a link...

                  • 6. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                    katharinej91298857 Level 1

                    Thanks Joel!

                    I agree and would rather sort this out with the printers direct but unfortunately we now use printer brokers where I'm working so this isn't really practical.

                    I'll see if we can just send on the PDFs from now on though..

                    I'm using CC and can see the shapes generated myself once I open the IDML CC file even though I can't see them anywhere the original Indesign CC file.

                    • 7. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                      Willi Adelberger Most Valuable Participant

                      When you place images, how are you doing it? Linking or embedding? Place or copy/paste?

                      • 8. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                        Laubender Adobe Community Professional & MVP

                        @Mike – were you able to look into Katherine's files?

                        Did you find a cause for that behavior / bug ?

                         

                        Uwe

                        • 9. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                          SJRiegel Adobe Community Professional & MVP

                          If your printer will take press-ready PDF flies, all the IDML uncertainty could be avoided.

                          • 10. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                            MW Design Level 4

                            Hi everyone...I just awoke. Need coffee. Be back.

                            • 11. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                              MW Design Level 4

                              Ok.

                               

                              In the ID file, there is a single point of a path.

                              capture-002882.png

                               

                              When ID exports this file to IDML, ID closes the path--a single point actually cannot truly exist if I recall properly. So ID makes it into a polygon.

                              capture-002884.png

                               

                              Maybe ID should remove all improper elements when saving back to IDML... Anyway, ina  compare of the IDML's XML, it can easily be seen. This is a file compare of the two IDMLs, the original one Katharine gave me, and the IDML I generated from the ID file after deleting the spurious path.

                              capture-002885.png

                              On the left is the original IDML showing the path definition. It isn't present in the IDML I generated.

                               

                              Other than the general principle that everyone should be working in the same versions of ID, that IDML is really not a general file exchange file-type, one needs to go through the layers and identify these pen-path segments that are not intended to be there and delete them.

                               

                              Mike

                              • 12. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                Laubender Adobe Community Professional & MVP

                                @Mike – ah, very interesting. The single path point remembers its origins.

                                That's an assumption, of course. A single path point, that is a polygon.

                                Funny.

                                 

                                So the import mechanism of InDesign (open IDML) will regard this object as a default polygon object, I guess.

                                Its size should be around 3.922 x 3.881 mm, if the defaults of InDesign are not changed.

                                 

                                How can these objects be detected and possibly removed?

                                We could look for page items with one single path point and remove them by script.

                                 

                                Would something problematic happen to the layout, if we will remove them?
                                Maybe yes, maybe not…

                                (Have to think about it)

                                 

                                Uwe

                                • 13. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                  Laubender Adobe Community Professional & MVP

                                  Ah. And the other question: How could that happen to my InDesign file?
                                  That's easy: Select a polygon (could also be an open path object with two diagonal positioned path points or more path points) with the direct selection tool using a "selection marquee", missing one path point and remove all path points but the one you did not select.

                                   

                                  Uwe

                                  • 14. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                    MW Design Level 4

                                    Yeah, looking at it it is the import that creates the polygonal shape from the single point. It is an invalid object and I suppose InDesign is being helpful.

                                    • 15. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                      Laubender Adobe Community Professional & MVP

                                      @Mike – I wouldn't say this single path point is an invalid object.

                                       

                                      I think, the import filter is doing something wrong with it.

                                      So it's more a bug than a feature.

                                       

                                      Tried to reproduce the issue with InDesign CS5.5. No luck.
                                      But I didn't try very hard…

                                      Without seeing the files, I cannot tell what exactly will cause this behavior.

                                       

                                      Uwe

                                      • 16. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                        Peter Spier Most Valuable Participant (Moderator)

                                        I've seen two cases where single path points with a color fill assigned completely screwed up PDFs (but not for several years, since before the days of the improved layers panel), and those points were not selectable except when choosing select all -- marquee wouldn't pick them up, even knowing where they were, so they were pretty hard to find. In all the testing I did I was never able to create such a point.

                                        • 17. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                          MW Design Level 4

                                          Katharine, can I send Uwe the link to the test file? Else can you provide a link for more eyes to look at it in a post here?

                                           

                                          Uwe, I cannot replicate the behavior with my own test files in CS5.5, CS6 nor CC2014 nor by using Katharine's file.

                                           

                                          Peter, thanks for the input. This object has no fill, it does have an outline color and a 1pt weight. It can be marquee selected in the ID file.

                                           

                                          These lines are the specific lines in Katharine's file that do not exist in any of my test files.

                                           

                                          2<!         <Properties>
                                          3<!            <PathGeometry>
                                          4<!               <GeometryPathType PathOpen="true">
                                          5<!                  <PathPointArray>
                                          6<!                     <PathPointType Anchor="311.04 -57.6" LeftDirection="311.04 -57.6" RightDirection="311.04 -57.6" />
                                          7<!                  </PathPointArray>
                                          8<!               </GeometryPathType>
                                          9<!            </PathGeometry>
                                          10<!         </Properties>
                                          • 18. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                            Joel Cherney Adobe Community Professional & MVP

                                            Dave Saunders wrote a script to find stray points in ID, once upon a time, but the only evidence I find in a hasty Google search is a link from Cari Jansen that points to ye olde webx forums. If I wasn't hip-deep in change orders I'd go dig it up; it has to be on one of my old external drives.

                                            • 19. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                              Laubender Adobe Community Professional & MVP

                                              @Peter – I just played around with rotated and flipped rectangles removing three of four path points with the Direct Selection tool.

                                               

                                              Surprising result:

                                              One single path point on the page you can select with the marquee. I can identify this one as the remnant of the rectangle.

                                              PLUS: One single path object on the pasteboard you cannot select with the marquee. However you can select it from the Layers panel. I have no idea how exactly I produced this.

                                               

                                              Exported to IDML, opened IDML in the same version of InDesign:

                                              The single path object was converted into a default polygon (three-sided, because this was my default at that time).

                                               

                                              Here a view before exporting to IDML:

                                              <Punkt> may translate to <Pathpoint> (or simply <Point> ?)

                                              <Pfad> means <Path>

                                              Before-OnePathPoint-OnePathObject.png

                                               

                                              Here after opening the IDML in the same version of inDesign:

                                              After-OnePathPoint-OnePolygon.png

                                               

                                              InDesign CS6 v8.1.0 on Mac OSX 10.7.5.

                                              The problem: I cannot reproduce the phenomenon right now :-(

                                               

                                              Uwe

                                              • 20. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                Laubender Adobe Community Professional & MVP

                                                Now, that I have a sample of that strange object on the pasteboard, I could do some tests with it. I selected the object in the Layers panel and ran a test for all properties and their values on it:

                                                 

                                                The object is of type Polygon tells my script. However, the Layers panel insists it's a Path object (different terminology for the same object).

                                                However its path.length, the value that indicates how many paths the object is composed of, says: 0

                                                 

                                                No paths, no path points, but an object of type polygon ??!

                                                 

                                                If we look at the dimensions of that irregularity, we can see some amazing things.

                                                The values for its geometric bounds, the overall rectangle you can span over every page item usually parallel to the edges of the page say something totally different from its visible bounds usually describing the outermost visible dimensions of an object (effects will not count, but stroke values do):

                                                 

                                                geometricBounds   148.499999999731 , 0 , 148.499999999731 , 0

                                                visible bounds        43.9203193976101 , -82.0096718203236 , 43.9203193976101 , -82.0096718203236

                                                 

                                                The geometric bounds will describe a point nearly exact in the middle of the left edge of the page.

                                                My page size is A4 which is a page height of 297 mm.

                                                297/2 = 148.5

                                                 

                                                However, the visible bounds will describe a single point on the pasteboard.

                                                 

                                                All values in millimeters of the coordinates of the spread in the form: y1 , x1 , y2 , x2

                                                 

                                                Here some screenshots:

                                                 

                                                Dimensions1.png

                                                Dimensions2.png

                                                 

                                                I'm a little perplexed !

                                                 

                                                Uwe

                                                • 21. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                  Peter Spier Most Valuable Participant (Moderator)

                                                  I have Dave's script in my script archive:

                                                   

                                                  //DESCRIPTION: Delete singular points in selected group(s) or whole document 
                                                  
                                                  (function() { 
                                                    if (app.documents.length > 0) { 
                                                      if (app.selection.length > 0) { 
                                                        for (var j = app.selection.length - 1; j >= 0; j--) { 
                                                          if (app.selection[j] instanceof Group) { 
                                                            removeSingularPoint(app.selection[j]); 
                                                          }  
                                                        }  
                                                      } else { 
                                                        removeSingularPoint(app.documents[0]); 
                                                      } 
                                                    } 
                                                    function removeSingularPoint(range) { 
                                                      var myPIs = range.allPageItems; 
                                                      for (var j = myPIs.length - 1; j >= 0; j--) { 
                                                        if (myPIs[j] instanceof Polygon) { 
                                                          var paths = myPIs[j].paths; 
                                                          for (var k = paths.length - 1; k >= 0; k--) { 
                                                            if (paths[k].pathPoints.length == 1) { 
                                                              paths[k].pathPoints[0].remove(); 
                                                            } 
                                                          } 
                                                        } 
                                                      } 
                                                    var zP = app.activeWindow.zoomPercentage 
                                                      app.activeWindow.zoom(ZoomOptions.showPasteboard); 
                                                      app.activeWindow.zoomPercentage = zP ; 
                                                   } 
                                                  
                                                  }()) 
                                                  
                                                  • 22. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                    Peter Spier Most Valuable Participant (Moderator)

                                                    For what it's worth, I don't really understand what's happening, but I suspect it is a bug.

                                                    • 23. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                      Laubender Adobe Community Professional & MVP

                                                      @Peter – thank you for digging out this old ExtendScript script.

                                                      It is still working with InDesign CS6 or above.

                                                       

                                                      For my personal case, the example I presented here, that script will not work or will only work on the not problematic single path point object. It will not catch and remove the strange object on the pasteboard that will transform to a regular polygon after export/open IDML, because this object has absolutely no path or path points!

                                                       

                                                      After looking more closely to the screenshots Michael was presenting here, I think for Katherine's case the script would have worked.

                                                       

                                                      So I think we have two different cases here with a similar result:

                                                      Superfluous polygons after opening an IDML with InDesign.

                                                       

                                                      Uwe

                                                      • 24. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                        MW Design Level 4

                                                        Nope. The script doesn't remove the problem point whether it is selected or not.

                                                         

                                                        It would really, really help to understand where this object came from, how it came into being. I cannot replicate the behavior of a point causing an issue when exported/IDML and back into the current or previous ID versions I have. The object is there in the file. But it never mutates into another thing.

                                                         

                                                        I don't know if it is related to some default object style or the like. But it is pretty plain to me I am overlooking how Uwe made his "break" and I cannot.

                                                         

                                                        Mike

                                                        • 25. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                          Laubender Adobe Community Professional & MVP

                                                          Sorry, Mike!
                                                          I really cannot tell you, how I made this thing.

                                                           

                                                          As I already said: I played around with rectangles, that were a.) rotated and b.) flipped. Then I removed some path points.

                                                          Maybe a.) plus b.) are two necessary ingredients for that strange result. Some others are obviously missing. So, I could imagine a specific combination of rotation angle with flipping plus speed of action doing all this?! Hm. A hypothesis of course…

                                                           

                                                          Uwe

                                                          • 26. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                            MW Design Level 4

                                                            Yeah...dunno. I originally tried creating frames and other objects and deleting points in an attempt to recreate the issue. I didn't try flipping, rotating etc., though. I'm out and about using a tablet and will play some more tonight.

                                                             

                                                            Mike

                                                            • 27. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                              Laubender Adobe Community Professional & MVP

                                                              @Mike – the following script (ExtendScript/JavaScript) should remove these strange objects (plus stray path points as well):

                                                               

                                                              //150311-1-GetRidOf_OneSinglePathPoints-StrangePolygons.jsx
                                                              //Uwe Laubender
                                                              
                                                              /**
                                                              * @@@BUILDINFO@@@ 150311-1-GetRidOf_OneSinglePathPoints-StrangePolygons.jsx !Version! Wed Mar 11 2015 12:05:10 GMT+0100
                                                              */
                                                              
                                                              //DESCRIPTION:Remove all: Single path point objects, all polygon objects with no paths at all in ACTIVE DOCUMENT
                                                              
                                                              /*
                                                              See discussion at:
                                                              
                                                              Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                              katharinej91298857 Mar 10, 2015 12:43 AM
                                                              https://forums.adobe.com/thread/1729366
                                                              
                                                              */
                                                              
                                                              app.scriptPreferences.userInteractionLevel = UserInteractionLevels.interactWithAll;
                                                              
                                                              app.doScript(
                                                                  removeStrangeObjects, 
                                                                  ScriptLanguage.JAVASCRIPT, 
                                                                  [], 
                                                                  UndoModes.ENTIRE_SCRIPT, 
                                                                  "Remove strange objects in active document"
                                                                  );
                                                              
                                                              
                                                              function removeStrangeObjects(){
                                                              
                                                              var myDoc = app.documents[0];
                                                              var myAllPageItems = myDoc.allPageItems;
                                                              var strangeObjectIDs = [];
                                                              
                                                              //1. Gather strange objects:
                                                              
                                                              for(var n=0;n<myAllPageItems.length;n++){
                                                                  
                                                                  var myPageItem = myAllPageItems[n].getElements()[0];
                                                                  
                                                                  //Case 1:
                                                                  //single objects are "stray" objects, not part of combined path objects
                                                                  
                                                                  //Some pageitems do not support the property paths. Let's skip them:
                                                                  try{
                                                                  if(myPageItem.paths.length === 1 && myPageItem.paths[0].pathPoints.length === 1){
                                                                      strangeObjectIDs[strangeObjectIDs.length++] = myPageItem.id;
                                                                      };
                                                                  }catch(e){continue};
                                                                  
                                                                  //Case 2:
                                                                  //object identifies itself as Polygon with no path at all !!
                                                                  //Some pageitems do not support the property paths. Let's skip them:
                                                                  try{
                                                                  if(myPageItem.paths.length === 0 && myPageItem.constructor.name === "Polygon"){
                                                                      strangeObjectIDs[strangeObjectIDs.length++] = myPageItem.id;
                                                                      };
                                                                  }catch(e){continue};
                                                                  
                                                                  };
                                                              
                                                              //2. Remove strange objects gathered:
                                                              
                                                              for(var n=0;n<strangeObjectIDs.length;n++){
                                                                  
                                                                  var myStrangeObject = myDoc.pageItems.itemByID(strangeObjectIDs[n]);
                                                                  
                                                                  //Case 1: Object itself is locked:
                                                                  if(myStrangeObject.locked === true){myStrangeObject.locked = false};
                                                                  
                                                                  //Case 2: item layer of object is locked:
                                                                  if(myStrangeObject.itemLayer.locked === true){
                                                                      myStrangeObject.itemLayer.locked = false;
                                                                      var myLayer = myStrangeObject.itemLayer;
                                                                      myStrangeObject.remove();
                                                                      myLayer.locked = true;
                                                                      };
                                                                  else{myStrangeObject.remove()};
                                                                  
                                                                  };
                                                              
                                                              alert(strangeObjectIDs.length+" "+"strange objects were removed."+"\r"+"Note: You can undo this in one go.");
                                                              
                                                              };
                                                              

                                                               

                                                              Uwe

                                                              • 28. Re: Why is my IDML file adding random hexagonal shapes to my artwork files?
                                                                MW Design Level 4

                                                                Uwe--Works a treat!

                                                                 

                                                                Katharine, copy the script into a text editor and save it with a .jsx extension into the scripts panel folder. I think this script will work fine for you.

                                                                 

                                                                Thanks, Uwe...

                                                                 

                                                                Mike