[xep-support] The perfect triangle

From: Mark Cilia Vincenti <markciliavincenti@gmail.com>
Date: Wed Dec 17 2008 - 01:17:00 PST

Hi,

I have a table with 2 columns:

The left column has the background color #BEBEBE.
The right column has triangle.svg as a background image.

I have this SVG:

<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "
http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg viewBox="0 0 57 104" version="1.1" xmlns="http://www.w3.org/2000/svg">
<polygon points="0,0 0,104 57,0" fill="#BEBEBE" />
</svg>

This produces something that looks a bit like antialiasing at the top of the
image from what I can see. In fact by putting the whole table inside a block
with background-color="red", it was apparent. And it prints as well.

So I tried this instead:

 <?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "
http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg viewBox="0 0 57 104" version="1.1" xmlns="http://www.w3.org/2000/svg">
<polygon points="0,0 0,104 57,0" fill="#BEBEBE" stroke="#BEBEBE"
stroke-width="1" />
</svg>

This still shows the red background at the top at certain percentages, but
it's less obvious. However more alarmingly is that the top right corner
looks like it's chopped off. It's no longer pointed.

How can I achieve this please?

Full FO code here:

<fo:block background-color="red">
 <fo:table width="100%" space-after.optimum="6pt">
  <fo:table-column />
  <fo:table-column column-width="5mm" />
  <fo:table-body>
   <fo:table-row height="5mm">
    <fo:table-cell background-color="#BEBEBE">
     <fo:block margin-left="1mm" line-height="5mm" font-size="10.5pt"
color="#FFFFFF" font-weight="bold">This is a long sentence and it may or may
not wrap.</fo:block>
    </fo:table-cell>
    <fo:table-cell rx:background-content-height="100%"
rx:background-content-width="5mm" rx:background-scaling="non-uniform"
background-repeat="no-repeat" background="url('triangle.svg')" />
   </fo:table-row>
  </fo:table-body>
 </fo:table>
</fo:block>

-------------------
(*) To unsubscribe, send a message with words 'unsubscribe xep-support'
in the body of the message to majordomo@renderx.com from the address
you are subscribed from.
(*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/terms-of-service.html
Received on Wed Dec 17 01:44:53 2008

This archive was generated by hypermail 2.1.8 : Wed Dec 17 2008 - 01:44:59 PST