From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/44732 Path: news.gmane.org!not-for-mail From: "Wolfgang Schuster" Newsgroups: gmane.comp.tex.context Subject: Re: XML Date: Tue, 14 Oct 2008 09:24:57 +0200 Message-ID: <115224fb0810140024o1b1d1365ld7604568be1e4ddd@mail.gmail.com> References: <200810072214.52895.johannes_graumann@web.de> <115224fb0810090050x4b827f8ej9c75bcc724222a7b@mail.gmail.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1223969504 24624 80.91.229.12 (14 Oct 2008 07:31:44 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 14 Oct 2008 07:31:44 +0000 (UTC) To: "mailing list for ConTeXt users" Original-X-From: ntg-context-bounces@ntg.nl Tue Oct 14 09:32:36 2008 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1KpeOF-0005B4-Bb for gctc-ntg-context-518@m.gmane.org; Tue, 14 Oct 2008 09:32:23 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 4AA701FD59; Tue, 14 Oct 2008 09:31:06 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 12563-01-16; Tue, 14 Oct 2008 09:29:47 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 51E551FCC6; Tue, 14 Oct 2008 09:28:02 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 7BE061FCC6 for ; Tue, 14 Oct 2008 09:27:09 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 07999-06-18 for ; Tue, 14 Oct 2008 09:26:28 +0200 (CEST) Original-Received: from mu-out-0910.google.com (mu-out-0910.google.com [209.85.134.184]) by ronja.ntg.nl (Postfix) with ESMTP id ADF1D1FB72 for ; Tue, 14 Oct 2008 09:24:57 +0200 (CEST) Original-Received: by mu-out-0910.google.com with SMTP id w9so2015788mue.4 for ; Tue, 14 Oct 2008 00:24:57 -0700 (PDT) Original-Received: by 10.103.222.12 with SMTP id z12mr4227531muq.95.1223969097192; Tue, 14 Oct 2008 00:24:57 -0700 (PDT) Original-Received: by 10.103.215.10 with HTTP; Tue, 14 Oct 2008 00:24:57 -0700 (PDT) In-Reply-To: Content-Disposition: inline X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:44732 Archived-At: On Thu, Oct 9, 2008 at 8:13 PM, Johannes Graumann wrote: > Wolfgang Schuster googlemail.com> writes: > >> \xmlprocess{main}{zip:///\inputfilename.odt?name=content.xml}{} >> >> or >> >> \usezipfile[\inputfilename.odt] >> \xmlprocess{main}{*/content.xml}{} > > Thank you very much - very nice! > >> You could use this for the start but it behavious a little bit weird. >> >> \unprotect >> >> \def\switchfontstyle >> {\ifx\fontalternative\c!tf \it \else >> \ifx\fontalternative\c!bf \bi \else >> \it \fi\fi} >> >> \protect >> >> \xmlmapvalue {fo:font-style} {italic} {\switchfontstyle} > > Hmm ... if I understand this correctly this is aimed at dealing with nested > bold/italic attributes? > > While I'm certainly going to fall over this rather soon, I think the issue here > is that the following excerpt, where "T1" and "T2" correspond to bold and italic > definitions further up, is misinterpreted such that the opening "text:span" of > the "T1" section is taken for the beginning of the "T2" section instead and "T2" > is accordingly applied to the whole construct ... > > > Versuch > > Bold Versuch > > > Italic Versuch > > > > Where in Hans' snippet below might that be fixable? > > \startxmlsetups office > \xmlsetsetup{main}{text:p|text:span}{*} > \stopxmlsetups > xmlregistersetup{office} > > \startxmlsetups text:p > \xmlflush{#1}\par > \stopxmlsetups > > \startxmlsetups text:span > \bgroup > > \xmlfilter{main}{office:automatic-styles/style:style/style:text-properties > /command(do:style:text-properties)} > \xmlflush{#1} > \egroup > \stopxmlsetups \startxmlsetups text:span \bgroup \xmlfilter{main}{office:automatic-styles/style:style[@style:name='\xmlatt{#1}{style-name}']/style:text-properties/command(do:style:text-properties)} \xmlflush{#1} \egroup \stopxmlsetups Wolfgang ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________