-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deployed 7cc7120 with MkDocs version: 1.6.0
- Loading branch information
Unknown
committed
May 27, 2024
0 parents
commit 14b36f5
Showing
45 changed files
with
9,168 additions
and
0 deletions.
There are no files selected for viewing
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,132 @@ | ||
<!DOCTYPE html> | ||
<html class="writer-html5" lang="en" > | ||
<head> | ||
<meta charset="utf-8" /> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<link rel="shortcut icon" href="/img/favicon.ico" /> | ||
<title>Welcome to PyPDFForm - PyPDFForm Documentation</title> | ||
<link rel="stylesheet" href="/css/theme.css" /> | ||
<link rel="stylesheet" href="/css/theme_extra.css" /> | ||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.8.0/styles/github.min.css" /> | ||
|
||
<!--[if lt IE 9]> | ||
<script src="/js/html5shiv.min.js"></script> | ||
<![endif]--> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.8.0/highlight.min.js"></script> | ||
<script>hljs.highlightAll();</script> | ||
</head> | ||
|
||
<body class="wy-body-for-nav" role="document"> | ||
|
||
<div class="wy-grid-for-nav"> | ||
<nav data-toggle="wy-nav-shift" class="wy-nav-side stickynav"> | ||
<div class="wy-side-scroll"> | ||
<div class="wy-side-nav-search"> | ||
<a href="/."> | ||
<img src="/img/logo.png" class="logo" alt="Logo"/> | ||
</a> | ||
<div class="version"> | ||
v1.4.26 | ||
</div><div role="search"> | ||
<form id ="rtd-search-form" class="wy-form" action="//search.html" method="get"> | ||
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" title="Type search term here" /> | ||
</form> | ||
</div> | ||
</div> | ||
|
||
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu"> | ||
<p class="caption"><span class="caption-text">User Guide</span></p> | ||
<ul> | ||
<li class="toctree-l1"><a class="reference internal" href="/install/">Installation and setup</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/coordinate/">PDF coordinates</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/prepare/">Prepare a PDF form</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/inspect/">Inspect a PDF form</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/fill/">Fill a PDF form</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/simple_fill/">Fill a PDF form in place</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/style/">Change text field styles</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/button_style/">Change checkbox and radio button styles</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/draw/">Draw stuffs</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="/utils/">Other utilities</a> | ||
</li> | ||
</ul> | ||
</div> | ||
</div> | ||
</nav> | ||
|
||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"> | ||
<nav class="wy-nav-top" role="navigation" aria-label="Mobile navigation menu"> | ||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i> | ||
<a href="/.">Welcome to PyPDFForm - PyPDFForm Documentation</a> | ||
|
||
</nav> | ||
<div class="wy-nav-content"> | ||
<div class="rst-content"><div role="navigation" aria-label="breadcrumbs navigation"> | ||
<ul class="wy-breadcrumbs"> | ||
<li><a href="/." class="icon icon-home" aria-label="Docs"></a></li> | ||
<li class="wy-breadcrumbs-aside"> | ||
</li> | ||
</ul> | ||
<hr/> | ||
</div> | ||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article"> | ||
<div class="section" itemprop="articleBody"> | ||
|
||
|
||
<h1 id="404-page-not-found">404</h1> | ||
|
||
<p><strong>Page not found</strong></p> | ||
|
||
|
||
</div> | ||
</div><footer> | ||
|
||
<hr/> | ||
|
||
<div role="contentinfo"> | ||
<!-- Copyright etc --> | ||
</div> | ||
|
||
Built with <a href="https://www.mkdocs.org/">MkDocs</a> using a <a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>. | ||
</footer> | ||
|
||
</div> | ||
</div> | ||
|
||
</section> | ||
|
||
</div> | ||
|
||
<div class="rst-versions" role="note" aria-label="Versions"> | ||
<span class="rst-current-version" data-toggle="rst-current-version"> | ||
|
||
<span> | ||
<a href="https://github.com/chinapandaman/PyPDFForm" class="fa fa-github" style="color: #fcfcfc"> GitHub</a> | ||
</span> | ||
|
||
|
||
|
||
</span> | ||
</div> | ||
<script src="/js/jquery-3.6.0.min.js"></script> | ||
<script>var base_url = "/";</script> | ||
<script src="/js/theme_extra.js"></script> | ||
<script src="/js/theme.js"></script> | ||
<script src="/search/main.js"></script> | ||
<script> | ||
jQuery(function () { | ||
SphinxRtdTheme.Navigation.enable(true); | ||
}); | ||
</script> | ||
|
||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,197 @@ | ||
<!DOCTYPE html> | ||
<html class="writer-html5" lang="en" > | ||
<head> | ||
<meta charset="utf-8" /> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<link rel="shortcut icon" href="../img/favicon.ico" /> | ||
<title>Change checkbox and radio button styles - Welcome to PyPDFForm - PyPDFForm Documentation</title> | ||
<link rel="stylesheet" href="../css/theme.css" /> | ||
<link rel="stylesheet" href="../css/theme_extra.css" /> | ||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.8.0/styles/github.min.css" /> | ||
|
||
<script> | ||
// Current page data | ||
var mkdocs_page_name = "Change checkbox and radio button styles"; | ||
var mkdocs_page_input_path = "button_style.md"; | ||
var mkdocs_page_url = null; | ||
</script> | ||
|
||
<!--[if lt IE 9]> | ||
<script src="../js/html5shiv.min.js"></script> | ||
<![endif]--> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.8.0/highlight.min.js"></script> | ||
<script>hljs.highlightAll();</script> | ||
</head> | ||
|
||
<body class="wy-body-for-nav" role="document"> | ||
|
||
<div class="wy-grid-for-nav"> | ||
<nav data-toggle="wy-nav-shift" class="wy-nav-side stickynav"> | ||
<div class="wy-side-scroll"> | ||
<div class="wy-side-nav-search"> | ||
<a href=".."> | ||
<img src="../img/logo.png" class="logo" alt="Logo"/> | ||
</a> | ||
<div class="version"> | ||
v1.4.26 | ||
</div><div role="search"> | ||
<form id ="rtd-search-form" class="wy-form" action="../search.html" method="get"> | ||
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" title="Type search term here" /> | ||
</form> | ||
</div> | ||
</div> | ||
|
||
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu"> | ||
<p class="caption"><span class="caption-text">User Guide</span></p> | ||
<ul class="current"> | ||
<li class="toctree-l1"><a class="reference internal" href="../install/">Installation and setup</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../coordinate/">PDF coordinates</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../prepare/">Prepare a PDF form</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../inspect/">Inspect a PDF form</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../fill/">Fill a PDF form</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../simple_fill/">Fill a PDF form in place</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../style/">Change text field styles</a> | ||
</li> | ||
<li class="toctree-l1 current"><a class="reference internal current" href="#">Change checkbox and radio button styles</a> | ||
<ul class="current"> | ||
<li class="toctree-l2"><a class="reference internal" href="#change-size">Change size</a> | ||
</li> | ||
<li class="toctree-l2"><a class="reference internal" href="#change-button-style">Change button style</a> | ||
</li> | ||
</ul> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../draw/">Draw stuffs</a> | ||
</li> | ||
<li class="toctree-l1"><a class="reference internal" href="../utils/">Other utilities</a> | ||
</li> | ||
</ul> | ||
</div> | ||
</div> | ||
</nav> | ||
|
||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"> | ||
<nav class="wy-nav-top" role="navigation" aria-label="Mobile navigation menu"> | ||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i> | ||
<a href="..">Welcome to PyPDFForm - PyPDFForm Documentation</a> | ||
|
||
</nav> | ||
<div class="wy-nav-content"> | ||
<div class="rst-content"><div role="navigation" aria-label="breadcrumbs navigation"> | ||
<ul class="wy-breadcrumbs"> | ||
<li><a href=".." class="icon icon-home" aria-label="Docs"></a></li> | ||
<li class="breadcrumb-item">User Guide</li> | ||
<li class="breadcrumb-item active">Change checkbox and radio button styles</li> | ||
<li class="wy-breadcrumbs-aside"> | ||
<a href="https://github.com/chinapandaman/PyPDFForm/edit/master/docs/button_style.md" class="icon icon-github"> Edit on GitHub</a> | ||
</li> | ||
</ul> | ||
<hr/> | ||
</div> | ||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article"> | ||
<div class="section" itemprop="articleBody"> | ||
|
||
<h1 id="change-checkbox-and-radio-button-styles">Change checkbox and radio button styles</h1> | ||
<p>Similar to text fields discussed in the last chapter, PyPDFForm gives you the ability to | ||
modify some styles of checkboxes and radio buttons without changing the template.</p> | ||
<h2 id="change-size">Change size</h2> | ||
<p>You can change the size of the selection by specifying a <code>float</code> value. Consider | ||
<a href="https://github.com/chinapandaman/PyPDFForm/raw/master/pdf_samples/sample_template.pdf">this PDF</a>:</p> | ||
<pre><code class="language-python">from PyPDFForm import PdfWrapper | ||
|
||
form = PdfWrapper("sample_template.pdf") | ||
form.widgets["check"].size = 50 | ||
form.widgets["check_2"].size = 40 | ||
form.widgets["check_3"].size = 60 | ||
|
||
form.fill( | ||
{ | ||
"check": True, | ||
"check_2": True, | ||
"check_3": True, | ||
}, | ||
) | ||
|
||
with open("output.pdf", "wb+") as output: | ||
output.write(form.read()) | ||
</code></pre> | ||
<h2 id="change-button-style">Change button style</h2> | ||
<p>The button style is the shape of the selection on a checkbox or radio button. PyPDFForm lets you pick | ||
three different button styles: <code>check</code>, <code>circle</code>, and <code>cross</code>. Consider | ||
<a href="https://github.com/chinapandaman/PyPDFForm/raw/master/pdf_samples/sample_template_with_radio_button.pdf">this PDF</a>:</p> | ||
<pre><code class="language-python">from PyPDFForm import PdfWrapper | ||
|
||
form = PdfWrapper("sample_template_with_radio_button.pdf") | ||
form.widgets["radio_1"].button_style = "cross" | ||
form.widgets["radio_2"].button_style = "circle" | ||
form.widgets["radio_3"].button_style = "check" | ||
|
||
form.fill( | ||
{ | ||
"radio_1": 0, | ||
"radio_2": 1, | ||
"radio_3": 2, | ||
}, | ||
) | ||
|
||
with open("output.pdf", "wb+") as output: | ||
output.write(form.read()) | ||
</code></pre> | ||
|
||
</div> | ||
</div><footer> | ||
<div class="rst-footer-buttons" role="navigation" aria-label="Footer Navigation"> | ||
<a href="../style/" class="btn btn-neutral float-left" title="Change text field styles"><span class="icon icon-circle-arrow-left"></span> Previous</a> | ||
<a href="../draw/" class="btn btn-neutral float-right" title="Draw stuffs">Next <span class="icon icon-circle-arrow-right"></span></a> | ||
</div> | ||
|
||
<hr/> | ||
|
||
<div role="contentinfo"> | ||
<!-- Copyright etc --> | ||
</div> | ||
|
||
Built with <a href="https://www.mkdocs.org/">MkDocs</a> using a <a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>. | ||
</footer> | ||
|
||
</div> | ||
</div> | ||
|
||
</section> | ||
|
||
</div> | ||
|
||
<div class="rst-versions" role="note" aria-label="Versions"> | ||
<span class="rst-current-version" data-toggle="rst-current-version"> | ||
|
||
<span> | ||
<a href="https://github.com/chinapandaman/PyPDFForm" class="fa fa-github" style="color: #fcfcfc"> GitHub</a> | ||
</span> | ||
|
||
|
||
<span><a href="../style/" style="color: #fcfcfc">« Previous</a></span> | ||
|
||
|
||
<span><a href="../draw/" style="color: #fcfcfc">Next »</a></span> | ||
|
||
</span> | ||
</div> | ||
<script src="../js/jquery-3.6.0.min.js"></script> | ||
<script>var base_url = "..";</script> | ||
<script src="../js/theme_extra.js"></script> | ||
<script src="../js/theme.js"></script> | ||
<script src="../search/main.js"></script> | ||
<script> | ||
jQuery(function () { | ||
SphinxRtdTheme.Navigation.enable(true); | ||
}); | ||
</script> | ||
|
||
</body> | ||
</html> |
Oops, something went wrong.