Dear Hussein,

>> Otherwise I will end up with thousands of attributes with predictable 
>> values
>> in my document, which will needlessly make it a lot bigger.
>
> This is hard to understand for us, who are not professional 
> lexicographers.
>

Perhaps I didn't make myself clear. Since language selection in XXE is 
*attribute-based* (and not *element-based*), the only way to implement 
spell-checking in my documents was to add language attributes. However, 
since the relationship between elements and language in an XML-encoded 
dictionary is normally one-to-one (e.g. headwords are always in, say, 
French, and translations in English), I wanted to avoid the necessity of 
specifying language attributes for all elements by defining default values 
in the DTD, so that instead of writing:

<Entry>
  <Headword lang="fr">chien</Headword>
  <Translation lang="en">dog</Translation>
</Entry>
<Entry>
  <Headword lang="fr">chienne</Headword>
  <Translation lang="en">dog</Translation>
  <Translation lang="en">bitch</Translation>
</Entry>

I could simply write:

<Entry>
  <Headword>chien</Headword>
  <Translation>dog</Translation>
</Entry>
<Entry>
  <Headword>chienne</Headword>
  <Translation>dog</Translation>
  <Translation>bitch</Translation>
</Entry>

and still be able to spell-check such a document.

***

> In the case of CSS, this is supported because DITA specialization
> depends on it. See
> http://www.xmlmind.com/xmleditor/_distrib/doc/csssupport/use-default-attribute-values.html
>

That looks interesting. I overlooked this functionality when reading the 
documentation. Thank you!

Does it work in CSS selectors only or is it possible to retrieve the value 
of a default attribute in a CSS stylesheet using the attr() function as 
well?

***

Thanks for your great product and even better support!

Best wishes,

Mariusz 


Reply via email to