I'm sorry but I still don't see where is the problem. What you want to
do is quite common.  We did that for our own documents (written first in
English and then translated to French) dozens of times.

--> If you want, once for all,  new documents containing a concept to
always have xml:lang="en-us", then customize the document templates as
explained in my previous email.

--> If you want to set/change the xml:lang attribute on an existing
concept element, then first select it (for example by clicking on
"concept" in the node path bar) and then use the Attributes tool to
set/change the xml:lang attribute.

XMLmind XML Editor tutorial: Setting attributes
http://www.xmlmind.com/xmleditor/_tutorial/set_attribute/index.html

Node path bar:
http://www.xmlmind.com/xmleditor/_distrib/doc/help/nodePathTool.html

Attributes tool:
http://www.xmlmind.com/xmleditor/_distrib/doc/help/editAttributePane.html



On 08/05/2015 08:56 PM, Tyrin Avery wrote:
> The current XML Mind concept template looks like:(note that there's no
> xml:lang attribute for the concept element)
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN"
> "concept.dtd">
> <concept id="???">
>    <title/>
> 
>    <conbody>
> ...
> 
> 
> We want it to look like: (note the xml:lang attribute for the concept
> element)
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN"
> "concept.dtd">
> <concept id="UsingURLRulesforSEO" xml:lang="en-us">
>    <title>Using URL Rules for SEO</title>
>    <conbody>
> ...
> 
> 
> 
> So that when it's returned from our translators, it looks like:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN"
> "concept.dtd">
> <concept id="UsingURLRulesforSEO" xml:lang="zh-CN">
>    <title>利用 URL 规则实现 SEO</title>
> 
>    <conbody>
> ...
> 
> 
> 
> On 8/5/15, 1:52 PM, "Hussein Shafie" <huss...@xmlmind.com> wrote:
> 
>> On 08/05/2015 04:13 PM, Tyrin Avery wrote:
>>> Hi
>>> We localize our doc and the translator software need us to use the
>>> xml:lang=en_us tag for our topics. I'm trying to find a way to get XML
>>> Mind to include that in the basic topic template. I tried to use the
>>> feature that allows you to customize template elements, but it doesn't
>>> work.
>>
>> Sorry but I'm not 100% sure to understand what you want to do.
>>
>>
>>
>> The idea is to customize all the stock topic, concept, reference, task,
>> etc, document templates (those used by "File|New").
>>
>> Please try to use "Options|Customize Configuration|Save Document As
>> Template" (and not "Options|Customize Configuration|Save Selected
>> Element As Template").
>>
>> See
>> http://www.xmlmind.com/xmleditor/_distrib/doc/help/customizeConfigurationM
>> enu.html
>>
>> You need to start by creating say a new Concept file by using
>> "File|New", add xml:lang="en-US" to its root element, add id="concept"
>> to its root element, save the file anywhere you want (the saved file is
>> anyway copied elsewhere) and then select "Options|Customize
>> Configuration|Save Document As Template".
>>
>> In this dialog box,
>>
>> http://www.xmlmind.com/xmleditor/_distrib/doc/help/com.xmlmind.xmleditapp.
>> app.part.SaveAsTemplateAction.Prompt.html
>>
>> specify the same info (name, category, order) as for the stock Concept
>> document. This will allow you to override the stock Concept document by
>> a similar one having xml:lang="en-US".
>>
>>
>>
>>
>> Alternatively, you may want to do the same thing by hand by customizing
>> the DITA Topic configuration.
>>
>> You need to replace the stock topic templates by similar templates
>> having xml:lang="en-US".
>>
>> How to do this is explained here:
>>
>> Customizing an existing configuration
>> http://www.xmlmind.com/xmleditor/_distrib/doc/configure/customizing.html
>>
>> and more precisely:
>>
>> Replacing an existing document template
>> http://www.xmlmind.com/xmleditor/_distrib/doc/configure/replace_template.h
>> tml
>>
>>
>>
>>
>>> I'm not sure if that's because it's the conbody element or because
>>> it's an attribute, but I think this may be a bug.
>>> If there is another way I can add the xml:lang attribute to my concepts
>>> and tasks templates automatically
>>
>> See above.
>>
>>
>>
>>> (and in a way I can roll out to my  group) please let me know.
>>
>> "in a way I can roll out to my  group" is a different problem.
> 
> This e-mail message and all attachments transmitted with it may contain 
> privileged and/or confidential information intended solely for the use of the 
> addressee(s). If the reader of this message is not the intended recipient, 
> you are hereby notified that any reading, dissemination, distribution, 
> copying, forwarding or other use of this message or its attachments is 
> strictly prohibited. If you have received this message in error, please 
> notify the sender immediately and delete this message, all attachments and 
> all copies and backups thereof.
> 
> --
> XMLmind XML Editor Support List
> xmleditor-support@xmlmind.com
> http://www.xmlmind.com/mailman/listinfo/xmleditor-support
> 


--
XMLmind XML Editor Support List
xmleditor-support@xmlmind.com
http://www.xmlmind.com/mailman/listinfo/xmleditor-support

Reply via email to