|
|
This article is available in: English Castellano ChineseGB Deutsch Francais Italiano Nederlands Portugues Turkce |
by Egon Willighagen <egonw(at)linuxfocus.org> ��������: ���߻����Nijmegen��ѧ��ѧ˶ʿѧλ��������ͬһ����ѧ���з��ӱ�ʾ����IJ�ʿѧλ�о������ô������java��̡� Ŀ¼: |
ÕªÒª:
��ƪ���½����˹���Kate������XML����ڱà¼DocBook XML�ĵ������ʹ�á�
ʹ�ÿ���Դ��Ĺ��߽���XML�à¼Ò»Ö±ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½Ò»ï¿½ï¿½ï¿½ï¿½ï¿½â¡£ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ÒªÒ»ï¿½ï¿½ï¿½à¼ï¿½ï¿½ï¿½ï¿½Ð§ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½XML�ĵ�������ֱ�۵Ŀ��������һЩ�à¼ï¿½ï¿½ï¿½Ñ¾ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½Ð©ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½Ë½ï¿½Ð°ï¿½È¨ï¿½Ä¡ï¿½ï¿½Ú¿ï¿½ï¿½ï¿½Ô´ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï£¬ï¿½ï¿½ï¿½ï¿½Ã´ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ß£ï¿½ï¿½ï¿½ï¿½Ç²ï¿½ï¿½á¹©Æ¯ï¿½ï¿½ï¿½ï¿½Í¼ï¿½ï¿½Ô¤ï¿½ï¿½ï¿½ï¿½È´ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½Ð§ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½XML�ĵ������������㽨�飬���ĵ�������λ������ЩԪ��(elements)�ǿɹ�ʹ�õġ�
����DocBook����ģʽ��Emacs�������е�һ�����ܹ���(�ο���ǰ��DocBook ����). ���������ģʽ�ܸ����ĵ������е�Ԫ���ṩ�������õ���Ԫ�ع���ѡ��ͬʱҲ�������֪ʶ�ṩtab���Զ���ɹ��ܣ���������linux����̨ģʽ����������ʱһ��������ע����
�������IJ�������Emacs��������һ��DocBook XML�à¼ï¿½ï¿½Kate��
./configure --prefix=/path/where/your/kde3/is/installed make sudo make install
�������װ�ú���Ҫ֪ͨKate�������ǣ�ѡ��"Settings"�˵���"Configure Kate"���"Plugins"�������а�XML���������װ�ز���б��У�
Meta DTD ��Norman Walsh ��dtdparser����, ���Դ�SourceForge.net����.
��ʹ�õ���һ�������޸��˵�2.0 beta6�汾�� ���磺�Ұ�dtdparse�����һ���е�·�������޸ģ�����ȷ�ı����ҵ�perl��װ·������������dtdparse����������£�
> ./dtdparse /path/to/docbookx.dtd Public ID: unknown System ID: /usr/share/sgml/docbook/dtd/xml/4.1.2/docbookx.dtd SGML declaration: unknown, using defaults for xml and namecase Loading dbnotnx.mod Loading dbcentx.mod Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsa.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsb.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsc.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsn.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamso.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsr.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISObox.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOcyr1.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOcyr2.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOdia.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOgrk1.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOgrk2.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOgrk3.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOgrk4.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOlat1.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOlat2.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOnum.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOpub.ent Loading /usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOtech.ent Loading dbpoolx.mod Loading calstblx.dtd Loading dbhierx.mod Loading dbgenent.mod Parse complete. Writing docbookx.dtd.xml... Done.
ע�⣬�д�����ʵ��(entity)�˿̱����롣������ز��ֵĵ��������ɵ�ԪDTD��1.63M �󡣲���ʹ����xsltproc������XSLT������������kde���Ӱ�(kde-addon)��simplify_dtd.xsl��ʽ�������԰����Ĵ�С��С��0.96M��
> xsltproc simplify_dtd.xsl docbookx.dtd.xml > docbook-xml-4.1.2.dtd.xml
Ȼ��Ϳ��԰����ɵ�docbook-xml-4.1.2.dtd.xml������/path/to/kde3/share/apps/katexmltools/,ע�⽫/path/to�ij�KDE3��ʵ�ʰ�װ·�����������������homeĿ¼Ҳ���ԣ���Ϊ��������һ���µ�ԪDTD��ʱ��XML�����ѯ�ʾ�����ļ����������ģ���
����ʼ�à¼Ò»ï¿½ï¿½ï¿½Âµï¿½DocBook XML�ĵ���ʱ����Ҫָ��һ��ԪDTD�������ǣ�ѡ��"XML Plugin"�˵��е�"Assign Meta DTD"���ʱ��ᵯ��һ���ļ�ѡ��Ի��������ѡ������ʹ�õ�DTD���������ѡ�����DocBook XML 4.1.2 Meta DTD���µĶԻ���ͻ���ʾ������ʼ������
���µĿհ��ĵ��У���������"<book>"��Ҫʹ���Ԫ���Զ����(close the element),��F11���ɡ�����﷨������(syntax highlighting)��ɫ��û�д򿪣��������"Document"�˵���ѡ��"Highlight Mode"��ֶ���ɡ�XML �﷨��������"Markup"�Ӳ˵��С�
�������������Ԫ��book����Щ���ԣ����ǿ��԰ѹ���Ƶ���ʼ��ǩ(tag)�е�wordһ�ʵĽ�β����Ctrl+Return����һ���������ھͻ���ʾ��ǰԪ�صĿ��������б���
�����ŵ�����֮��(����ע:����������xx��,���Զ�����xx=""�����Ը�ʽ,����ֵ������֮������)����Ctrl+Return��������ʾ�㶨����DTD�еĿɹ�ʹ�õ�����ֵ����������idû�����ֹ��ܡ�
��������֮��,���ǵõ�����DocBook XML����:
<book id="SomeID"> </book>
���ù�굽Ԫ��book�Ŀ�ʼ��ǩ�ͽ�����ǩ֮��,��Ctrl+Return,���ǵõ�һ���µĵ����б�, ��ʱ��ʾ����book�����п��ܵ���Ԫ��.����ѡ��Ԫ��title��Ϊ����:
��������һ�������ǣ�����֪����������Ԫ�أ�����֪����Ԫ���������ֵ�˳�����������磺 DTD������titleԪ�س������λ��������ϣ�����XML���������������һ�㡣���ڲ��Ҳû����Ч����֤ ѡ�����Ŀǰ��û�У������Ժ����������д����ĵ���
�������Ĺ���ժҪ���±���
���� | ���� |
����XML(Ԫ�� �� ����) | Ctrl+Return |
����ʵ�� | F10 |
��ձ�ǩ(Close Tag) | F11 |
KDE��Ŀ����Ҳʹ��DocBook��Ϊ���ǵ�һ���ĵ���ʽ��������XML���Ĭ�ϴ���KDE���ƹ���DocBookԪDTD�汾�������Ҫ��дKDE�ĵ��Ļ�����ѡ��Ȼ����ʹ�����ԪDTD��������DocBook XML 4.1.2��ԪDTD��
���DocBookҲ֧��MathML���Ա����ĵ��м�����ѧ��ʽ�� һ����Ϻ�֧��MathMl�����DocBook DTD������ ����ʼ���Ϣ���ҵ�.
SVG������ע���μ���������DTD���һ�û��д��һ�ֿ��԰�����DocBook�ķ�ʽ��������������Ŭ��ʹ֮��Ϊ���ܡ�
ʹ��Kate��XML���Ҫ����dtdparse����ϵ�DTD�Ļ���������һ���µ�ԪDTD��ͨ�����ַ�ʽΪ���ṩ����Ĺ���֧�֣����磺MathML������ע����
Kate��XML�����������à¼DocBook XML�ĵ�ʱ��ܴ�İ������á����������������Ͼ�����������ſ��������ġ�����KDE3.0�ij��֣��������˽����л���ʹ������
|
��ҳ��LinuxFocus�à¼ï¿½ï¿½Î¬ï¿½ï¿½
© Egon Willighagen, FDL LinuxFocus.org ���������LinuxFocus�������������� |
������Ϣ:
|
2002-05-28, generated by lfparser version 2.27