Loading ...
Sorry, an error occurred while loading the content.
 

Re: [XSL-FO] Background-image challenge

Expand Messages
  • W. Eliot Kimber
    ... You can set the background color on fo:inline or fo:block, which will set the background color for the text. This is
    Message 1 of 11 , Dec 2, 2004
      C. Myers wrote:

      >
      > Hi,
      >
      > I have been challenged by the following, I need to publish blocks of
      > text that required the left part of the text in yellow background
      > color, and the right part of the text is in gray background color.
      >

      You can set the background color on fo:inline or fo:block, which will
      set the background color for the text.

      <fo:block background-color="yellow">This is yellow</fo:block>

      Cheers,

      Eliot
      --
      W. Eliot Kimber
      Professional Services
      Innodata Isogen
      9390 Research Blvd, #410
      Austin, TX 78759
      (512) 372-8122

      eliot@...
      www.innodata-isogen.com
    • C. Myers
      You didn t understand my issue. If you are interestes, you can read my posting again. Thanks for the reply. ... You can set the background color on fo:inline
      Message 2 of 11 , Dec 3, 2004
        You didn't understand my issue. If you are interestes, you can read my posting again. Thanks for the reply.

        "W. Eliot Kimber" <ekimber@...> wrote:C. Myers wrote:

        >
        > Hi,
        >
        > I have been challenged by the following, I need to publish blocks of
        > text that required the left part of the text in yellow background
        > color, and the right part of the text is in gray background color.
        >

        You can set the background color on fo:inline or fo:block, which will
        set the background color for the text.

        <fo:block background-color="yellow">This is yellow</fo:block>

        Cheers,

        Eliot
        --
        W. Eliot Kimber
        Professional Services
        Innodata Isogen
        9390 Research Blvd, #410
        Austin, TX 78759
        (512) 372-8122

        eliot@...
        www.innodata-isogen.com

        Yahoo! Groups SponsorADVERTISEMENT


        ---------------------------------
        Yahoo! Groups Links

        To visit your group on the web, go to:
        http://groups.yahoo.com/group/XSL-FO/

        To unsubscribe from this group, send an email to:
        XSL-FO-unsubscribe@yahoogroups.com

        Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.




        ---------------------------------
        Do you Yahoo!?
        Yahoo! Mail - 250MB free storage. Do more. Manage less.

        [Non-text portions of this message have been removed]
      • W. Eliot Kimber
        ... Then I don t understand your problem. If you know which part is left and which part is right then you know enough to wrap the data in the appropriate
        Message 3 of 11 , Dec 3, 2004
          C. Myers wrote:

          > You didn't understand my issue. If you are interestes, you can read
          > my posting again. Thanks for the reply.
          >
          > "W. Eliot Kimber" <ekimber@...> wrote:C. Myers wrote:
          >
          >
          >
          >> Hi,
          >>
          >> I have been challenged by the following, I need to publish blocks
          >> of text that required the left part of the text in yellow
          >> background color, and the right part of the text is in gray
          >> background color.

          Then I don't understand your problem. If you know which part is "left"
          and which part is "right" then you know enough to wrap the data in the
          appropriate FOs in order to set the background color.

          If you just want static colors in the background of the blocks there's
          several ways to do that, the easiest being to have nested block
          containers, two for the left/right background colors and then another
          block container positioned on top of the ones underneath to hold the
          text itself.

          But to really suggest a solution we'd have to see a sample of the
          desired rendered result and the input data that would populate it.

          Cheers,

          Eliot
          --
          W. Eliot Kimber
          Professional Services
          Innodata Isogen
          9390 Research Blvd, #410
          Austin, TX 78759
          (512) 372-8122

          eliot@...
          www.innodata-isogen.com
        • Victor Vishnyakov
          In HTML make-up there is a trick when as a background was used 1px height and 1000px width gif with Xpx of the required color and (1000-X)px of the transparent
          Message 4 of 11 , Dec 5, 2004
            In HTML make-up there is a trick when as a background was used 1px height
            and 1000px width gif with Xpx of the required color and (1000-X)px of the
            transparent color. Thus a part of the background was painted with a color
            while remained part wasn't. This trick might be useful in your case.


            Best Regards,
            Victor Vishnyakov



            > -----Original Message-----
            > From: C. Myers [mailto:ccmyers98@...]
            > Sent: Friday, December 03, 2004 12:29 AM
            > To: XSL-FO@yahoogroups.com
            > Subject: [XSL-FO] Background-image challenge
            >
            >
            >
            > Hi,
            >
            > I have been challenged by the following, I need to publish
            > blocks of text that required the left part of the text in
            > yellow background color, and the right part of the text is in
            > gray background color.
            >
            > i.e.
            >
            > Original text:
            >
            > This is a text, and the text
            >
            > color could be red, yellow,
            >
            > and yellow.
            >
            > After style sheet is applied:
            >
            > This is a text, and the text
            >
            > color could be red, yellow,
            >
            > and yellow.
            >
            > Can someone out there provide some clue how to implement this? Thanks,
            >
            > -- Ching
          • C. Myers
            Thanks for your reply. The problem is that I don t know which text belongs to the left or right. I created a word file attached, hopefully I stated this issue
            Message 5 of 11 , Dec 6, 2004
              Thanks for your reply. The problem is that I don't know which text belongs to the left or right. I created a word file attached, hopefully I stated this issue more clear than before. Thanks again for your time.



              "W. Eliot Kimber" <ekimber@...> wrote:
              C. Myers wrote:

              > You didn't understand my issue. If you are interestes, you can read
              > my posting again. Thanks for the reply.
              >
              > "W. Eliot Kimber" <ekimber@...> wrote:C. Myers wrote:
              >
              >
              >
              >> Hi,
              >>
              >> I have been challenged by the following, I need to publish blocks
              >> of text that required the left part of the text in yellow
              >> background color, and the right part of the text is in gray
              >> background color.

              Then I don't understand your problem. If you know which part is "left"
              and which part is "right" then you know enough to wrap the data in the
              appropriate FOs in order to set the background color.

              If you just want static colors in the background of the blocks there's
              several ways to do that, the easiest being to have nested block
              containers, two for the left/right background colors and then another
              block container positioned on top of the ones underneath to hold the
              text itself.

              But to really suggest a solution we'd have to see a sample of the
              desired rendered result and the input data that would populate it.

              Cheers,

              Eliot
              --
              W. Eliot Kimber
              Professional Services
              Innodata Isogen
              9390 Research Blvd, #410
              Austin, TX 78759
              (512) 372-8122

              eliot@...
              www.innodata-isogen.com

              Yahoo! Groups SponsorADVERTISEMENT


              ---------------------------------
              Yahoo! Groups Links

              To visit your group on the web, go to:
              http://groups.yahoo.com/group/XSL-FO/

              To unsubscribe from this group, send an email to:
              XSL-FO-unsubscribe@yahoogroups.com

              Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



              __________________________________________________
              Do You Yahoo!?
              Tired of spam? Yahoo! Mail has the best spam protection around
              http://mail.yahoo.com

              [Non-text portions of this message have been removed]
            • W. Eliot Kimber
              ... The attachment didn t survive. But I m not sure I understand your issue. Either you know which text belongs two which language, in which case you can
              Message 6 of 11 , Dec 6, 2004
                C. Myers wrote:
                > Thanks for your reply. The problem is that I don't know which text
                > belongs to the left or right. I created a word file attached,
                > hopefully I stated this issue more clear than before. Thanks again
                > for your time.

                The attachment didn't survive.

                But I'm not sure I understand your issue.

                Either you know which text belongs two which language, in which case you
                can control where on the page it goes (e.g., using a table or
                list-block) or you simply want different background colors for each half
                of the page, in which case you can use any number of techniques.

                But if you don't know which text belongs to which language then I'm
                having a hard time seeing you'll ensure that the right language's text
                is given the appropriate background color.

                Cheers,

                E.
                --
                W. Eliot Kimber
                Professional Services
                Innodata Isogen
                9390 Research Blvd, #410
                Austin, TX 78759
                (512) 372-8122

                eliot@...
                www.innodata-isogen.com
              • C. Myers
                Other properties can be found in section 10. The number 1 should exist in the section 5. How should I
                Message 7 of 11 , Dec 6, 2004
                  <fo:table-cell>

                  <fo:block>Other properties can be found in section 10. The number 1 should exist in the section 5.</fo:block>

                  </fo:table-cell>



                  How should I modify the above style in order to obtain the following desired rendered result? Imagine this block has been split into two parts vertically, the left half is in yellow background color, and the right is in gray. Thanks.



                  Other properties can be found in

                  section 10. The number 1 should

                  exist in the section 5.



                  P.S. The gray color should go always to the end of each line (rectangle), I just don�t know how to create that in the word.


                  "W. Eliot Kimber" <ekimber@...> wrote:C. Myers wrote:
                  > Thanks for your reply. The problem is that I don't know which text
                  > belongs to the left or right. I created a word file attached,
                  > hopefully I stated this issue more clear than before. Thanks again
                  > for your time.

                  The attachment didn't survive.

                  But I'm not sure I understand your issue.

                  Either you know which text belongs two which language, in which case you
                  can control where on the page it goes (e.g., using a table or
                  list-block) or you simply want different background colors for each half
                  of the page, in which case you can use any number of techniques.

                  But if you don't know which text belongs to which language then I'm
                  having a hard time seeing you'll ensure that the right language's text
                  is given the appropriate background color.

                  Cheers,

                  E.
                  --
                  W. Eliot Kimber
                  Professional Services
                  Innodata Isogen
                  9390 Research Blvd, #410
                  Austin, TX 78759
                  (512) 372-8122

                  eliot@...
                  www.innodata-isogen.com

                  Yahoo! Groups SponsorADVERTISEMENT


                  ---------------------------------
                  Yahoo! Groups Links

                  To visit your group on the web, go to:
                  http://groups.yahoo.com/group/XSL-FO/

                  To unsubscribe from this group, send an email to:
                  XSL-FO-unsubscribe@yahoogroups.com

                  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.




                  ---------------------------------
                  Do you Yahoo!?
                  The all-new My Yahoo! � What will yours do?

                  [Non-text portions of this message have been removed]
                • W. Eliot Kimber
                  ... Still can t understand exactly what you re trying to do--if there was HTML formatting I only view mail as plain text. Can you do a pure text representation
                  Message 8 of 11 , Dec 6, 2004
                    C. Myers wrote:

                    >
                    > <fo:table-cell>
                    >
                    > <fo:block>Other properties can be found in section 10. The number 1
                    > should exist in the section 5.</fo:block>
                    >
                    > </fo:table-cell>
                    >
                    >
                    >
                    > How should I modify the above style in order to obtain the following
                    > desired rendered result? Imagine this block has been split into two
                    > parts vertically, the left half is in yellow background color, and
                    > the right is in gray. Thanks.
                    >
                    >
                    >
                    > Other properties can be found in
                    >
                    > section 10. The number 1 should
                    >
                    > exist in the section 5.

                    Still can't understand exactly what you're trying to do--if there was
                    HTML formatting I only view mail as plain text. Can you do a pure text
                    representation of what you're trying to achieve?

                    Note that the question isn't what to do with the FO's, but what FOs to
                    put the original data into (unless the original data is itself XSL-FO,
                    which seems unlikely.

                    That is, if you're asking how to modify existing FO elements, you've
                    gone too far forward. The question is what to do *when generating the FO
                    elements* in order to get the effect you need.

                    Cheers,

                    Eliot
                    --
                    W. Eliot Kimber
                    Professional Services
                    Innodata Isogen
                    9390 Research Blvd, #410
                    Austin, TX 78759
                    (512) 372-8122

                    eliot@...
                    www.innodata-isogen.com
                  • C. Myers
                    Thanks for your hint of using nested block-container. I got it solved. -- Ching W. Eliot Kimber wrote: ... The attachment
                    Message 9 of 11 , Dec 6, 2004
                      Thanks for your hint of using nested block-container. I got it solved.
                      -- Ching

                      "W. Eliot Kimber" <ekimber@...> wrote:
                      C. Myers wrote:
                      > Thanks for your reply. The problem is that I don't know which text
                      > belongs to the left or right. I created a word file attached,
                      > hopefully I stated this issue more clear than before. Thanks again
                      > for your time.

                      The attachment didn't survive.

                      But I'm not sure I understand your issue.

                      Either you know which text belongs two which language, in which case you
                      can control where on the page it goes (e.g., using a table or
                      list-block) or you simply want different background colors for each half
                      of the page, in which case you can use any number of techniques.

                      But if you don't know which text belongs to which language then I'm
                      having a hard time seeing you'll ensure that the right language's text
                      is given the appropriate background color.

                      Cheers,

                      E.
                      --
                      W. Eliot Kimber
                      Professional Services
                      Innodata Isogen
                      9390 Research Blvd, #410
                      Austin, TX 78759
                      (512) 372-8122

                      eliot@...
                      www.innodata-isogen.com

                      Yahoo! Groups SponsorADVERTISEMENT


                      ---------------------------------
                      Yahoo! Groups Links

                      To visit your group on the web, go to:
                      http://groups.yahoo.com/group/XSL-FO/

                      To unsubscribe from this group, send an email to:
                      XSL-FO-unsubscribe@yahoogroups.com

                      Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


                      __________________________________________________
                      Do You Yahoo!?
                      Tired of spam? Yahoo! Mail has the best spam protection around
                      http://mail.yahoo.com

                      [Non-text portions of this message have been removed]
                    • C. Myers
                      Hi, I need to use the column-width as a base variable to derive another value dynamically, I tried to use the function of from-table-column() , it didn t
                      Message 10 of 11 , Dec 6, 2004
                        Hi,

                        I need to use the column-width as a base variable to derive another value dynamically, I tried to use the function of "from-table-column()", it didn't work. Could someone give me a hint? Please refer to the following codes, thanks.



                        <fo:table space-before.optimum="3pt">

                        <fo:table-column column-width="proportional-column-width(2.5)"/>

                        <fo:table-column column-width="proportional-column-width(3.5)"/>

                        <fo:table-column column-width="proportional-column-width(20)"/>

                        <fo:table-body>

                        <fo:table-row>

                        <fo:table-cell>

                        <fo:block><xsl:call-template name="code-left-icons" /></fo:block>

                        </fo:table-cell>

                        <fo:table-cell>

                        <xsl:call-template name="codetemplate" />

                        </fo:table-cell>

                        <fo:table-cell>

                        <xsl:variable name="column-width"><xsl:value-of select="from-table-column(column-width)" /></xsl:variable>

                        <fo:block><xsl:value-of select="$column-width" /></fo:block>

                        <xsl:call-template name="descriptiontemplate" />

                        </fo:table-cell>

                        </fo:table-row>

                        </fo:table-body>

                        </fo:table>

                        </xsl:template>




                        ---------------------------------
                        Do you Yahoo!?
                        Yahoo! Mail - 250MB free storage. Do more. Manage less.

                        [Non-text portions of this message have been removed]
                      Your message has been successfully submitted and would be delivered to recipients shortly.