github.com/pdfcpu/pdfcpu@v0.11.1/pkg/testdata/json/create/textAndAlignment.json (about) 1 { 2 "paper": "A4P", 3 "crop": "10", 4 "origin": "LowerLeft", 5 "debug": false, 6 "contentBox": true, 7 "guides": true, 8 "colors": { 9 "DarkOrange": "#FF8C00", 10 "DarkSeaGreen": "#8FBC8F", 11 "LimeGreen": "#BEDED9" 12 }, 13 "dirs": { 14 "images": "../../testdata/resources" 15 }, 16 "files": { 17 "logo1": "$images/logoVerySmall.png", 18 "logo2": "$images/github.png" 19 }, 20 "fonts": { 21 "myCourier": { 22 "name": "Courier", 23 "size": 12 24 }, 25 "myCourierBold": { 26 "name": "Courier-Bold", 27 "size": 12 28 }, 29 "input": { 30 "name": "Helvetica", 31 "size": 12, 32 "xcol": "#222222" 33 }, 34 "label": { 35 "name": "Helvetica", 36 "size": 12 37 } 38 }, 39 "margin": { 40 "width": 10 41 }, 42 "header": { 43 "font": { 44 "name": "$myCourierBold", 45 "size": 24, 46 "col": "#C00000" 47 }, 48 "left": "$logo1", 49 "center": "Textboxes and Alignment", 50 "right": "$logo2", 51 "height": 40, 52 "dx": 5, 53 "dy": 5, 54 "border": false 55 }, 56 "footer": { 57 "font": { 58 "name": "Courier", 59 "size": 9 60 }, 61 "left": "pdfcpu: %v\nCreated: %t", 62 "center": "Page %p of %P", 63 "right": "Source:\ntestdata/json/create/textAndAlignment.json", 64 "height": 30, 65 "dx": 5, 66 "dy": 5, 67 "border": false 68 }, 69 "images": { 70 "logo1": { 71 "src": "$logo1", 72 "url": "https://pdfcpu.io", 73 "margin": { 74 "width": 5 75 } 76 }, 77 "logo2": { 78 "src": "$logo2", 79 "url": "https://github.com/pdfcpu/pdfcpu", 80 "margin": { 81 "width": 5 82 } 83 } 84 }, 85 "pages": { 86 "1": { 87 "bgcol": "LightGray", 88 "content": { 89 "guides": [ 90 { 91 "pos": [ 92 -1, 93 650 94 ] 95 }, 96 { 97 "pos": [ 98 -1, 99 600 100 ] 101 }, 102 { 103 "pos": [ 104 -1, 105 550 106 ] 107 }, 108 { 109 "pos": [ 110 -1, 111 485 112 ] 113 }, 114 115 { 116 "pos": [ 117 -1, 118 420 119 ] 120 }, 121 { 122 "pos": [ 123 -1, 124 370 125 ] 126 }, 127 { 128 "pos": [ 129 -1, 130 320 131 ] 132 }, 133 { 134 "pos": [ 135 -1, 136 260 137 ] 138 }, 139 140 { 141 "pos": [ 142 -1, 143 190 144 ] 145 }, 146 { 147 "pos": [ 148 -1, 149 140 150 ] 151 }, 152 { 153 "pos": [ 154 -1, 155 90 156 ] 157 }, 158 { 159 "pos": [ 160 -1, 161 3 162 ] 163 } 164 ], 165 "text": [ 166 { 167 "hide": false, 168 "value": "Textboxes without width:", 169 "pos": [ 170 1, 171 680 172 ], 173 "font": { 174 "name": "$myCourier" 175 } 176 }, 177 { 178 "hide": false, 179 "value": "A left aligned text\nwith border and padding.", 180 "pos": [ 181 -1, 182 650 183 ], 184 "align": "left", 185 "bgcol": "$LimeGreen", 186 "border": { 187 "width": 2, 188 "col": "Black" 189 }, 190 "font": { 191 "name": "$myCourier" 192 }, 193 "padding": { 194 "width": 5 195 } 196 }, 197 { 198 "hide": false, 199 "value": "A center aligned text\nwith border and padding.", 200 "pos": [ 201 -1, 202 600 203 ], 204 "align": "center", 205 "bgcol": "$LimeGreen", 206 "border": { 207 "width": 2, 208 "col": "Black" 209 }, 210 "font": { 211 "name": "$myCourier" 212 }, 213 "padding": { 214 "width": 5 215 } 216 }, 217 { 218 "hide": false, 219 "value": "A right aligned text\nwith border and padding.", 220 "pos": [ 221 -1, 222 550 223 ], 224 "align": "right", 225 "bgcol": "$LimeGreen", 226 "border": { 227 "width": 2, 228 "col": "Black" 229 }, 230 "font": { 231 "name": "$myCourier" 232 }, 233 "padding": { 234 "width": 5 235 } 236 }, 237 { 238 "hide": false, 239 "value": "A justified aligned text\nwith border and padding.", 240 "pos": [ 241 -1, 242 485 243 ], 244 "align": "justify", 245 "bgcol": "$LimeGreen", 246 "border": { 247 "width": 2, 248 "col": "Black" 249 }, 250 "font": { 251 "name": "$myCourier" 252 }, 253 "padding": { 254 "width": 5 255 } 256 }, 257 258 { 259 "hide": false, 260 "value": "Textboxes using width: 200", 261 "pos": [ 262 1, 263 450 264 ], 265 "font": { 266 "name": "$myCourier" 267 } 268 }, 269 { 270 "hide": false, 271 "value": "A left aligned text\nwith border and padding.", 272 "pos": [ 273 -1, 274 420 275 ], 276 "width": 200, 277 "align": "left", 278 "bgcol": "$DarkSeaGreen", 279 "border": { 280 "width": 2, 281 "col": "Black" 282 }, 283 "font": { 284 "name": "$myCourier" 285 }, 286 "padding": { 287 "width": 5 288 } 289 }, 290 { 291 "hide": false, 292 "value": "A center aligned text\nwith border and padding.", 293 "pos": [ 294 -1, 295 370 296 ], 297 "width": 200, 298 "align": "center", 299 "bgcol": "$DarkSeaGreen", 300 "border": { 301 "width": 2, 302 "col": "Black" 303 }, 304 "font": { 305 "name": "$myCourier" 306 }, 307 "padding": { 308 "width": 5 309 } 310 }, 311 { 312 "hide": false, 313 "value": "A right aligned text\nwith border and padding.", 314 "pos": [ 315 -1, 316 320 317 ], 318 "width": 200, 319 "align": "right", 320 "bgcol": "$DarkSeaGreen", 321 "border": { 322 "width": 2, 323 "col": "Black" 324 }, 325 "font": { 326 "name": "$myCourier" 327 }, 328 "padding": { 329 "width": 5 330 } 331 }, 332 { 333 "hide": false, 334 "value": "A justified aligned text with border and padding.", 335 "pos": [ 336 -1, 337 260 338 ], 339 "width": 200, 340 "align": "justify", 341 "bgcol": "$DarkSeaGreen", 342 "border": { 343 "width": 2, 344 "col": "Black" 345 }, 346 "font": { 347 "name": "$myCourier" 348 }, 349 "padding": { 350 "width": 5 351 } 352 }, 353 354 { 355 "hide": false, 356 "value": "Textboxes using width: 100", 357 "pos": [ 358 1, 359 220 360 ], 361 "font": { 362 "name": "$myCourier" 363 } 364 }, 365 { 366 "hide": false, 367 "value": "A left aligned text\nwith border and padding.", 368 "pos": [ 369 -1, 370 190 371 ], 372 "width": 100, 373 "align": "left", 374 "bgcol": "$DarkOrange", 375 "border": { 376 "width": 2, 377 "col": "Black" 378 }, 379 "font": { 380 "name": "$myCourier" 381 }, 382 "padding": { 383 "width": 5 384 } 385 }, 386 { 387 "hide": false, 388 "value": "A center aligned text\nwith border and padding.", 389 "pos": [ 390 -1, 391 140 392 ], 393 "width": 100, 394 "align": "center", 395 "bgcol": "$DarkOrange", 396 "border": { 397 "width": 2, 398 "col": "Black" 399 }, 400 "font": { 401 "name": "$myCourier" 402 }, 403 "padding": { 404 "width": 5 405 } 406 }, 407 { 408 "hide": false, 409 "value": "A right aligned text\nwith border and padding.", 410 "pos": [ 411 -1, 412 90 413 ], 414 "width": 100, 415 "align": "right", 416 "bgcol": "$DarkOrange", 417 "border": { 418 "width": 2, 419 "col": "Black" 420 }, 421 "font": { 422 "name": "$myCourier" 423 }, 424 "padding": { 425 "width": 5 426 } 427 }, 428 { 429 "hide": false, 430 "value": "A justified aligned text with border and padding.", 431 "pos": [ 432 -1, 433 3 434 ], 435 "width": 100, 436 "align": "justify", 437 "bgcol": "$DarkOrange", 438 "border": { 439 "width": 2, 440 "col": "Black" 441 }, 442 "font": { 443 "name": "$myCourier" 444 }, 445 "padding": { 446 "width": 5 447 } 448 } 449 ] 450 } 451 } 452 } 453 }