1

I cant figure a way to disable validation for SVG files in eclipse. I tried to add an exception for xml validation in the validation configuration page, but it did not work. I have a file from bootstrap 3 (glyphicons-halflings-regular.svg) that has an error marker ( dtd compliance probably ) I would like to either exclude this specific file from validation OR disable validation of SVG files all together.

Any help appreciated.

edit : I am using eclipse Luna

The error message in the SVG file says :

Description Resource Path Location Type The content of element type "font-face" is incomplete, it must match "((font-face-src,(desc|title|metadata))|((desc|title|metadata)+,font-face-src,((desc|title|metadata))?))". glyphicons-halflings-regular.svg /myApp/src/main/webapp/js/vendor/bootstrap-3 line 6 XML Problem

azpublic
  • 1,404
  • 4
  • 20
  • 42
  • What an error message says is usually not something you should *guess* *at* when asking a technical question. – nitind Sep 26 '14 at 05:36

1 Answers1

1

This is a problem related with the validator not with the bootstap SVG file, since the definition is right, if you check the definition of defs Element it allows an font element.

Also from mozilla sources:

Permitted content:

Any number of the following elements, in any order:

  • Animation elements
  • Descriptive elements
  • Shape elements
  • Structural elements
  • Gradient elements

and

<a>, <altglyphdef>, <clippath>, <color-profile>, <cursor>, <filter>, <font>, <font-face>, <foreignobject>, <image>, <marker>, <mask>, <pattern>, <script>, <style>, <switch>, <text>, <view>

Normative document SVG 1.1 (2nd Edition)

So you can add to ignore in eclipse validator, please check this topic: How to exclude specific folders or files from validation in Eclipse?

Community
  • 1
  • 1
Paulo Fidalgo
  • 21,709
  • 7
  • 99
  • 115
  • I did follow the suggestions in the answer you linked but it did not work for me. The svg file still gets validated for some obscure reason. I added svg file extension in the Exclude group for XML validator. But still no luck – azpublic Sep 26 '14 at 11:51
  • 1
    OK so it seems eclipse is in a better mood today ... even though I had completely rebuilt and re-validated my workspace yesterday, the marker would not disappear. Today however after restarting it, its' just plain gone .... Who knowns... Sometimes its just THAT day of the month for eclipse too. Accepting your answer :) – azpublic Sep 27 '14 at 06:01