{"id":227,"date":"2024-04-14T16:43:38","date_gmt":"2024-04-14T07:43:38","guid":{"rendered":"https:\/\/chocottopro.com\/?p=227"},"modified":"2024-06-14T16:40:36","modified_gmt":"2024-06-14T07:40:36","slug":"%e3%80%90python%e5%88%9d%e5%bf%83%e8%80%85%e5%90%91%e3%81%91%e3%80%91reportlab%e3%82%92%e4%bd%bf%e3%81%a3%e3%81%a6pdf%e3%82%92%e8%87%aa%e5%8b%95%e7%94%9f%e6%88%90%e3%81%99%e3%82%8b%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"https:\/\/chocottopro.com\/?p=227","title":{"rendered":"\u3010Python\u521d\u5fc3\u8005\u5411\u3051\u3011reportlab\u3092\u4f7f\u3063\u3066PDF\u3092\u81ea\u52d5\u751f\u6210\u3059\u308b\u65b9\u6cd5\u3092\u5fb9\u5e95\u89e3\u8aac\uff01"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Python\u3067PDF\u3092\u81ea\u52d5\u751f\u6210\u3057\u305f\u3044\u3001\u3067\u3082\u4f55\u304b\u3089\u59cb\u3081\u308c\u3070\u3044\u3044\u304b\u5206\u304b\u3089\u306a\u3044\u30fb\u30fb\u30fb\u3002\u305d\u3093\u306a\u65b9\u306b\u304a\u3059\u3059\u3081\u306a\u306e\u304c\u3001Python\u306e\u5f37\u529b\u306aPDF\u30e9\u30a4\u30d6\u30e9\u30ea\u300creportlab\u300d\u3067\u3059\u3002\u672c\u8a18\u4e8b\u3067\u306f\u3001reportlab\u3092\u4f7f\u3063\u305fPDF\u306e\u81ea\u52d5\u751f\u6210\u3092\u3001\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u304b\u3089\u30b0\u30e9\u30d5\u63cf\u753b\u3001\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u8a2d\u5b9a\u307e\u3067\u3001\u521d\u5fc3\u8005\u5411\u3051\u306b\u5fb9\u5e95\u89e3\u8aac\u3057\u307e\u3059\u3002Python\u3067\u306e\u5e33\u7968\u81ea\u52d5\u5316\u3092\u76ee\u6307\u3059\u30a8\u30f3\u30b8\u30cb\u30a2\u5fc5\u898b\u306e\u5185\u5bb9\u3067\u3059\uff01<\/p>\n\n\n\n<div class=\"wp-block-sgb-block-simple sgb-box-simple sgb-box-simple--title-normal sgb-box-simple--with-border\"><div style=\"background-color:var(--wp--preset--color--sango-main);color:#FFF\" class=\"sgb-box-simple__title\">\u3053\u306e\u8a18\u4e8b\u3092\u8aad\u3093\u3060\u3089\u308f\u304b\u308b\u3053\u3068<\/div><div class=\"sgb-box-simple__body\" style=\"border-color:var(--wp--preset--color--sango-main);background-color:#FFF\">\n<ul class=\"wp-block-list\">\n<li>reportlab\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u3068\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u306e\u8a2d\u5b9a <\/li>\n\n\n\n<li>PDF\u3078\u306e\u30c6\u30ad\u30b9\u30c8\u3001\u753b\u50cf\u3001\u30c6\u30fc\u30d6\u30eb\u306e\u63cf\u753b\u65b9\u6cd5 <\/li>\n\n\n\n<li>\u30da\u30fc\u30b8\u756a\u53f7\u30fb\u76ee\u6b21\u306e\u81ea\u52d5\u8ffd\u52a0\u3068\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u6d3b\u7528\u306e\u30b3\u30c4 <\/li>\n\n\n\n<li>\u30b0\u30e9\u30d5\u63cf\u753b\u3084\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u8a2d\u5b9a\u306a\u3069\u306e\u9ad8\u5ea6\u306a\u6a5f\u80fd\u306e\u4f7f\u3044\u65b9 <\/li>\n\n\n\n<li>reportlab\u3092\u4f7f\u3063\u305f\u696d\u52d9\u306e\u81ea\u52d5\u5316\u30fb\u52b9\u7387\u5316\u306e\u30d2\u30f3\u30c8<\/li>\n<\/ul>\n<\/div><\/div>\n\n\n\n<div class=\"toc\"><br \/>\n<b>Warning<\/b>:  Undefined array key \"is_admin\" in <b>\/home\/c7479301\/public_html\/chocottopro.com\/wp-content\/themes\/sango-theme\/library\/gutenberg\/dist\/classes\/Toc.php<\/b> on line <b>116<\/b><br \/>\n<br \/>\n<b>Warning<\/b>:  Undefined array key \"is_category_top\" in <b>\/home\/c7479301\/public_html\/chocottopro.com\/wp-content\/themes\/sango-theme\/library\/gutenberg\/dist\/classes\/Toc.php<\/b> on line <b>121<\/b><br \/>\n<br \/>\n<b>Warning<\/b>:  Undefined array key \"is_top\" in <b>\/home\/c7479301\/public_html\/chocottopro.com\/wp-content\/themes\/sango-theme\/library\/gutenberg\/dist\/classes\/Toc.php<\/b> on line <b>128<\/b><br \/>\n    <div id=\"toc_container\" class=\"sgb-toc--bullets js-smooth-scroll\" data-dialog-title=\"Table of Contents\">\n      <p class=\"toc_title\">\u76ee\u6b21 <\/p>\n      <ul class=\"toc_list\">  <li class=\"first\">    <a href=\"#i-0\">reportlab\u3068\u306f\uff1fPython\u3067\u306e\u5229\u7528\u30e1\u30ea\u30c3\u30c8\u3092\u89e3\u8aac<\/a>    <ul class=\"menu_level_1\">      <li class=\"first\">        <a href=\"#i-1\">reportlab\u306e\u6982\u8981\u3068\u7279\u5fb4<\/a>      <\/li>      <li class=\"last\">        <a href=\"#i-2\">Python\u3067reportlab\u306b\u3088\u308bPDF\u751f\u6210\u306e\u30e1\u30ea\u30c3\u30c8<\/a>      <\/li>    <\/ul>  <\/li>  <li>    <a href=\"#i-3\">reportlab\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u65b9\u6cd5<\/a>    <ul class=\"menu_level_1\">      <li class=\"first\">        <a href=\"#i-4\">pip install reportlab\u306e\u5b9f\u884c<\/a>      <\/li>      <li class=\"last\">        <a href=\"#i-5\">\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3068\u57cb\u3081\u8fbc\u307f\u8a2d\u5b9a<\/a>      <\/li>    <\/ul>  <\/li>  <li>    <a href=\"#i-6\">reportlab\u306b\u3088\u308b\u57fa\u672c\u7684\u306aPDF\u751f\u6210\u65b9\u6cd5<\/a>    <ul class=\"menu_level_1\">      <li class=\"first\">        <a href=\"#i-7\">PDF\u30d5\u30a1\u30a4\u30eb\u306e\u4f5c\u6210\u3068\u30da\u30fc\u30b8\u8ffd\u52a0<\/a>      <\/li>      <li>        <a href=\"#i-8\">\u6587\u5b57\u306e\u63cf\u753b(\u30d5\u30a9\u30f3\u30c8\u3001\u30b5\u30a4\u30ba\u3001\u8272\u306e\u6307\u5b9a)<\/a>      <\/li>      <li class=\"last\">        <a href=\"#i-9\">\u753b\u50cf\u306e\u57cb\u3081\u8fbc\u307f\u65b9\u6cd5<\/a>      <\/li>    <\/ul>  <\/li>  <li>    <a href=\"#i-10\">reportlab\u3092\u4f7f\u3063\u305f\u5b9f\u7528\u7684\u306aPDF\u81ea\u52d5\u751f\u6210Tips<\/a>    <ul class=\"menu_level_1\">      <li class=\"first\">        <a href=\"#i-11\">\u30c6\u30fc\u30d6\u30eb\u30c7\u30fc\u30bf\u306e\u57cb\u3081\u8fbc\u307f\u65b9\u6cd5<\/a>      <\/li>      <li>        <a href=\"#i-12\">\u30da\u30fc\u30b8\u756a\u53f7\u3084\u76ee\u6b21\u306e\u81ea\u52d5\u8ffd\u52a0<\/a>      <\/li>      <li class=\"last\">        <a href=\"#i-13\">\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u6d3b\u7528\u306b\u3088\u308bPDF\u751f\u6210\u306e\u52b9\u7387\u5316<\/a>      <\/li>    <\/ul>  <\/li>  <li>    <a href=\"#i-14\">reportlab\u306e\u3055\u3089\u306b\u9ad8\u5ea6\u306a\u6a5f\u80fd\u306e\u7d39\u4ecb<\/a>    <ul class=\"menu_level_1\">      <li class=\"first\">        <a href=\"#i-15\">\u30b0\u30e9\u30d5\u30fb\u30c1\u30e3\u30fc\u30c8\u306e\u63cf\u753b\u65b9\u6cd5<\/a>      <\/li>      <li class=\"last\">        <a href=\"#i-16\">\u6697\u53f7\u5316\u3084\u30d1\u30b9\u30ef\u30fc\u30c9\u4fdd\u8b77\u3067\u306e\u9ad8\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3PDF\u751f\u6210<\/a>      <\/li>    <\/ul>  <\/li>  <li>    <a href=\"#i-17\">\u307e\u3068\u3081\uff1areportlab\u3092\u4f7f\u3044\u3053\u306a\u3057\u3066PDF\u81ea\u52d5\u751f\u6210\u3092\u52b9\u7387\u5316\u3057\u3088\u3046\uff01<\/a>  <\/li>  <li class=\"last\">    <a href=\"#i-18\">\u95a2\u9023\u30ea\u30f3\u30af<\/a>    <ul class=\"menu_level_1\">      <li class=\"first\">        <a href=\"#i-19\">\u516c\u5f0f\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8<\/a>      <\/li>      <li class=\"last\">        <a href=\"#i-20\">pypdf2<\/a>      <\/li>    <\/ul>  <\/li><\/ul>\n      \n    <\/div><\/div><h2 class=\"wp-block-heading\" id=\"i-0\">reportlab\u3068\u306f\uff1fPython\u3067\u306e\u5229\u7528\u30e1\u30ea\u30c3\u30c8\u3092\u89e3\u8aac<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Python\u3067PDF\u5e33\u7968\u3092\u81ea\u52d5\u751f\u6210\u3057\u305f\u3044\u3001\u305d\u3093\u306a\u8981\u671b\u306b\u304a\u5fdc\u3048\u3059\u308b\u306e\u304creportlab\u3067\u3059\u3002reportlab\u306f\u3001Python\u3067\u6700\u3082\u5e83\u304f\u4f7f\u308f\u308c\u3066\u3044\u308bPDF\u751f\u6210\u30e9\u30a4\u30d6\u30e9\u30ea\u306e1\u3064\u3067\u3001\u8c4a\u5bcc\u306a\u6a5f\u80fd\u3068\u9ad8\u3044\u67d4\u8edf\u6027\u3092\u517c\u306d\u5099\u3048\u3066\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-1\">reportlab\u306e\u6982\u8981\u3068\u7279\u5fb4<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">reportlab\u306f\u3001PDF\u30d5\u30a1\u30a4\u30eb\u306e\u65b0\u898f\u4f5c\u6210\u306f\u3082\u3061\u308d\u3093\u3001\u65e2\u5b58PDF\u306e\u8aad\u307f\u8fbc\u307f\u3084\u7de8\u96c6\u3082\u30b5\u30dd\u30fc\u30c8\u3057\u3066\u3044\u307e\u3059\u3002\u30c6\u30ad\u30b9\u30c8\u3001\u56f3\u5f62\u3001\u753b\u50cf\u306a\u3069\u3092\u81ea\u5728\u306bPDF\u4e0a\u306b\u63cf\u753b\u3067\u304d\u308b\u307b\u304b\u3001TrueType\u3084OpenType\u306a\u3069\u591a\u69d8\u306a\u30d5\u30a9\u30f3\u30c8\u5f62\u5f0f\u306b\u5bfe\u5fdc\u3002\u6bb5\u7d44\u307f\u3084\u30c6\u30fc\u30d6\u30eb\u3001\u30ea\u30b9\u30c8\u3068\u3044\u3063\u305f\u30ec\u30a4\u30a2\u30a6\u30c8\u6a5f\u80fd\u3082\u5145\u5b9f\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u3055\u3089\u306b\u30b0\u30e9\u30d5\u3001\u30c1\u30e3\u30fc\u30c8\u3001\u30d0\u30fc\u30b3\u30fc\u30c9\u306e\u751f\u6210\u6a5f\u80fd\u3092\u6a19\u6e96\u3067\u5099\u3048\u3066\u3044\u308b\u306e\u3082reportlab\u306e\u5927\u304d\u306a\u7279\u9577\u3067\u3059\u3002\u307e\u305f\u3001PDF\/A\u3084\u6697\u53f7\u5316\u306a\u3069\u3001PDF\u306e\u9ad8\u5ea6\u306a\u6a5f\u80fd\u3082\u30b5\u30dd\u30fc\u30c8\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-2\">Python\u3067reportlab\u306b\u3088\u308bPDF\u751f\u6210\u306e\u30e1\u30ea\u30c3\u30c8<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">reportlab\u3092\u4f7f\u3048\u3070\u3001\u624b\u4f5c\u696d\u3067\u306ePDF\u4f5c\u6210\u304b\u3089\u958b\u653e\u3055\u308c\u3001\u696d\u52d9\u306e\u81ea\u52d5\u5316\u30fb\u52b9\u7387\u5316\u304c\u53ef\u80fd\u306b\u306a\u308a\u307e\u3059\u3002\u30d7\u30ed\u30b0\u30e9\u30e0\u306b\u3088\u308b\u67d4\u8edf\u306a\u5236\u5fa1\u3067\u3001\u30cb\u30fc\u30ba\u306b\u5408\u3063\u305fPDF\u3092\u751f\u6210\u3067\u304d\u308b\u306e\u3082\u5927\u304d\u306a\u30e1\u30ea\u30c3\u30c8\u3067\u3059\u3002Python\u7d4c\u9a13\u8005\u306a\u3089\u6bd4\u8f03\u7684\u5bb9\u6613\u306b\u7fd2\u5f97\u30fb\u6d3b\u7528\u3067\u304d\u308b\u306e\u3082\u9b45\u529b\u3068\u8a00\u3048\u308b\u3067\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u306f\u3001reportlab\u3092\u4f7f\u3063\u305f\u30b7\u30f3\u30d7\u30eb\u306aPDF\u751f\u6210\u306e\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.pdfgen import canvas\n\n# PDF\u30d5\u30a1\u30a4\u30eb\u3092\u65b0\u898f\u4f5c\u6210\nc = canvas.Canvas(\"sample.pdf\")\n\n# \u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\nc.drawString(100, 700, \"Hello, World!\")\n\n\n# \u30da\u30fc\u30b8\u3092\u78ba\u5b9a\u3057\u3001PDF\u30d5\u30a1\u30a4\u30eb\u3092\u4fdd\u5b58\nc.showPage()\nc.save()<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"590\" src=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06-1024x590.png\" alt=\"\" class=\"wp-image-870\" srcset=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06-1024x590.png 1024w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06-300x173.png 300w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06-768x442.png 768w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06-1536x884.png 1536w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06-940x541.png 940w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06-520x300.png 520w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.38.06.png 1966w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\"><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">\u5fc5\u8981\u306a\u30d5\u30a9\u30f3\u30c8\u30b5\u30a4\u30ba\u3084\u5ea7\u6a19\u3001\u753b\u50cf\u306e\u30b5\u30a4\u30ba\u3092\u6307\u5b9a\u3059\u308b\u3060\u3051\u3067\u3001\u76ee\u7684\u306e\u30ec\u30a4\u30a2\u30a6\u30c8\u304c\u5b9f\u73fe\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">reportlab\u306f\u65e5\u672c\u8a9e\u306b\u3082\u5bfe\u5fdc\u3057\u3066\u3044\u307e\u3059\u3002\u305f\u3060\u3057\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u30d5\u30a9\u30f3\u30c8\u306b\u306f\u65e5\u672c\u8a9e\u30b0\u30ea\u30d5\u304c\u542b\u307e\u308c\u306a\u3044\u305f\u3081\u3001\u65e5\u672c\u8a9e\u5bfe\u5fdc\u30d5\u30a9\u30f3\u30c8(IPA\u30d5\u30a9\u30f3\u30c8\u306a\u3069)\u3092\u7528\u610f\u3057\u3001PDF\u306b\u57cb\u3081\u8fbc\u3080\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u3053\u306e\u3088\u3046\u306b\u3001reportlab\u306fPython\u3067\u306ePDF\u751f\u6210\u306b\u5e45\u5e83\u304f\u6d3b\u7528\u3067\u304d\u308b\u30e9\u30a4\u30d6\u30e9\u30ea\u3067\u3059\u3002\u305d\u308c\u3067\u306f\u3001\u307e\u305a\u306freportlab\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u304b\u3089\u898b\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"i-3\">reportlab\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u65b9\u6cd5<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u305d\u308c\u3067\u306f\u3001reportlab\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u3092\u898b\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002reportlab\u306f\u3001\u4ee5\u4e0b\u306epip\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3059\u308b\u3053\u3068\u3067\u7c21\u5358\u306b\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-4\">pip install reportlab\u306e\u5b9f\u884c<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">pip install reportlab<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">reportlab\u306f\u3001Python 2.7\u4ee5\u964d\u3001\u307e\u305f\u306f3.5\u4ee5\u964d\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u3067\u52d5\u4f5c\u3057\u307e\u3059\u304c\u3001\u7279\u306bPython 3.7\u4ee5\u964d\u3092\u63a8\u5968\u3068\u306e\u3053\u3068\u3067\u3059\u3002\u304a\u4f7f\u3044\u306ePython\u74b0\u5883\u306b\u5408\u308f\u305b\u3066\u3001\u9069\u5207\u306a\u30d0\u30fc\u30b8\u30e7\u30f3\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u307e\u305f\u3001\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u6642\u306b\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u30a8\u30e9\u30fc\u304c\u767a\u751f\u3059\u308b\u5834\u5408\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>pip\u30b3\u30de\u30f3\u30c9\u3092\u8a8d\u8b58\u3067\u304d\u306a\u3044\u2192Python\u306ePath\u304c\u901a\u3063\u3066\u3044\u308b\u304b\u3092\u78ba\u8a8d\u3057\u307e\u3057\u3087\u3046\u3002<\/li>\n\n\n\n<li>Pillow(PIL)\u30e2\u30b8\u30e5\u30fc\u30eb\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u30a8\u30e9\u30fc\u2192\u5225\u9014Pillow\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-5\">\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3068\u57cb\u3081\u8fbc\u307f\u8a2d\u5b9a<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">reportlab\u3067\u306f\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u306f\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u304c\u542b\u307e\u308c\u3066\u3044\u307e\u305b\u3093\u3002\u65e5\u672c\u8a9e\u3092\u6271\u3046\u5834\u5408\u306f\u3001\u4ee5\u4e0b\u306e\u624b\u9806\u3067\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3001PDF\u306b\u57cb\u3081\u8fbc\u3080\u8a2d\u5b9a\u3092\u884c\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>IPA\u30d5\u30a9\u30f3\u30c8\u306a\u3069\u306e\u65e5\u672c\u8a9e\u5bfe\u5fdc\u30d5\u30a9\u30f3\u30c8\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3001\u4efb\u610f\u306e\u30d5\u30a9\u30eb\u30c0\u306b\u914d\u7f6e\u3057\u307e\u3059\u3002<\/li>\n\n\n\n<li>\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u30b3\u30fc\u30c9\u3067\u30d5\u30a9\u30f3\u30c8\u3092\u767b\u9332\u3057\u3001PDF\u306b\u57cb\u3081\u8fbc\u307f\u307e\u3059\u3002<\/li>\n<\/ol>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.pdfbase import pdfmetrics\nfrom reportlab.pdfbase.ttfonts import TTFont\n\n# \u30d5\u30a9\u30f3\u30c8\u3092\u767b\u9332\npdfmetrics.registerFont(TTFont('IPAGothic', 'ipaexg.ttf'))\n\n# \u30d5\u30a9\u30f3\u30c8\u3092\u6307\u5b9a\u3057\u3066\u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\nc.setFont('IPAGothic', 12)\nc.drawString(100, 500, '\u3053\u308c\u306f\u65e5\u672c\u8a9e\u30c6\u30ad\u30b9\u30c8\u306e\u4f8b\u3067\u3059\u3002')<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u3053\u3053\u3067\u306f\u3001IPA\u30b4\u30b7\u30c3\u30af\u30d5\u30a9\u30f3\u30c8\u3092\u4f8b\u306b\u8aac\u660e\u3057\u307e\u3057\u305f\u304c\u3001\u4ed6\u306e\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u3067\u3082\u540c\u69d8\u306e\u624b\u9806\u3067\u8a2d\u5b9a\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u306f\u3001\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u306e\u57cb\u3081\u8fbc\u307f\u8a2d\u5b9a\u3092\u542b\u3080\u3001\u3088\u308a\u8a73\u7d30\u306areportlab\u306e\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.pdfgen import canvas\nfrom reportlab.pdfbase import pdfmetrics\nfrom reportlab.pdfbase.ttfonts import TTFont\nfrom reportlab.lib.pagesizes import A4, portrait\nfrom reportlab.lib.units import mm\n\n# \u30d5\u30a9\u30f3\u30c8\u3092\u767b\u9332\npdfmetrics.registerFont(TTFont('IPAGothic', 'ipaexg.ttf'))\n\n# PDF\u3092\u65b0\u898f\u4f5c\u6210\u3002\u7528\u7d19\u30b5\u30a4\u30ba\u3092\u6307\u5b9a\nc = canvas.Canvas(\"japanese_sample.pdf\", pagesize=portrait(A4))\n\n# \u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u3092\u6307\u5b9a\u3057\u3066\u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\nc.setFont('IPAGothic', 12)\nc.drawString(50*mm, 270*mm, '\u3053\u308c\u306f\u65e5\u672c\u8a9e\u306b\u3088\u308b\u63cf\u753b\u306e\u30c6\u30b9\u30c8\u3067\u3059\u3002')\nc.drawString(50*mm, 260*mm, '\u30d5\u30a9\u30f3\u30c8\u30b5\u30a4\u30ba\u3092\u5909\u66f4\u3057\u305f\u308a\u3001')\n\nc.setFont('IPAGothic', 16)\nc.drawString(50*mm, 250*mm, '\u4f4d\u7f6e\u3092\u8abf\u6574\u3059\u308b\u306e\u3082\u81ea\u5728\u3067\u3059\u3002')\n\n# \u30da\u30fc\u30b8\u3092\u78ba\u5b9a\u3057\u3001PDF\u30d5\u30a1\u30a4\u30eb\u3092\u4fdd\u5b58\nc.showPage()\nc.save()<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"646\" src=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.40.56-1024x646.png\" alt=\"\" class=\"wp-image-871\" srcset=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.40.56-1024x646.png 1024w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.40.56-300x189.png 300w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.40.56-768x484.png 768w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.40.56-1536x968.png 1536w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.40.56-940x593.png 940w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.40.56.png 1640w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\"><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">\u30d5\u30a9\u30f3\u30c8\u30d5\u30a1\u30a4\u30eb\u304c\u898b\u3064\u304b\u3089\u306a\u3044\u30a8\u30e9\u30fc\u304c\u767a\u751f\u3059\u308b\u5834\u5408\u306f\u3001\u30d5\u30a9\u30f3\u30c8\u30d5\u30a1\u30a4\u30eb\u306e\u30d1\u30b9\u304c\u6b63\u3057\u3044\u304b\u3092\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0a\u3067\u3001reportlab\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3068\u65e5\u672c\u8a9e\u30d5\u30a9\u30f3\u30c8\u306e\u8a2d\u5b9a\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306e\u89e3\u8aac\u306f\u7d42\u308f\u308a\u3067\u3059\u3002\u6b21\u306f\u3001reportlab\u3092\u4f7f\u3063\u305f\u57fa\u672c\u7684\u306aPDF\u751f\u6210\u65b9\u6cd5\u306b\u3064\u3044\u3066\u898b\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"i-6\">reportlab\u306b\u3088\u308b\u57fa\u672c\u7684\u306aPDF\u751f\u6210\u65b9\u6cd5<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u304c\u5b8c\u4e86\u3057\u305f\u3089\u3001\u65e9\u901freportlab\u3092\u4f7f\u3063\u3066PDF\u30d5\u30a1\u30a4\u30eb\u3092\u751f\u6210\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002\u3053\u3053\u3067\u306f\u3001PDF\u30d5\u30a1\u30a4\u30eb\u306e\u65b0\u898f\u4f5c\u6210\u3001\u30c6\u30ad\u30b9\u30c8\u306e\u63cf\u753b\u3001\u753b\u50cf\u306e\u57cb\u3081\u8fbc\u307f\u306b\u3064\u3044\u3066\u89e3\u8aac\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-7\">PDF\u30d5\u30a1\u30a4\u30eb\u306e\u4f5c\u6210\u3068\u30da\u30fc\u30b8\u8ffd\u52a0<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">PDF\u30d5\u30a1\u30a4\u30eb\u3092\u65b0\u898f\u4f5c\u6210\u3059\u308b\u306b\u306f\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306b<code>Canvas<\/code>\u30af\u30e9\u30b9\u306e\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u306b\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.pdfgen import canvas\n\n# PDF\u30d5\u30a1\u30a4\u30eb\u3092\u65b0\u898f\u4f5c\u6210\nc = canvas.Canvas(\"sample.pdf\")\n\n# \u30da\u30fc\u30b8\u3092\u8ffd\u52a0\nc.showPage()\nc.save()<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>showPage<\/code>\u30e1\u30bd\u30c3\u30c9\u3067\u30da\u30fc\u30b8\u3092\u78ba\u5b9a\u3057\u3001<code>save<\/code>\u30e1\u30bd\u30c3\u30c9\u3067PDF\u30d5\u30a1\u30a4\u30eb\u3092\u4fdd\u5b58\u3057\u307e\u3059\u3002\u3053\u308c\u3060\u3051\u3067\u3001\u7a7a\u306ePDF\u30d5\u30a1\u30a4\u30eb\u304c\u751f\u6210\u3055\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-8\">\u6587\u5b57\u306e\u63cf\u753b(\u30d5\u30a9\u30f3\u30c8\u3001\u30b5\u30a4\u30ba\u3001\u8272\u306e\u6307\u5b9a)<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">PDF\u306b\u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\u3059\u308b\u306b\u306f\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\"># \u30d5\u30a9\u30f3\u30c8\u3068\u30b5\u30a4\u30ba\u3092\u6307\u5b9a\nc.setFont(\"Helvetica\", 20)\n\n# \u63cf\u753b\u4f4d\u7f6e\u3092\u6307\u5b9a\u3057\u3066\u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\nc.drawString(100, 700, \"Hello, World!\")\n\n# \u8272\u3092\u6307\u5b9a\u3057\u3066\u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\nc.setFillColorRGB(1, 0, 0)  # \u8d64\u8272\nc.drawString(100, 650, \"This is red text.\")<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>setFont<\/code>\u30e1\u30bd\u30c3\u30c9\u3067\u30d5\u30a9\u30f3\u30c8\u3068\u30b5\u30a4\u30ba\u3092\u6307\u5b9a\u3057\u3001<code>drawString<\/code>\u30e1\u30bd\u30c3\u30c9\u3067\u63cf\u753b\u4f4d\u7f6e\u3068\u30c6\u30ad\u30b9\u30c8\u5185\u5bb9\u3092\u6307\u5b9a\u3057\u3066\u63cf\u753b\u3057\u307e\u3059\u3002\u8272\u3092\u6307\u5b9a\u3059\u308b\u5834\u5408\u306f\u3001<code>setFillColorRGB<\/code>\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-9\">\u753b\u50cf\u306e\u57cb\u3081\u8fbc\u307f\u65b9\u6cd5<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">\u753b\u50cf\u3092\u57cb\u3081\u8fbc\u3080\u306b\u306f\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306b<code>drawImage<\/code>\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\"># \u753b\u50cf\u3092\u63cf\u753b\nc.drawImage(\"python-logo.png\", 100, 500, width=100, height=100)<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u753b\u50cf\u30d5\u30a1\u30a4\u30eb\u540d\u3001\u63cf\u753b\u4f4d\u7f6e\u3001\u30b5\u30a4\u30ba\u3092\u6307\u5b9a\u3059\u308b\u3053\u3068\u3067\u3001PDF\u306b\u753b\u50cf\u3092\u57cb\u3081\u8fbc\u3080\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0b\u306f\u3001\u3053\u308c\u3089\u3092\u7d44\u307f\u5408\u308f\u305b\u305f\u57fa\u672c\u7684\u306aPDF\u751f\u6210\u306e\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.pdfgen import canvas\n\n# PDF\u30d5\u30a1\u30a4\u30eb\u3092\u65b0\u898f\u4f5c\u6210\nc = canvas.Canvas(\"sample.pdf\")\n\n# \u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\nc.setFont(\"Helvetica\", 20)\nc.drawString(100, 700, \"Hello, World!\")\n\n# \u8272\u3092\u6307\u5b9a\u3057\u3066\u30c6\u30ad\u30b9\u30c8\u3092\u63cf\u753b\nc.setFillColorRGB(1, 0, 0)\nc.drawString(100, 650, \"This is red text.\")\n\n# \u753b\u50cf\u3092\u63cf\u753b\nc.drawImage(\"python-logo.png\", 100, 500, width=100, height=100)\n\n# \u30da\u30fc\u30b8\u3092\u78ba\u5b9a\u3057\u3001PDF\u30d5\u30a1\u30a4\u30eb\u3092\u4fdd\u5b58\nc.showPage()\nc.save()<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u3053\u306e\u30b3\u30fc\u30c9\u3092\u5b9f\u884c\u3059\u308b\u3068\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306aPDF\u30d5\u30a1\u30a4\u30eb\u304c\u751f\u6210\u3055\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u201cHello, World!\u201d\u3068\u3044\u3046\u30c6\u30ad\u30b9\u30c8\u304c\u63cf\u753b\u3055\u308c\u3066\u3044\u308b\u3002<\/li>\n\n\n\n<li>\u201cThis is red text.\u201d\u3068\u3044\u3046\u8d64\u8272\u306e\u30c6\u30ad\u30b9\u30c8\u304c\u63cf\u753b\u3055\u308c\u3066\u3044\u308b\u3002<\/li>\n\n\n\n<li>Python logo\u306e\u753b\u50cf\u304c\u6307\u5b9a\u306e\u30b5\u30a4\u30ba\u3067\u57cb\u3081\u8fbc\u307e\u308c\u3066\u3044\u308b\u3002<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0a\u304c\u3001reportlab\u3092\u4f7f\u3063\u305f\u57fa\u672c\u7684\u306aPDF\u751f\u6210\u65b9\u6cd5\u3067\u3059\u3002\u30c6\u30ad\u30b9\u30c8\u3084\u753b\u50cf\u306e\u914d\u7f6e\u3092\u8abf\u6574\u3059\u308b\u3053\u3068\u3067\u3001\u3088\u308a\u8907\u96d1\u306a\u30ec\u30a4\u30a2\u30a6\u30c8\u3082\u5b9f\u73fe\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b21\u306f\u3001reportlab\u3092\u4f7f\u3063\u305f\u5b9f\u7528\u7684\u306aPDF\u81ea\u52d5\u751f\u6210\u306eTips\u3092\u898b\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"i-10\">reportlab\u3092\u4f7f\u3063\u305f\u5b9f\u7528\u7684\u306aPDF\u81ea\u52d5\u751f\u6210Tips<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">reportlab\u3092\u4f7f\u3048\u3070\u3001\u3088\u308a\u5b9f\u7528\u7684\u306aPDF\u306e\u81ea\u52d5\u751f\u6210\u304c\u53ef\u80fd\u3067\u3059\u3002\u3053\u3053\u3067\u306f\u3001\u30c6\u30fc\u30d6\u30eb\u30c7\u30fc\u30bf\u306e\u57cb\u3081\u8fbc\u307f\u3001\u30da\u30fc\u30b8\u756a\u53f7\u306e\u81ea\u52d5\u8ffd\u52a0\u3001\u76ee\u6b21\u306e\u81ea\u52d5\u751f\u6210\u3001\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u6d3b\u7528\u3068\u3044\u3063\u305fTips\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-11\">\u30c6\u30fc\u30d6\u30eb\u30c7\u30fc\u30bf\u306e\u57cb\u3081\u8fbc\u307f\u65b9\u6cd5<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><code>Table<\/code>\u30af\u30e9\u30b9\u3092\u4f7f\u3046\u3053\u3068\u3067\u3001PDF\u306b\u30c6\u30fc\u30d6\u30eb\u3092\u57cb\u3081\u8fbc\u3080\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u4ee5\u4e0b\u306f\u3001\u30c6\u30fc\u30d6\u30eb\u30c7\u30fc\u30bf\u3092\u57cb\u3081\u8fbc\u3080\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.lib import colors\nfrom reportlab.lib.pagesizes import A4\nfrom reportlab.platypus import SimpleDocTemplate, Table, TableStyle\n\n# \u30c6\u30fc\u30d6\u30eb\u30c7\u30fc\u30bf\u3092\u6e96\u5099\ndata = [\n    ['\u5546\u54c1\u540d', '\u4fa1\u683c', '\u5728\u5eab'],\n    ['\u5546\u54c1A', '1000\u5186', '100\u500b'],\n    ['\u5546\u54c1B', '2000\u5186', '50\u500b'],\n    ['\u5546\u54c1C', '3000\u5186', '30\u500b'],\n]\n\n# \u30c6\u30fc\u30d6\u30eb\u30b9\u30bf\u30a4\u30eb\u3092\u8a2d\u5b9a\nstyle = TableStyle([\n    ('BACKGROUND', (0, 0), (-1, 0), colors.grey),\n    ('TEXTCOLOR', (0, 0), (-1, 0), colors.whitesmoke),\n    ('ALIGN', (0, 0), (-1, -1), 'CENTER'),\n    ('FONTNAME', (0, 0), (-1, 0), 'Helvetica-Bold'),\n    ('FONTSIZE', (0, 0), (-1, 0), 14),\n    ('BOTTOMPADDING', (0, 0), (-1, 0), 12),\n    ('BACKGROUND', (0, 1), (-1, -1), colors.beige),\n    ('TEXTCOLOR', (0, 1), (-1, -1), colors.black),\n    ('ALIGN', (0, 1), (-1, -1), 'LEFT'),\n    ('FONTNAME', (0, 1), (-1, -1), 'Helvetica'),\n    ('FONTSIZE', (0, 1), (-1, -1), 12),\n    ('TOPPADDING', (0, 1), (-1, -1), 6),\n    ('BOTTOMPADDING', (0, 1), (-1, -1), 6),\n    ('GRID', (0, 0), (-1, -1), 1, colors.black),\n])\n\n# PDF\u3092\u751f\u6210\ndef generate_pdf(filename, data):\n    pdf = SimpleDocTemplate(filename, pagesize=A4)\n    table = Table(data)\n    table.setStyle(style)\n    pdf.build([table])\n\ngenerate_pdf(\"table.pdf\", data)<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>TableStyle<\/code>\u30af\u30e9\u30b9\u3092\u4f7f\u3063\u3066\u30c6\u30fc\u30d6\u30eb\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u8a73\u7d30\u306b\u8a2d\u5b9a\u3067\u304d\u308b\u306e\u304c\u7279\u5fb4\u3067\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-12\">\u30da\u30fc\u30b8\u756a\u53f7\u3084\u76ee\u6b21\u306e\u81ea\u52d5\u8ffd\u52a0<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">\u30da\u30fc\u30b8\u756a\u53f7\u306f\u3001<code>Canvas<\/code>\u30af\u30e9\u30b9\u306e<code>drawPageNumber<\/code>\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u3063\u3066\u81ea\u52d5\u7684\u306b\u8ffd\u52a0\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.lib.pagesizes import A4\nfrom reportlab.pdfgen import canvas\n\ndef generate_pdf(filename):\n    pdf = canvas.Canvas(filename, pagesize=A4)\n\n    # \u30da\u30fc\u30b8\u6570\u3092\u53d6\u5f97\n    page_count = pdf.getPageNumber()\n\n    for i in range(1, page_count + 1):\n        # \u30da\u30fc\u30b8\u756a\u53f7\u3092\u63cf\u753b\n        pdf.drawPageNumber(550, 20, i, page_count)\n\n        # \u6539\u30da\u30fc\u30b8\n        pdf.showPage()\n\n    pdf.save()\n\ngenerate_pdf(\"page_numbers.pdf\")<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u76ee\u6b21\u306f\u3001<code>Paragraph<\/code>\u30af\u30e9\u30b9\u3068<code>PageBreak<\/code>\u30af\u30e9\u30b9\u3092\u4f7f\u3063\u3066\u81ea\u52d5\u751f\u6210\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.lib.pagesizes import A4\nfrom reportlab.platypus import SimpleDocTemplate, Paragraph, PageBreak\nfrom reportlab.lib.styles import getSampleStyleSheet\n\ndef generate_pdf(filename, toc_data):\n    pdf = SimpleDocTemplate(filename, pagesize=A4)\n    styles = getSampleStyleSheet()\n\n    story = []\n\n    # \u76ee\u6b21\u3092\u8ffd\u52a0\n    story.append(Paragraph(\"\u76ee\u6b21\", styles[\"Heading1\"]))\n    for chapter, page in toc_data:\n        story.append(Paragraph(f\"{chapter}\u30fb\u30fb\u30fb{page}\", styles[\"Normal\"]))\n    story.append(PageBreak())\n\n    # \u672c\u6587\u3092\u8ffd\u52a0\n    for chapter, page in toc_data:\n        story.append(Paragraph(chapter, styles[\"Heading2\"]))\n        story.append(Paragraph(\"\u672c\u6587\u306e\u30b5\u30f3\u30d7\u30eb\u30c6\u30ad\u30b9\u30c8\u3067\u3059\u3002\" * 20, styles[\"Normal\"]))\n        story.append(PageBreak())\n\n    pdf.build(story)\n\ntoc_data = [\n    (\"\u7b2c1\u7ae0 \u306f\u3058\u3081\u306b\", 1),\n    (\"\u7b2c2\u7ae0 \u672c\u8ad6\", 2),\n    (\"\u7b2c3\u7ae0 \u7d50\u8ad6\", 4),\n]\n\ngenerate_pdf(\"toc.pdf\", toc_data)<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-13\">\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u6d3b\u7528\u306b\u3088\u308bPDF\u751f\u6210\u306e\u52b9\u7387\u5316<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">\u5b9a\u578b\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u306ePDF\u3092\u5927\u91cf\u306b\u751f\u6210\u3059\u308b\u5834\u5408\u3001\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u6d3b\u7528\u3059\u308b\u3053\u3068\u3067\u52b9\u7387\u5316\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.lib.pagesizes import A4\nfrom reportlab.platypus import SimpleDocTemplate, Paragraph\nfrom reportlab.lib.styles import getSampleStyleSheet\n\ndef generate_pdf(filename, template_data):\n    pdf = SimpleDocTemplate(filename, pagesize=A4)\n    styles = getSampleStyleSheet()\n\n    story = []\n\n    # \u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u9069\u7528\n    for text in template_data:\n        story.append(Paragraph(text, styles[\"Normal\"]))\n\n    pdf.build(story)\n\ntemplate_data = [\n    \"\u3053\u308c\u306f\u5831\u544a\u66f8\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3067\u3059\u3002\",\n    \"\u4ee5\u4e0b\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3092\u8a18\u5165\u3057\u3066\u304f\u3060\u3055\u3044\u3002\",\n    \"1. \u306f\u3058\u3081\u306b\",\n    \"2. \u8abf\u67fb\u65b9\u6cd5\",\n    \"3. \u7d50\u679c\", \n    \"4. \u8003\u5bdf\",\n    \"5. \u7d50\u8ad6\",\n]\n\ngenerate_pdf(\"template.pdf\", template_data)<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3068\u306a\u308b\u30c6\u30ad\u30b9\u30c8\u30c7\u30fc\u30bf\u3092\u7528\u610f\u3057\u3001\u305d\u308c\u3092\u5143\u306bPDF\u3092\u751f\u6210\u3059\u308b\u3060\u3051\u306a\u306e\u3067\u3001\u975e\u5e38\u306b\u7c21\u6f54\u306b\u8a18\u8ff0\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0a\u306e\u3088\u3046\u306b\u3001reportlab\u306b\u306f\u5b9f\u7528\u7684\u306aPDF\u751f\u6210\u306b\u5f79\u7acb\u3064\u69d8\u3005\u306a\u6a5f\u80fd\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u4ed6\u306ePDF\u30e9\u30a4\u30d6\u30e9\u30ea\u3068\u6bd4\u3079\u3066\u3082\u3001\u30ec\u30a4\u30a2\u30a6\u30c8\u306e\u67d4\u8edf\u6027\u3084\u51fa\u529b\u306e\u7f8e\u3057\u3055\u306f\u7279\u306b\u512a\u308c\u3066\u3044\u308b\u3067\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u305f\u3060\u3057\u3001\u4e00\u65b9\u3067reportlab\u306f\u30ed\u30fc\u30ec\u30d9\u30eb\u306a\u30e9\u30a4\u30d6\u30e9\u30ea\u306a\u306e\u3067\u3001\u591a\u5c11\u306ePython\u30b9\u30ad\u30eb\u306f\u5fc5\u8981\u306b\u306a\u308a\u307e\u3059\u3002\u3088\u308a\u7c21\u6613\u306b\u5229\u7528\u3057\u305f\u3044\u5834\u5408\u306f\u3001reportlab\u3092\u30e9\u30c3\u30d7\u3057\u305f\u3082\u306e\u3084\u3001\u4ed6\u306e\u30cf\u30a4\u30ec\u30d9\u30eb\u306aPDF\u30e9\u30a4\u30d6\u30e9\u30ea\u306e\u5229\u7528\u3082\u691c\u8a0e\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6b21\u306f\u3001reportlab\u306e\u3055\u3089\u306b\u9ad8\u5ea6\u306a\u6a5f\u80fd\u306b\u3064\u3044\u3066\u898b\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"i-14\">reportlab\u306e\u3055\u3089\u306b\u9ad8\u5ea6\u306a\u6a5f\u80fd\u306e\u7d39\u4ecb<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u3053\u3053\u307e\u3067\u306f\u3001reportlab\u306e\u57fa\u672c\u7684\u306a\u4f7f\u3044\u65b9\u3084\u5b9f\u7528\u7684\u306aTips\u3092\u898b\u3066\u304d\u307e\u3057\u305f\u3002\u6700\u5f8c\u306b\u3001reportlab\u306e\u3055\u3089\u306b\u9ad8\u5ea6\u306a\u6a5f\u80fd\u306b\u3064\u3044\u3066\u7d39\u4ecb\u3057\u307e\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-15\">\u30b0\u30e9\u30d5\u30fb\u30c1\u30e3\u30fc\u30c8\u306e\u63cf\u753b\u65b9\u6cd5<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">reportlab\u306e<code>graphics<\/code>\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u4f7f\u3046\u3068\u3001\u69d8\u3005\u306a\u30b0\u30e9\u30d5\u3084\u30c1\u30e3\u30fc\u30c8\u3092\u63cf\u753b\u3067\u304d\u307e\u3059\u3002\u4ee5\u4e0b\u306f\u3001\u68d2\u30b0\u30e9\u30d5\u3092\u63cf\u753b\u3059\u308b\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.graphics.shapes import Drawing\nfrom reportlab.graphics.charts.barcharts import VerticalBarChart\nfrom reportlab.lib.pagesizes import A4\nfrom reportlab.graphics import renderPDF\n\ndata = [\n    (2010, 1000, 1500),\n    (2011, 1500, 1800),\n    (2012, 1800, 2000),\n    (2013, 2000, 2500),\n]\n\ndrawing = Drawing(400, 200)\n\nchart = VerticalBarChart()\nchart.x = 50\nchart.y = 50\nchart.width = 300\nchart.height = 125\nchart.data = data\n\nchart.valueAxis.valueMin = 0\nchart.valueAxis.valueMax = 3000\nchart.valueAxis.valueStep = 500\n\nchart.categoryAxis.labels.boxAnchor = 'ne'\nchart.categoryAxis.labels.dx = 8\nchart.categoryAxis.labels.dy = -2\nchart.categoryAxis.labels.angle = 30\n\ndrawing.add(chart)\n\nrenderPDF.drawToFile(drawing, \"barchart.pdf\", \"Bar Chart Example\")<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"659\" src=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.44.02-1024x659.png\" alt=\"\" class=\"wp-image-872\" srcset=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.44.02-1024x659.png 1024w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.44.02-300x193.png 300w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.44.02-768x494.png 768w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.44.02-1536x988.png 1536w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.44.02-940x605.png 940w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/06\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2024-06-05-23.44.02.png 1934w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\"><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">\u3053\u306e\u3088\u3046\u306b\u3001<code>VerticalBarChart<\/code>\u30af\u30e9\u30b9\u3092\u4f7f\u3063\u3066\u68d2\u30b0\u30e9\u30d5\u306e\u30d7\u30ed\u30d1\u30c6\u30a3\u3092\u8a2d\u5b9a\u3057\u3001<code>Drawing<\/code>\u30af\u30e9\u30b9\u306b\u8ffd\u52a0\u3059\u308b\u3053\u3068\u3067\u3001PDF\u306b\u30b0\u30e9\u30d5\u3092\u63cf\u753b\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-16\">\u6697\u53f7\u5316\u3084\u30d1\u30b9\u30ef\u30fc\u30c9\u4fdd\u8b77\u3067\u306e\u9ad8\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3PDF\u751f\u6210<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><code>canvas.Canvas<\/code>\u30af\u30e9\u30b9\u306e<code>setEncrypt<\/code>\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u3046\u3068\u3001\u6697\u53f7\u5316\u3084\u30d1\u30b9\u30ef\u30fc\u30c9\u4fdd\u8b77\u3092\u8a2d\u5b9a\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">from reportlab.pdfgen import canvas\nfrom reportlab.lib.pagesizes import A4\n\ndef generate_secured_pdf(filename, password):\n    pdf = canvas.Canvas(filename, pagesize=A4)\n\n    # \u6697\u53f7\u5316\u3068\u30d1\u30b9\u30ef\u30fc\u30c9\u4fdd\u8b77\u3092\u8a2d\u5b9a\n    pdf.setEncrypt(password)\n\n    pdf.drawString(100, 500, \"This is a secured PDF.\")\n    pdf.showPage()\n    pdf.save()\n\ngenerate_secured_pdf(\"secured.pdf\", \"password\")<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u6a5f\u5bc6\u60c5\u5831\u3092\u542b\u3080PDF\u3092\u751f\u6210\u3059\u308b\u5834\u5408\u306a\u3069\u306b\u6d3b\u7528\u3067\u304d\u308b\u3067\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u305d\u306e\u4ed6\u3001reportlab\u306b\u306fPDF\/A\u6e96\u62e0\u306ePDF\u751f\u6210\u3001\u30d5\u30a9\u30fc\u30e0\u306e\u4f5c\u6210\u3068\u51e6\u7406\u3001\u30d0\u30fc\u30b3\u30fc\u30c9\u30fbQR\u30b3\u30fc\u30c9\u306e\u751f\u6210\u3001PDF\u306e\u7d50\u5408\u30fb\u5206\u5272\u3001\u30c6\u30ad\u30b9\u30c8\u62bd\u51fa\u3001\u6ce8\u91c8\u306e\u8ffd\u52a0\u306a\u3069\u3001\u9ad8\u5ea6\u306a\u6a5f\u80fd\u304c\u6570\u591a\u304f\u7528\u610f\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u7528\u9014\u306b\u5fdc\u3058\u3066\u3001\u3053\u308c\u3089\u306e\u6a5f\u80fd\u3092\u7d44\u307f\u5408\u308f\u305b\u308b\u3053\u3068\u3067\u3001\u3088\u308a\u6d17\u7df4\u3055\u308c\u305fPDF\u3092\u751f\u6210\u3059\u308b\u3053\u3068\u304c\u53ef\u80fd\u3067\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"i-17\">\u307e\u3068\u3081\uff1areportlab\u3092\u4f7f\u3044\u3053\u306a\u3057\u3066PDF\u81ea\u52d5\u751f\u6210\u3092\u52b9\u7387\u5316\u3057\u3088\u3046\uff01<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">\u4ee5\u4e0a\u3001reportlab\u3092\u4f7f\u3063\u305fPDF\u81ea\u52d5\u751f\u6210\u306e\u57fa\u672c\u304b\u3089\u5fdc\u7528\u307e\u3067\u3092\u898b\u3066\u304d\u307e\u3057\u305f\u3002reportlab\u306f\u3001Python\u3067\u306e\u672c\u683c\u7684\u306aPDF\u751f\u6210\u3092\u5b9f\u73fe\u3059\u308b\u5f37\u529b\u306a\u30e9\u30a4\u30d6\u30e9\u30ea\u3067\u3059\u3002\u57fa\u672c\u7684\u306a\u4f7f\u3044\u65b9\u3092\u30de\u30b9\u30bf\u30fc\u3059\u308c\u3070\u3001\u9ad8\u54c1\u8cea\u306aPDF\u3092\u7c21\u5358\u306b\u81ea\u52d5\u751f\u6210\u3067\u304d\u308b\u3067\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u5b9f\u969b\u306e\u30d3\u30b8\u30cd\u30b9\u30b7\u30fc\u30f3\u3067\u306f\u3001\u5927\u91cf\u306e\u5e33\u7968\u3084\u30ec\u30dd\u30fc\u30c8\u751f\u6210\u304c\u6c42\u3081\u3089\u308c\u308b\u30b1\u30fc\u30b9\u3082\u591a\u3044\u306f\u305a\u3002\u305d\u3093\u306a\u6642\u306f\u3001\u305c\u3072reportlab\u306e\u51fa\u756a\u3067\u3059\u3002\u672c\u8a18\u4e8b\u3067\u7d39\u4ecb\u3057\u305f\u30c6\u30af\u30cb\u30c3\u30af\u3092\u5fdc\u7528\u3057\u3001\u696d\u52d9\u306e\u81ea\u52d5\u5316\u30fb\u52b9\u7387\u5316\u3092\u56f3\u3063\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u4eca\u56de\u306e\u5185\u5bb9\u3092\u4e00\u901a\u308a\u7406\u89e3\u3057\u305f\u3089\u3001\u6b21\u306e\u30b9\u30c6\u30c3\u30d7\u3068\u3057\u3066\u304a\u3059\u3059\u3081\u306a\u306e\u306f\u3001\u5b9f\u969b\u306e\u696d\u52d9\u3092\u60f3\u5b9a\u3057\u305f\u3001\u3088\u308a\u5b9f\u8df5\u7684\u306aPDF\u306e\u81ea\u52d5\u751f\u6210\u306b\u6311\u6226\u3057\u3066\u307f\u308b\u3053\u3068\u3067\u3059\u3002\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3092\u53c2\u8003\u306b\u3001\u81ea\u793e\u306e\u5e33\u7968\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u306b\u5408\u308f\u305b\u305fPDF\u306e\u81ea\u52d5\u51fa\u529b\u306a\u3069\u306b\u53d6\u308a\u7d44\u3093\u3067\u307f\u308b\u306e\u306f\u3044\u304b\u304c\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u3042\u306a\u305f\u306e\u5275\u610f\u5de5\u592b\u6b21\u7b2c\u3067\u3001reportlab\u306e\u6d3b\u7528\u306e\u5e45\u306f\u3050\u3093\u3068\u5e83\u304c\u308b\u306f\u305a\u3067\u3059\u3002\u305c\u3072\u3001PDF\u81ea\u52d5\u751f\u6210\u306e\u30b9\u30da\u30b7\u30e3\u30ea\u30b9\u30c8\u3092\u76ee\u6307\u3057\u3066\u3001reportlab\u3092\u5b58\u5206\u306b\u4f7f\u3044\u3053\u306a\u3057\u3066\u304f\u3060\u3055\u3044\uff01<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"i-18\">\u95a2\u9023\u30ea\u30f3\u30af<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-19\">\u516c\u5f0f\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8<\/h3>\n\n\n\n<div class=\"wp-block-sgb-sanko\"><a href=\"https:\/\/docs.reportlab.com\/\" class=\"sgb-e-link sgb-e-link--vertical sgb-e-link--left\" target=\"_blank\" rel=\"noopener noreferrer\"><div class=\"sgb-e-link__text\"><span class=\"sgb-e-link__catchy\">\u53c2\u8003<\/span><div class=\"sgb-e-link__title\">ReportLab Docs<\/div><div class=\"sgb-e-link__sitename\"><\/div><\/div><\/a><\/div>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"i-20\">pypdf2<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Python\u3067PDF\u3092\u64cd\u4f5c\u3059\u308b\u30e9\u30a4\u30d6\u30e9\u30ea\u306b\u306f\u4ed6\u306bpypdf2\u304c\u3042\u308a\u307e\u3059\u3002\u5408\u308f\u305b\u3066\u304a\u8aad\u307f\u304f\u3060\u3055\u3044\uff01<\/p>\n\n\n<a class=\"linkto table\" href=\"https:\/\/chocottopro.com\/?p=436\"> <span class=\"tbcell tbimg\"><img loading=\"lazy\" decoding=\"async\" width=\"160\" height=\"160\" src=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/04\/pypdf2-160x160.jpg\" class=\"attachment-thumb-160 size-thumb-160 wp-post-image\" alt=\"\" srcset=\"https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/04\/pypdf2-160x160.jpg 160w, https:\/\/chocottopro.com\/wp-content\/uploads\/2024\/04\/pypdf2-150x150.jpg 150w\" sizes=\"auto, (max-width: 160px) 100vw, 160px\"><\/span> <span class=\"tbcell tbtext\"> <time class=\"pubdate sng-link-time dfont\" itemprop=\"datePublished\" datetime=\"2024-04-22\">2024\u5e744\u670822\u65e5<\/time> \u3010Python\u3011\u521d\u5fc3\u8005\u5411\u3051pypdf2\u306e\u4f7f\u3044\u65b9\u5b8c\u5168\u30ac\u30a4\u30c9\uff01PDF\u3092\u81ea\u5728\u306b\u64cd\u4f5c\u3057\u3088\u3046 <\/span> <\/a>","protected":false},"excerpt":{"rendered":"<p>Python\u3067PDF\u3092\u81ea\u52d5\u751f\u6210\u3057\u305f\u3044\u3001\u3067\u3082\u4f55\u304b\u3089\u59cb\u3081\u308c\u3070\u3044\u3044\u304b\u5206\u304b\u3089\u306a\u3044\u30fb\u30fb\u30fb\u3002\u305d\u3093\u306a\u65b9\u306b\u304a\u3059\u3059\u3081\u306a\u306e\u304c\u3001Python\u306e\u5f37\u529b\u306aPDF\u30e9\u30a4\u30d6\u30e9\u30ea\u300creportlab\u300d\u3067\u3059\u3002\u672c\u8a18\u4e8b\u3067\u306f\u3001reportlab\u3092\u4f7f\u3063\u305fPDF\u306e\u81ea\u52d5 &#8230; <\/p>\n","protected":false},"author":1,"featured_media":460,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-227","post","type-post","status-publish","format-standard","has-post-thumbnail","category-python"],"_links":{"self":[{"href":"https:\/\/chocottopro.com\/index.php?rest_route=\/wp\/v2\/posts\/227","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/chocottopro.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/chocottopro.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/chocottopro.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/chocottopro.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=227"}],"version-history":[{"count":9,"href":"https:\/\/chocottopro.com\/index.php?rest_route=\/wp\/v2\/posts\/227\/revisions"}],"predecessor-version":[{"id":899,"href":"https:\/\/chocottopro.com\/index.php?rest_route=\/wp\/v2\/posts\/227\/revisions\/899"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/chocottopro.com\/index.php?rest_route=\/wp\/v2\/media\/460"}],"wp:attachment":[{"href":"https:\/\/chocottopro.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=227"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/chocottopro.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=227"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/chocottopro.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=227"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}