OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Using a XSL call template to a SVG for a background-image


Title: KCC Stationery
Hello all,
 
I would like to have an <fo:block background-image=""/> where the background image goes to a template in my XSLFO that contains an SVG.  Is this possible?
 
What I'm trying to do is have the docbook XSL header.content contain a background image...
 
Below is some code:
 
XSLT: (this is currently calling an external image for its background)...but I want it to use the template below:

<fo:block background-image="url({$graphics.path}{$header.image.filename})" background-repeat="no-repeat" background-position-horizontal="center" background-position-vertical="bottom" padding-bottom="30pt">

<xsl:choose>

<xsl:when test="$double.sided != 0 and

($sequence = 'even' or $sequence = 'last'

$sequence = 'blank' ) and $position='left'">

<fo:block padding-top="0pt" >

<xsl:apply-templates select="self::chapter/title" mode="title.markup"/>

</fo:block>

</xsl:when>

<xsl:when test="$double.sided != 0 and

($sequence = 'odd') and $position='right' ">

<fo:block padding-top="0pt" >

<xsl:apply-templates select="self::chapter/title" mode="title.markup"/>

</fo:block>

</xsl:when>

</xsl:choose>

</fo:block>

 

<xsl:template name="svg.header">

<fo:inline>

<fo:instream-foreign-object>

<svg:svg width="522" height="26.25" viewBox="0 0 522 26.25" id="autocar_header" xml:space="preserve">

<svg:g id="Layer_1">

<svg:line fill="none" stroke="#000000" stroke-width="1.98" stroke-miterlimit="10" x1="0" y1="15.286" x2="522" y2="15.286" id="line7" style="fill:none;stroke:#000000;stroke-width:1.98000002;stroke-miterlimit:10"/>

<svg:rect width="522" height="1.98" x="0" y="10.276" style="fill:#870000" id="rect9"/>

<svg:rect width="60.299999" height="26.219999" x="232.02" y="0.016000001" style="fill:#ffffff" id="rect11"/>

<svg:path d="M 281.413,4.492 L 292.298,4.506 L 292.298,21.832 L 281.313,21.832 C 281.313,21.832 275.551,26.25 261.612,26.25 C 247.673,26.25 241.724,21.846 241.724,21.846 L 231.998,21.846 L 231.998,4.492 L 241.681,4.492 C 241.681,4.492 248.151,0 261.178,0 C 275.073,0 281.413,4.492 281.413,4.492" style="fill:#231f20" id="path13"/>

<svg:path d="M 291.415,5.349 L 291.386,5.32 L 281.138,5.32 C 281.138,5.32 275.001,0.901 261.627,0.901 C 247.905,0.901 242.029,5.32 242.029,5.32 L 232.881,5.32 L 232.823,20.989 L 241.971,20.989 C 241.971,20.989 247.905,25.437 261.598,25.437 C 275.291,25.437 281.167,20.989 281.167,20.989 L 291.415,20.989 L 291.415,5.349 M 280.82,19.826 C 280.82,19.826 274.827,24.274 261.974,24.274 C 247.818,24.274 242.318,19.826 242.318,19.826 L 234.01,19.797 L 234.01,6.512 L 242.318,6.512 C 242.318,6.512 248.194,2.064 261.598,2.064 C 275.001,2.064 280.791,6.512 280.791,6.512 L 290.344,6.512 L 290.344,19.797 L 280.82,19.826 z " style="fill:#ffffff" id="path15"/>

<svg:line fill="none" stroke="#FFFFFF" stroke-width="0.4071" stroke-miterlimit="10" x1="249.41" y1="19.941999" x2="273.87201" y2="19.941999" id="line17" style="fill:none;stroke:#ffffff;stroke-width:0.40709999;stroke-miterlimit:10"/>

<svg:line fill="none" stroke="#FFFFFF" stroke-width="0.4071" stroke-miterlimit="10" x1="249.403" y1="6.3239999" x2="273.86499" y2="6.3239999" id="line19" style="fill:none;stroke:#ffffff;stroke-width:0.40709999;stroke-miterlimit:10"/>

<svg:path d="M 238.975,13.84 C 238.93,13.84 238.919,13.807 238.93,13.762 L 239.953,11.016 C 239.964,10.972 239.986,10.916 240.02,10.916 C 240.053,10.916 240.064,10.972 240.075,11.016 L 241.076,13.773 C 241.087,13.807 241.076,13.84 241.02,13.84 L 238.975,13.84 M 241.231,14.398 C 241.287,14.398 241.32,14.421 241.342,14.476 L 242.232,16.843 C 242.287,16.977 242.21,17.077 242.132,17.1 C 242.021,17.111 241.976,17.133 241.976,17.2 C 241.976,17.278 242.109,17.278 242.31,17.29 C 243.199,17.312 244.01,17.312 244.411,17.312 C 244.822,17.312 244.922,17.29 244.922,17.2 C 244.922,17.122 244.866,17.111 244.777,17.111 C 244.644,17.111 244.477,17.1 244.311,17.066 C 244.077,17.011 243.755,16.854 243.332,15.85 C 242.621,14.153 240.842,9.598 240.575,8.984 C 240.464,8.728 240.398,8.627 240.298,8.627 C 240.186,8.627 240.12,8.75 239.986,9.074 L 237.196,16.084 C 236.974,16.642 236.763,17.021 236.251,17.089 C 236.162,17.1 236.007,17.11 235.907,17.11 C 235.818,17.11 235.773,17.132 235.773,17.199 C 235.773,17.289 235.84,17.311 235.984,17.311 C 236.563,17.311 237.174,17.277 237.296,17.277 C 237.641,17.277 238.119,17.311 238.475,17.311 C 238.597,17.311 238.663,17.289 238.663,17.199 C 238.663,17.132 238.63,17.11 238.497,17.11 L 238.33,17.11 C 237.985,17.11 237.885,16.965 237.885,16.764 C 237.885,16.63 237.941,16.362 238.052,16.083 L 238.652,14.487 C 238.675,14.42 238.697,14.397 238.752,14.397 L 241.231,14.397 L 241.231,14.398 z " style="fill:#ffffff" id="path21"/>

<svg:path d="M 244.234,12.595 C 244.234,11.057 244.234,10.774 244.214,10.45 C 244.194,10.106 244.113,9.944 243.781,9.873 C 243.7,9.853 243.529,9.843 243.388,9.843 C 243.277,9.843 243.217,9.823 243.217,9.752 C 243.217,9.681 243.287,9.661 243.439,9.661 C 243.972,9.661 244.607,9.691 244.909,9.691 C 245.151,9.691 245.786,9.661 246.149,9.661 C 246.3,9.661 246.37,9.681 246.37,9.752 C 246.37,9.823 246.31,9.843 246.209,9.843 C 246.098,9.843 246.038,9.853 245.917,9.873 C 245.645,9.924 245.564,10.096 245.544,10.45 C 245.524,10.774 245.524,11.057 245.524,12.595 L 245.524,14.011 C 245.524,15.478 245.816,16.095 246.31,16.499 C 246.763,16.874 247.226,16.914 247.569,16.914 C 248.012,16.914 248.556,16.772 248.959,16.368 C 249.513,15.811 249.543,14.901 249.543,13.859 L 249.543,12.595 C 249.543,11.057 249.543,10.774 249.523,10.45 C 249.503,10.106 249.423,9.944 249.09,9.873 C 249.009,9.853 248.838,9.843 248.727,9.843 C 248.616,9.843 248.556,9.823 248.556,9.752 C 248.556,9.681 248.627,9.661 248.768,9.661 C 249.281,9.661 249.916,9.691 249.926,9.691 C 250.047,9.691 250.682,9.661 251.075,9.661 C 251.216,9.661 251.286,9.681 251.286,9.752 C 251.286,9.823 251.226,9.843 251.105,9.843 C 250.994,9.843 250.934,9.853 250.813,9.873 C 250.541,9.924 250.46,10.096 250.44,10.45 C 250.42,10.774 250.42,11.057 250.42,12.595 L 250.42,13.677 C 250.42,14.8 250.309,15.994 249.463,16.722 C 248.748,17.339 248.022,17.45 247.367,17.45 C 246.834,17.45 245.866,17.42 245.131,16.752 C 244.617,16.287 244.234,15.538 244.234,14.071 L 244.234,12.595" style="fill:#ffffff" id="path23"/>

<svg:path d="M 254.271,10.227 L 252.77,10.268 C 252.186,10.288 251.944,10.339 251.793,10.561 C 251.692,10.713 251.642,10.834 251.622,10.915 C 251.601,10.996 251.571,11.037 251.511,11.037 C 251.44,11.037 251.42,10.986 251.42,10.875 C 251.42,10.713 251.612,9.792 251.632,9.711 C 251.662,9.58 251.692,9.519 251.753,9.519 C 251.833,9.519 251.934,9.62 252.186,9.641 C 252.478,9.671 252.861,9.691 253.193,9.691 L 257.183,9.691 C 257.827,9.691 258.069,9.59 258.15,9.59 C 258.22,9.59 258.23,9.651 258.23,9.803 C 258.23,10.015 258.2,10.713 258.2,10.976 C 258.19,11.077 258.17,11.138 258.109,11.138 C 258.029,11.138 258.008,11.087 257.998,10.935 L 257.989,10.824 C 257.968,10.561 257.696,10.278 256.8,10.258 L 255.53,10.227 L 255.53,14.375 C 255.53,15.306 255.53,16.105 255.581,16.54 C 255.611,16.823 255.671,17.046 255.974,17.086 C 256.115,17.106 256.336,17.127 256.487,17.127 C 256.598,17.127 256.649,17.157 256.649,17.208 C 256.649,17.278 256.568,17.309 256.457,17.309 C 255.792,17.309 255.158,17.278 254.875,17.278 C 254.644,17.278 254.009,17.309 253.606,17.309 C 253.475,17.309 253.405,17.278 253.405,17.208 C 253.405,17.157 253.445,17.127 253.566,17.127 C 253.717,17.127 253.838,17.106 253.929,17.086 C 254.13,17.046 254.19,16.823 254.221,16.53 C 254.271,16.105 254.271,15.306 254.271,14.375 L 254.271,10.227" style="fill:#ffffff" id="path25"/>

<svg:path d="M 262.432,16.944 C 260.497,16.944 259.339,15.275 259.339,13.172 C 259.339,10.652 260.659,10.006 261.817,10.006 C 263.469,10.006 264.768,11.412 264.768,13.678 C 264.768,16.6 263.137,16.944 262.432,16.944 M 262.009,17.45 C 264.567,17.45 266.179,15.619 266.179,13.303 C 266.179,10.986 264.618,9.519 262.109,9.519 C 259.087,9.519 257.949,11.755 257.949,13.485 C 257.949,15.275 259.117,17.45 262.009,17.45 z " style="fill:#ffffff" id="path27"/>

<svg:path d="M 267.88,16.348 C 266.892,15.478 266.63,14.345 266.63,13.364 C 266.63,12.675 266.842,11.482 267.809,10.592 C 268.534,9.924 269.491,9.519 270.993,9.519 C 271.617,9.519 271.99,9.56 272.453,9.62 C 272.836,9.671 273.158,9.762 273.461,9.792 C 273.572,9.803 273.612,9.853 273.612,9.914 C 273.612,9.995 273.581,10.116 273.56,10.47 C 273.54,10.804 273.55,11.36 273.531,11.563 C 273.521,11.714 273.501,11.795 273.411,11.795 C 273.33,11.795 273.309,11.714 273.309,11.573 C 273.299,11.259 273.167,10.905 272.916,10.642 C 272.583,10.288 271.797,10.015 270.871,10.015 C 269.994,10.015 269.42,10.237 268.977,10.642 C 268.241,11.32 268.05,12.281 268.05,13.262 C 268.05,15.67 269.873,16.863 271.223,16.863 C 272.12,16.863 272.664,16.762 273.068,16.297 C 273.239,16.105 273.37,15.811 273.411,15.63 C 273.441,15.468 273.461,15.427 273.541,15.427 C 273.612,15.427 273.632,15.498 273.632,15.579 C 273.632,15.7 273.511,16.58 273.411,16.924 C 273.36,17.096 273.319,17.147 273.149,17.218 C 272.746,17.38 271.98,17.45 271.335,17.45 C 269.955,17.45 268.796,17.147 267.88,16.348" style="fill:#ffffff" id="path29"/>

<svg:path d="M 276.286,14.163 C 276.245,14.163 276.235,14.132 276.245,14.092 L 277.172,11.603 C 277.182,11.563 277.203,11.512 277.234,11.512 C 277.263,11.512 277.274,11.563 277.284,11.603 L 278.191,14.102 C 278.201,14.132 278.191,14.163 278.139,14.163 L 276.286,14.163 M 278.33,14.668 C 278.381,14.668 278.412,14.689 278.431,14.739 L 279.238,16.884 C 279.289,17.005 279.217,17.096 279.148,17.117 C 279.046,17.127 279.006,17.147 279.006,17.208 C 279.006,17.278 279.126,17.278 279.308,17.289 C 280.115,17.309 280.849,17.309 281.212,17.309 C 281.584,17.309 281.675,17.289 281.675,17.208 C 281.675,17.137 281.625,17.127 281.544,17.127 C 281.423,17.127 281.273,17.117 281.121,17.086 C 280.91,17.035 280.617,16.894 280.235,15.983 C 279.589,14.446 277.977,10.319 277.736,9.762 C 277.634,9.529 277.575,9.438 277.484,9.438 C 277.383,9.438 277.323,9.55 277.203,9.843 L 274.674,16.196 C 274.472,16.702 274.281,17.046 273.819,17.106 C 273.738,17.117 273.596,17.127 273.506,17.127 C 273.426,17.127 273.385,17.147 273.385,17.208 C 273.385,17.289 273.447,17.309 273.577,17.309 C 274.1,17.309 274.655,17.278 274.765,17.278 C 275.078,17.278 275.511,17.309 275.834,17.309 C 275.944,17.309 276.004,17.289 276.004,17.208 C 276.004,17.147 275.975,17.127 275.853,17.127 L 275.704,17.127 C 275.391,17.127 275.3,16.995 275.3,16.813 C 275.3,16.692 275.351,16.449 275.451,16.196 L 275.996,14.749 C 276.015,14.689 276.036,14.668 276.086,14.668 L 278.33,14.668 L 278.33,14.668 z " style="fill:#ffffff" id="path31"/>

<svg:path d="M 283.015,10.319 C 283.015,10.237 283.036,10.197 283.107,10.177 C 283.208,10.146 283.388,10.136 283.64,10.136 C 284.235,10.136 285.181,10.551 285.181,11.988 C 285.181,12.817 284.889,13.282 284.587,13.505 C 284.406,13.636 284.274,13.677 283.871,13.677 C 283.62,13.677 283.317,13.646 283.106,13.576 C 283.035,13.545 283.014,13.505 283.014,13.394 L 283.014,10.319 M 281.826,14.375 C 281.826,15.306 281.826,16.105 281.776,16.53 C 281.736,16.823 281.685,17.046 281.484,17.086 C 281.392,17.106 281.272,17.127 281.121,17.127 C 281,17.127 280.96,17.157 280.96,17.208 C 280.96,17.278 281.031,17.309 281.162,17.309 C 281.564,17.309 282.199,17.278 282.391,17.278 C 282.542,17.278 283.287,17.309 283.871,17.309 C 284.002,17.309 284.073,17.278 284.073,17.208 C 284.073,17.157 284.032,17.127 283.952,17.127 C 283.831,17.127 283.609,17.106 283.458,17.086 C 283.156,17.046 283.096,16.823 283.066,16.53 C 283.014,16.105 283.014,15.306 283.014,14.365 L 283.014,14.223 C 283.014,14.163 283.044,14.142 283.095,14.142 L 283.971,14.163 C 284.042,14.163 284.102,14.173 284.154,14.234 C 284.285,14.385 284.748,15.073 285.151,15.63 C 285.714,16.408 286.097,16.884 286.531,17.117 C 286.793,17.258 287.045,17.309 287.609,17.309 L 288.566,17.309 C 288.687,17.309 288.757,17.289 288.757,17.208 C 288.757,17.157 288.716,17.127 288.636,17.127 C 288.555,17.127 288.465,17.117 288.353,17.096 C 288.203,17.066 287.79,16.995 287.225,16.408 C 286.631,15.781 285.937,14.881 285.039,13.748 C 286.056,12.918 286.369,12.23 286.369,11.482 C 286.369,10.804 285.966,10.288 285.683,10.096 C 285.139,9.722 284.464,9.661 283.829,9.661 C 283.516,9.661 282.751,9.691 282.409,9.691 C 282.197,9.691 281.562,9.661 281.029,9.661 C 280.878,9.661 280.806,9.681 280.806,9.752 C 280.806,9.823 280.867,9.843 280.978,9.843 C 281.119,9.843 281.29,9.853 281.372,9.873 C 281.704,9.944 281.784,10.106 281.805,10.45 C 281.825,10.774 281.825,11.057 281.825,12.595 L 281.825,14.375 L 281.826,14.375 z " style="fill:#ffffff" id="path33"/>

</svg:g>

</svg:svg>

 
 
 
David White
Ken Cook Co.,
Content Management
davidw@kencook.com
http://www.kencook.com
tel: 414.847.1322
 
 
 


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]