From f8f1004e29e5cec0a553c9297dfe92a2c014db86 Mon Sep 17 00:00:00 2001 From: Mariusz Krzaczkowski Date: Mon, 14 Jun 2021 13:56:49 +0200 Subject: [PATCH 1/3] Update README.MD --- README.MD | 1 - 1 file changed, 1 deletion(-) diff --git a/README.MD b/README.MD index 865421d..24078f6 100644 --- a/README.MD +++ b/README.MD @@ -1,7 +1,6 @@ # YetiForcePDF [![Latest Stable Version](https://poser.pugx.org/yetiforce/yetiforcepdf/v/stable)](https://packagist.org/packages/yetiforce/yetiforcepdf) [![Build Status](https://travis-ci.org/YetiForceCompany/YetiForcePDF.svg?branch=developer)](https://travis-ci.org/YetiForceCompany/YetiForcePDF) -[![Analytics](https://ga-beacon.appspot.com/UA-81376231-2/welcome-page)](https://github.com/igrigorik/ga-beacon) [![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/YetiForceCompany/YetiForcePDF/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/YetiForceCompany/YetiForcePDF/?branch=master) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/b2e8645f5091496089ed203d05a05d61)](https://app.codacy.com/app/mariuszkrzaczkowski/YetiForcePDF?utm_source=github.com&utm_medium=referral&utm_content=YetiForceCompany/YetiForcePDF&utm_campaign=Badge_Grade_Settings) [![Maintainability](https://api.codeclimate.com/v1/badges/af478ddd07cf7278841a/maintainability)](https://codeclimate.com/github/YetiForceCompany/YetiForcePDF/maintainability) From 922cb0dd31c17192bb7bd8bf0ae150634948785e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrian=20Ko=C5=84?= Date: Fri, 20 Aug 2021 11:13:58 +0200 Subject: [PATCH 2/3] Improved default style for pre element --- lib/Style/Style.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Style/Style.php b/lib/Style/Style.php index fc34c69..edc36ae 100644 --- a/lib/Style/Style.php +++ b/lib/Style/Style.php @@ -492,7 +492,7 @@ class Style extends \YetiForcePDF\Base 'display' => 'block', 'font-family' => 'monospace', 'white-space' => 'pre', - 'margin' => '1em0', + 'margin' => '1em', ], 'q' => [ 'display' => 'inline', From ca04b8c0ef97592e1d2fbc77264dbd5323b6e4c6 Mon Sep 17 00:00:00 2001 From: Mariusz Krzaczkowski Date: Thu, 28 Oct 2021 14:40:26 +0200 Subject: [PATCH 3/3] License changed to MIT --- .php_cs.dist | 162 +++++++++++++++++++++ LICENSE | 30 ++-- README.MD | 3 +- composer.json | 3 +- examples/ColSpan.php | 8 +- examples/CustomFonts.php | 6 +- examples/DefaultStyles.php | 8 +- examples/HeaderFooter.php | 8 +- examples/Image.php | 8 +- examples/InvoiceTable.php | 2 +- examples/LongTable.php | 2 +- examples/LoremIpsum.php | 2 +- examples/NotExported.php | 2 +- examples/Pages.php | 8 +- examples/PagesTables.php | 2 +- examples/PagesTables2.html.php | 2 +- examples/PagesTables2.php | 3 +- examples/RowSpan.php | 8 +- examples/SimpleNestedDiv.php | 8 +- examples/SimpleTable.php | 8 +- examples/SpanTable.php | 8 +- examples/WidthsSpecifiedTable.php | 8 +- examples/helloWorld.php | 1 + lib/Base.php | 2 +- lib/Catalog.php | 4 +- lib/Document.php | 6 +- lib/Fonts/DejaVuSans-LICENSE.txt | 4 +- lib/Html/Element.php | 2 +- lib/Html/Parser.php | 2 +- lib/Layout/AppendChildInterface.php | 2 +- lib/Layout/BarcodeBox.php | 2 +- lib/Layout/BlockBox.php | 4 +- lib/Layout/Box.php | 14 +- lib/Layout/BoxInterface.php | 2 +- lib/Layout/BuildTreeInterface.php | 2 +- lib/Layout/Coordinates/Coordinates.php | 2 +- lib/Layout/Coordinates/Offset.php | 2 +- lib/Layout/Dimensions/BoxDimensions.php | 2 +- lib/Layout/Dimensions/Dimensions.php | 2 +- lib/Layout/ElementBox.php | 2 +- lib/Layout/FontBox.php | 2 +- lib/Layout/FooterBox.php | 2 +- lib/Layout/HeaderBox.php | 2 +- lib/Layout/ImageBox.php | 2 +- lib/Layout/InlineBlockBox.php | 2 +- lib/Layout/InlineBox.php | 4 +- lib/Layout/LineBox.php | 2 +- lib/Layout/PageGroupBox.php | 2 +- lib/Layout/StyleBox.php | 2 +- lib/Layout/TableBox.php | 2 +- lib/Layout/TableCellBox.php | 6 +- lib/Layout/TableColumnBox.php | 2 +- lib/Layout/TableColumnGroupBox.php | 2 +- lib/Layout/TableFooterGroupBox.php | 2 +- lib/Layout/TableHeaderGroupBox.php | 2 +- lib/Layout/TableRowBox.php | 2 +- lib/Layout/TableRowGroupBox.php | 2 +- lib/Layout/TableWrapperBox.php | 2 +- lib/Layout/TextBox.php | 6 +- lib/Layout/WatermarkBox.php | 2 +- lib/Math.php | 2 +- lib/Objects/Basic/ArrayObject.php | 4 +- lib/Objects/Basic/BooleanObject.php | 2 +- lib/Objects/Basic/DictionaryObject.php | 4 +- lib/Objects/Basic/IntegerObject.php | 2 +- lib/Objects/Basic/NameObject.php | 2 +- lib/Objects/Basic/NullObject.php | 2 +- lib/Objects/Basic/RealObject.php | 2 +- lib/Objects/Basic/StreamObject.php | 4 +- lib/Objects/Basic/StringObject.php | 2 +- lib/Objects/Font.php | 4 +- lib/Objects/FontDescriptor.php | 4 +- lib/Objects/FontEncoding.php | 4 +- lib/Objects/GraphicState.php | 2 +- lib/Objects/ImageStream.php | 4 +- lib/Objects/Meta.php | 2 +- lib/Objects/PdfObject.php | 2 +- lib/Objects/Resource.php | 2 +- lib/Objects/TextStream.php | 4 +- lib/Objects/Trailer.php | 4 +- lib/Page.php | 6 +- lib/Pages.php | 2 +- lib/Style/Color.php | 4 +- lib/Style/Normalizer/Background.php | 2 +- lib/Style/Normalizer/BackgroundColor.php | 2 +- lib/Style/Normalizer/BackgroundImage.php | 2 +- lib/Style/Normalizer/Border.php | 2 +- lib/Style/Normalizer/BorderBottomColor.php | 2 +- lib/Style/Normalizer/BorderBottomStyle.php | 2 +- lib/Style/Normalizer/BorderBottomWidth.php | 2 +- lib/Style/Normalizer/BorderCollapse.php | 2 +- lib/Style/Normalizer/BorderColor.php | 2 +- lib/Style/Normalizer/BorderLeftColor.php | 2 +- lib/Style/Normalizer/BorderLeftStyle.php | 2 +- lib/Style/Normalizer/BorderLeftWidth.php | 2 +- lib/Style/Normalizer/BorderRightColor.php | 2 +- lib/Style/Normalizer/BorderRightStyle.php | 2 +- lib/Style/Normalizer/BorderRightWidth.php | 2 +- lib/Style/Normalizer/BorderSpacing.php | 2 +- lib/Style/Normalizer/BorderStyle.php | 2 +- lib/Style/Normalizer/BorderTopColor.php | 2 +- lib/Style/Normalizer/BorderTopStyle.php | 2 +- lib/Style/Normalizer/BorderTopWidth.php | 2 +- lib/Style/Normalizer/BorderWidth.php | 4 +- lib/Style/Normalizer/BoxSizing.php | 2 +- lib/Style/Normalizer/Color.php | 2 +- lib/Style/Normalizer/Display.php | 2 +- lib/Style/Normalizer/FontFamily.php | 2 +- lib/Style/Normalizer/FontSize.php | 2 +- lib/Style/Normalizer/FontStyle.php | 2 +- lib/Style/Normalizer/FontWeight.php | 2 +- lib/Style/Normalizer/Height.php | 2 +- lib/Style/Normalizer/LineHeight.php | 2 +- lib/Style/Normalizer/Margin.php | 2 +- lib/Style/Normalizer/MarginBottom.php | 2 +- lib/Style/Normalizer/MarginLeft.php | 2 +- lib/Style/Normalizer/MarginRight.php | 2 +- lib/Style/Normalizer/MarginTop.php | 2 +- lib/Style/Normalizer/MaxWidth.php | 2 +- lib/Style/Normalizer/MinWidth.php | 2 +- lib/Style/Normalizer/Normalizer.php | 4 +- lib/Style/Normalizer/Opacity.php | 2 +- lib/Style/Normalizer/Overflow.php | 2 +- lib/Style/Normalizer/Padding.php | 2 +- lib/Style/Normalizer/PaddingBottom.php | 2 +- lib/Style/Normalizer/PaddingLeft.php | 2 +- lib/Style/Normalizer/PaddingRight.php | 2 +- lib/Style/Normalizer/PaddingTop.php | 2 +- lib/Style/Normalizer/TextAlign.php | 2 +- lib/Style/Normalizer/Transform.php | 4 +- lib/Style/Normalizer/TransformOrigin.php | 4 +- lib/Style/Normalizer/TransformRotate.php | 4 +- lib/Style/Normalizer/VerticalAlign.php | 2 +- lib/Style/Normalizer/WhiteSpace.php | 2 +- lib/Style/Normalizer/Width.php | 2 +- lib/Style/Normalizer/WordWrap.php | 2 +- lib/Style/NumericValue.php | 2 +- lib/Style/Style.php | 8 +- renovate.json | 4 +- 139 files changed, 386 insertions(+), 220 deletions(-) create mode 100644 .php_cs.dist diff --git a/.php_cs.dist b/.php_cs.dist new file mode 100644 index 0000000..c70ddbb --- /dev/null +++ b/.php_cs.dist @@ -0,0 +1,162 @@ +setRiskyAllowed(true) + ->setIndent("\t") + ->setUsingCache(false) + ->setRules([ + '@PHP56Migration' => true, + '@PHPUnit60Migration:risky' => true, + '@PhpCsFixer' => true, + '@PhpCsFixer:risky' => true, + 'list_syntax' => ['syntax' => 'short'], + '@PSR2' => true, + 'align_multiline_comment' => true, + 'array_syntax' => ['syntax' => 'short'], + 'blank_line_after_namespace' => true, + 'blank_line_after_opening_tag' => true, + 'blank_line_before_statement' => false, + 'binary_operator_spaces' => true, + 'cast_spaces' => true, + 'class_keyword_remove' => false, + 'combine_consecutive_issets' => true, + 'combine_consecutive_unsets' => true, + 'compact_nullable_typehint' => true, + 'concat_space' => [ + 'spacing' => 'one', + ], + 'explicit_string_variable' => false, + 'declare_equal_normalize' => true, + 'dir_constant' => false, + 'doctrine_annotation_braces' => true, + 'doctrine_annotation_indentation' => true, + 'doctrine_annotation_spaces' => true, + 'function_typehint_space' => true, + 'general_phpdoc_annotation_remove' => false, + 'hash_to_slash_comment' => true, + 'include' => true, + 'linebreak_after_opening_tag' => true, + 'lowercase_cast' => true, + 'magic_constant_casing' => true, + 'method_chaining_indentation' => true, + 'method_separation' => true, + 'method_argument_space' => true, + 'modernize_types_casting' => true, + 'multiline_comment_opening_closing' => true, + 'no_multiline_whitespace_before_semicolons' => true, + 'native_function_casing' => true, + 'native_function_invocation' => ['include' => ['@compiler_optimized'], 'scope' => 'all'], + 'new_with_braces' => true, + 'no_alias_functions' => true, + 'no_blank_lines_after_class_opening' => true, + 'no_blank_lines_after_phpdoc' => true, + 'no_blank_lines_before_namespace' => false, + 'no_closing_tag' => true, + 'no_empty_comment' => true, + 'no_empty_phpdoc' => true, + 'no_empty_statement' => true, + 'no_extra_blank_lines' => ['tokens' => ['break', 'continue', 'extra', 'return', 'throw', 'use', 'parenthesis_brace_block', 'square_brace_block', 'curly_brace_block']], + 'no_extra_consecutive_blank_lines' => [ + 'break', + 'continue', + 'curly_brace_block', + 'extra', + 'parenthesis_brace_block', + 'return', + 'square_brace_block', + 'throw', + 'use', + 'useTrait', + ], + 'no_leading_import_slash' => true, + 'no_leading_namespace_whitespace' => true, + 'no_mixed_echo_print' => [ + 'use' => 'echo', + ], + 'no_multiline_whitespace_around_double_arrow' => true, + 'no_multiline_whitespace_before_semicolons' => true, + 'no_null_property_initialization' => true, + 'no_php4_constructor' => false, + 'no_short_bool_cast' => true, + 'no_short_echo_tag' => true, + 'no_superfluous_phpdoc_tags' => false, + 'no_singleline_whitespace_before_semicolons' => true, + 'no_spaces_after_function_name' => true, + 'no_spaces_around_offset' => true, + 'no_spaces_inside_parenthesis' => true, + 'no_trailing_comma_in_list_call' => true, + 'no_trailing_comma_in_singleline_array' => true, + 'no_trailing_whitespace' => true, + 'no_trailing_whitespace_in_comment' => true, + 'no_unneeded_control_parentheses' => true, + 'no_unneeded_final_method' => true, + 'no_unused_imports' => true, + 'no_useless_return' => true, + 'no_whitespace_before_comma_in_array' => true, + 'no_whitespace_in_blank_line' => true, + 'normalize_index_brace' => true, + 'not_operator_with_space' => false, + 'not_operator_with_successor_space' => false, + 'object_operator_without_whitespace' => true, + 'ordered_class_elements' => false, + 'ordered_imports' => true, + 'php_unit_construct' => [], + 'php_unit_fqcn_annotation' => true, + 'php_unit_strict' => true, + 'phpdoc_add_missing_param_annotation' => [ + 'only_untyped' => false, + ], + 'phpdoc_align' => true, + 'phpdoc_annotation_without_dot' => false, + 'phpdoc_indent' => true, + 'phpdoc_inline_tag' => true, + 'phpdoc_no_access' => true, + 'phpdoc_no_empty_return' => false, + 'phpdoc_no_package' => false, + 'phpdoc_no_useless_inheritdoc' => true, + 'phpdoc_order' => true, + 'phpdoc_return_self_reference' => true, + 'phpdoc_scalar' => true, + 'phpdoc_separation' => true, + 'phpdoc_single_line_var_spacing' => true, + 'phpdoc_summary' => true, + 'phpdoc_trim' => true, + 'phpdoc_types' => true, + 'phpdoc_types_order' => ['null_adjustment' => 'always_last', 'sort_algorithm' => 'none'], + 'phpdoc_var_without_name' => true, + 'psr_autoloading' => false, + 'return_type_declaration' => true, + 'self_accessor' => true, + 'semicolon_after_instruction' => true, + 'short_scalar_cast' => true, + 'silenced_deprecation_error' => false, + 'single_blank_line_at_eof' => true, + 'single_blank_line_before_namespace' => true, + 'single_class_element_per_statement' => true, + 'single_import_per_statement' => true, + 'single_line_comment_style' => true, + 'single_line_throw' => true, + 'single_quote' => true, + 'space_after_semicolon' => true, + 'standardize_not_equals' => true, + 'strict_comparison' => false, + 'strict_param' => false, + 'switch_case_semicolon_to_colon' => true, + 'switch_case_space' => true, + 'ternary_operator_spaces' => true, + 'ternary_to_null_coalescing' => true, + 'trailing_comma_in_multiline_array' => false, + 'trim_array_spaces' => true, + 'unary_operator_spaces' => true, + 'visibility_required' => [ + 'property', + 'method', + ], + 'whitespace_after_comma_in_array' => true, + ]) + ->setFinder(PhpCsFixer\Finder::create() + ->exclude('vendor') + ->in(__DIR__) +); + +return $config; diff --git a/LICENSE b/LICENSE index 108a02a..67fef7f 100644 --- a/LICENSE +++ b/LICENSE @@ -1,15 +1,21 @@ -YetiForce Public License v3 -Open license based on MIT license -Copyright (c) 2017 YetiForce Sp. z o.o. (Ltd.) +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, -including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, -and to permit persons to whom the Software is furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. -The inclusion of abovementioned notices may be in a form of an active link to the license, as stated in Appendix A. -The Software used for more than 14 days must be registered via the built-in form. -If such registration is not possible, further use of the Software requires registration via email (registration@yetiforce.com), as stated in Appendix B. -The registration form is properly submitted if sent (data entry to electronic communication system) and if it contains complete and true data. -Registration is mandatory for any company (registration does not apply to employees of these companies or private individuals) that uses, configures and/or modifies the Software, regardless of whether the entity does it for itself or for other subjects. +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + + + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + +SOFTWARE. diff --git a/README.MD b/README.MD index 24078f6..22f649f 100644 --- a/README.MD +++ b/README.MD @@ -4,7 +4,6 @@ [![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/YetiForceCompany/YetiForcePDF/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/YetiForceCompany/YetiForcePDF/?branch=master) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/b2e8645f5091496089ed203d05a05d61)](https://app.codacy.com/app/mariuszkrzaczkowski/YetiForcePDF?utm_source=github.com&utm_medium=referral&utm_content=YetiForceCompany/YetiForcePDF&utm_campaign=Badge_Grade_Settings) [![Maintainability](https://api.codeclimate.com/v1/badges/af478ddd07cf7278841a/maintainability)](https://codeclimate.com/github/YetiForceCompany/YetiForcePDF/maintainability) -[![SymfonyInsight](https://insight.symfony.com/projects/d944b009-6a76-4957-8833-db95b010e5a5/big.png)](https://insight.symfony.com/projects/d944b009-6a76-4957-8833-db95b010e5a5) ## PDF generation library for PHP The best library in the world to generate PDF from HTML @@ -195,7 +194,7 @@ When you want to place page number (in header or footer for example) you can do - [ ] position (absolute, relative) ### License -YetiForce Public License v3 +MIT ======= file_put_contents('test.pdf', $pdfFile); ``` diff --git a/composer.json b/composer.json index af1bee9..5d393ad 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,7 @@ { "name": "yetiforce/yetiforcepdf", "description": "Library that generate pdf files from html.", + "license": "MIT", "type": "library", "keywords": [ "pdf", @@ -11,7 +12,7 @@ "authors": [ { "name": "YetiForceCompany", - "email": "info@yetiforce.com", + "email": "devs@yetiforce.com", "homepage": "https://yetiforce.com/" } ], diff --git a/examples/ColSpan.php b/examples/ColSpan.php index a3104aa..015ecd3 100644 --- a/examples/ColSpan.php +++ b/examples/ColSpan.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['ColSpan']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/CustomFonts.php b/examples/CustomFonts.php index 87ea224..49807f1 100644 --- a/examples/CustomFonts.php +++ b/examples/CustomFonts.php @@ -7,19 +7,19 @@ 'family' => 'Pacifico', 'weight' => '400', 'style' => 'normal', - 'file' => 'd:\fonts\Pacifico\Pacifico-Regular.ttf' + 'file' => 'd:\fonts\Pacifico\Pacifico-Regular.ttf', ], [ 'family' => 'Lobster Two', 'weight' => '400', 'style' => 'normal', - 'file' => 'd:\fonts\Lobster_Two\LobsterTwo-Regular.ttf' + 'file' => 'd:\fonts\Lobster_Two\LobsterTwo-Regular.ttf', ], [ 'family' => 'Lobster Two', 'weight' => 'bold', 'style' => 'normal', - 'file' => 'd:\fonts\Lobster_Two\LobsterTwo-Bold.ttf' + 'file' => 'd:\fonts\Lobster_Two\LobsterTwo-Bold.ttf', ], ]); diff --git a/examples/DefaultStyles.php b/examples/DefaultStyles.php index f1e8676..5ed36b6 100644 --- a/examples/DefaultStyles.php +++ b/examples/DefaultStyles.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['DefaultStyles']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/HeaderFooter.php b/examples/HeaderFooter.php index 9c9462e..776a6c4 100644 --- a/examples/HeaderFooter.php +++ b/examples/HeaderFooter.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['HeaderFooter']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/Image.php b/examples/Image.php index 55bc27a..2ce470c 100644 --- a/examples/Image.php +++ b/examples/Image.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['Image']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/InvoiceTable.php b/examples/InvoiceTable.php index 6a3de65..f4048f0 100644 --- a/examples/InvoiceTable.php +++ b/examples/InvoiceTable.php @@ -5,5 +5,5 @@ $document->loadHtml(file_get_contents('InvoiceTable.html')); $time = microtime(true); $pdfFile = $document->render(); -echo microtime(true)-$time; +echo microtime(true) - $time; file_put_contents('InvoiceTable.pdf', $pdfFile); diff --git a/examples/LongTable.php b/examples/LongTable.php index 8301faf..909bb1e 100644 --- a/examples/LongTable.php +++ b/examples/LongTable.php @@ -7,6 +7,6 @@ $document->loadHtml(file_get_contents($file . '.html')); $time = microtime(true); $pdfFile = $document->render(); - echo microtime(true) -$time; + echo microtime(true) - $time; file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/LoremIpsum.php b/examples/LoremIpsum.php index 12edacf..c3bd7c0 100644 --- a/examples/LoremIpsum.php +++ b/examples/LoremIpsum.php @@ -7,6 +7,6 @@ $document->loadHtml(file_get_contents($file . '.html')); $time = microtime(true); $pdfFile = $document->render(); - echo microtime(true) -$time; + echo microtime(true) - $time; file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/NotExported.php b/examples/NotExported.php index ae341eb..e143130 100644 --- a/examples/NotExported.php +++ b/examples/NotExported.php @@ -7,6 +7,6 @@ $document->loadHtml(file_get_contents($file . '.html')); $time = microtime(true); $pdfFile = $document->render(); - echo microtime(true) -$time; + echo microtime(true) - $time; file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/Pages.php b/examples/Pages.php index c6c561d..b4ef83b 100644 --- a/examples/Pages.php +++ b/examples/Pages.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['Pages']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/PagesTables.php b/examples/PagesTables.php index db07f1c..832f598 100644 --- a/examples/PagesTables.php +++ b/examples/PagesTables.php @@ -7,6 +7,6 @@ $document->loadHtml(file_get_contents($file . '.html')); $time = microtime(true); $pdfFile = $document->render(); - echo microtime(true)-$time; + echo microtime(true) - $time; file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/PagesTables2.html.php b/examples/PagesTables2.html.php index e14db2c..5725186 100644 --- a/examples/PagesTables2.html.php +++ b/examples/PagesTables2.html.php @@ -1,7 +1,7 @@ '; -for ($i = 0; $i < 100; $i++) { +for ($i = 0; $i < 100; ++$i) { $html .= '' . $i . 'item'; } $html .= ''; diff --git a/examples/PagesTables2.php b/examples/PagesTables2.php index 96e2535..080c569 100644 --- a/examples/PagesTables2.php +++ b/examples/PagesTables2.php @@ -1,9 +1,8 @@ init(); $document->loadHtml($html); $pdfFile = $document->render(); file_put_contents('PagesTables2.pdf', $pdfFile); - diff --git a/examples/RowSpan.php b/examples/RowSpan.php index 908a89c..07d3dc1 100644 --- a/examples/RowSpan.php +++ b/examples/RowSpan.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['RowSpan']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/SimpleNestedDiv.php b/examples/SimpleNestedDiv.php index 6673a2d..3f8953d 100644 --- a/examples/SimpleNestedDiv.php +++ b/examples/SimpleNestedDiv.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['SimpleNestedDiv']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/SimpleTable.php b/examples/SimpleTable.php index 2eea236..fcdfb69 100644 --- a/examples/SimpleTable.php +++ b/examples/SimpleTable.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['SimpleTable']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/SpanTable.php b/examples/SpanTable.php index b2f775f..9b9733d 100644 --- a/examples/SpanTable.php +++ b/examples/SpanTable.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['SpanTable']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/WidthsSpecifiedTable.php b/examples/WidthsSpecifiedTable.php index 09306d4..750c1b4 100644 --- a/examples/WidthsSpecifiedTable.php +++ b/examples/WidthsSpecifiedTable.php @@ -3,8 +3,8 @@ $loader = require '../vendor/autoload.php'; $files = ['WidthsSpecifiedTable']; foreach ($files as $file) { - $document = (new YetiForcePDF\Document())->init(); - $document->loadHtml(file_get_contents($file . '.html')); - $pdfFile = $document->render(); - file_put_contents($file . '.pdf', $pdfFile); + $document = (new YetiForcePDF\Document())->init(); + $document->loadHtml(file_get_contents($file . '.html')); + $pdfFile = $document->render(); + file_put_contents($file . '.pdf', $pdfFile); } diff --git a/examples/helloWorld.php b/examples/helloWorld.php index 0c78f68..1761250 100644 --- a/examples/helloWorld.php +++ b/examples/helloWorld.php @@ -1,4 +1,5 @@ init(); $document->loadHtml(file_get_contents('helloWorld.html')); diff --git a/lib/Base.php b/lib/Base.php index d90dd8b..2f2b015 100644 --- a/lib/Base.php +++ b/lib/Base.php @@ -7,7 +7,7 @@ * @package YetiForcePDF * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Catalog.php b/lib/Catalog.php index 23d77f9..0eba61f 100644 --- a/lib/Catalog.php +++ b/lib/Catalog.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Document * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -46,7 +46,7 @@ public function render(): string ' /Type /Catalog', ' /Pages ' . $this->document->getPagesObject()->getReference(), '>>', - 'endobj' + 'endobj', ]); } } diff --git a/lib/Document.php b/lib/Document.php index 057d826..91911d2 100644 --- a/lib/Document.php +++ b/lib/Document.php @@ -7,7 +7,7 @@ * @package YetiForcePDF * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -76,7 +76,7 @@ class Document 'left' => 40, 'top' => 40, 'right' => 40, - 'bottom' => 40 + 'bottom' => 40, ]; /** * All objects inside document. @@ -233,7 +233,7 @@ public function setDefaultMargins(float $left, float $top, float $right, float $ 'right' => $right, 'bottom' => $bottom, 'horizontal' => $left + $right, - 'vertical' => $top + $bottom + 'vertical' => $top + $bottom, ]; foreach ($this->pages as $page) { $page->setMargins($left, $top, $right, $bottom); diff --git a/lib/Fonts/DejaVuSans-LICENSE.txt b/lib/Fonts/DejaVuSans-LICENSE.txt index 254e2cc..8ecd49d 100644 --- a/lib/Fonts/DejaVuSans-LICENSE.txt +++ b/lib/Fonts/DejaVuSans-LICENSE.txt @@ -46,7 +46,7 @@ Foundation, and Bitstream Inc., shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Font Software without prior written authorization from the Gnome Foundation or Bitstream Inc., respectively. For further information, contact: fonts at gnome dot -org. +org. Arev Fonts Copyright ------------------------------ @@ -73,7 +73,7 @@ Fonts, only if the fonts are renamed to names not containing either the words "Tavmjong Bah" or the word "Arev". This License becomes null and void to the extent applicable to Fonts -or Font Software that has been modified and is distributed under the +or Font Software that has been modified and is distributed under the "Tavmjong Bah Arev" names. The Font Software may be sold as part of a larger software package but diff --git a/lib/Html/Element.php b/lib/Html/Element.php index 111d061..ad4d887 100644 --- a/lib/Html/Element.php +++ b/lib/Html/Element.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Html * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Html/Parser.php b/lib/Html/Parser.php index dedc1db..7b38e7d 100644 --- a/lib/Html/Parser.php +++ b/lib/Html/Parser.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Html * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/AppendChildInterface.php b/lib/Layout/AppendChildInterface.php index 6efb106..dcc9d2e 100644 --- a/lib/Layout/AppendChildInterface.php +++ b/lib/Layout/AppendChildInterface.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/BarcodeBox.php b/lib/Layout/BarcodeBox.php index d5fbc38..2f08307 100644 --- a/lib/Layout/BarcodeBox.php +++ b/lib/Layout/BarcodeBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/BlockBox.php b/lib/Layout/BlockBox.php index 53d04f0..36fcd9f 100644 --- a/lib/Layout/BlockBox.php +++ b/lib/Layout/BlockBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -737,7 +737,7 @@ public function addBackgroundColorInstructions(array $element, $pdfX, $pdfY, $wi "{$rules['background-color'][0]} {$rules['background-color'][1]} {$rules['background-color'][2]} rg", "0 0 $width $height re", 'f', - 'Q' + 'Q', ]; $element = array_merge($element, $bgColor); } diff --git a/lib/Layout/Box.php b/lib/Layout/Box.php index 8ce0793..951a4dd 100644 --- a/lib/Layout/Box.php +++ b/lib/Layout/Box.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -459,7 +459,7 @@ protected function hide() 'border-top-width' => '0', 'border-right-width' => '0', 'border-bottom-width' => '0', - 'border-left-width' => '0' + 'border-left-width' => '0', ]); $this->getDimensions()->setWidth('0'); $this->getDimensions()->setHeight('0'); @@ -1096,7 +1096,7 @@ protected function addBorderInstructions(array $element, string $pdfX, string $p implode(' ', [$x2, $y1]), implode(' ', [Math::sub($x2, $style->getRules('border-right-width')), Math::sub($y1, $style->getRules('border-top-width'))]), implode(' ', [Math::add($x1, $style->getRules('border-left-width')), Math::sub($y1, $style->getRules('border-top-width'))]), - implode(' ', [$x1, $y1]) + implode(' ', [$x1, $y1]), ]); $borderTop = [ 'q', @@ -1106,7 +1106,7 @@ protected function addBorderInstructions(array $element, string $pdfX, string $p "$x1 $y1 m", // move to start point $path . ' l h', 'f', - 'Q' + 'Q', ]; $element = array_merge($element, $borderTop); } @@ -1125,7 +1125,7 @@ protected function addBorderInstructions(array $element, string $pdfX, string $p "$x2 $y1 m", $path . ' l h', 'f', - 'Q' + 'Q', ]; $element = array_merge($element, $borderTop); } @@ -1144,7 +1144,7 @@ protected function addBorderInstructions(array $element, string $pdfX, string $p "$x1 $y2 m", $path . ' l h', 'f', - 'Q' + 'Q', ]; $element = array_merge($element, $borderTop); } @@ -1163,7 +1163,7 @@ protected function addBorderInstructions(array $element, string $pdfX, string $p "$x1 $y1 m", $path . ' l h', 'f', - 'Q' + 'Q', ]; $element = array_merge($element, $borderTop); } diff --git a/lib/Layout/BoxInterface.php b/lib/Layout/BoxInterface.php index 063b58d..4569105 100644 --- a/lib/Layout/BoxInterface.php +++ b/lib/Layout/BoxInterface.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/BuildTreeInterface.php b/lib/Layout/BuildTreeInterface.php index 40a7f04..88b96a5 100644 --- a/lib/Layout/BuildTreeInterface.php +++ b/lib/Layout/BuildTreeInterface.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/Coordinates/Coordinates.php b/lib/Layout/Coordinates/Coordinates.php index 83891f1..648b320 100644 --- a/lib/Layout/Coordinates/Coordinates.php +++ b/lib/Layout/Coordinates/Coordinates.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout\Coordinates * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/Coordinates/Offset.php b/lib/Layout/Coordinates/Offset.php index 2f1eda3..5737ba9 100644 --- a/lib/Layout/Coordinates/Offset.php +++ b/lib/Layout/Coordinates/Offset.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout\Coordinates * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/Dimensions/BoxDimensions.php b/lib/Layout/Dimensions/BoxDimensions.php index ad57e3e..05b851e 100644 --- a/lib/Layout/Dimensions/BoxDimensions.php +++ b/lib/Layout/Dimensions/BoxDimensions.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout\Dimensions * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/Dimensions/Dimensions.php b/lib/Layout/Dimensions/Dimensions.php index b0ac1e0..603660e 100644 --- a/lib/Layout/Dimensions/Dimensions.php +++ b/lib/Layout/Dimensions/Dimensions.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout\Dimensions * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/ElementBox.php b/lib/Layout/ElementBox.php index b7f2acf..32d116f 100644 --- a/lib/Layout/ElementBox.php +++ b/lib/Layout/ElementBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/FontBox.php b/lib/Layout/FontBox.php index b7e8754..ea66ea0 100644 --- a/lib/Layout/FontBox.php +++ b/lib/Layout/FontBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/FooterBox.php b/lib/Layout/FooterBox.php index b4dfa00..a9bd4c2 100644 --- a/lib/Layout/FooterBox.php +++ b/lib/Layout/FooterBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/HeaderBox.php b/lib/Layout/HeaderBox.php index 3de633e..ef6eb87 100644 --- a/lib/Layout/HeaderBox.php +++ b/lib/Layout/HeaderBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/ImageBox.php b/lib/Layout/ImageBox.php index 04b66e7..487a8cf 100644 --- a/lib/Layout/ImageBox.php +++ b/lib/Layout/ImageBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/InlineBlockBox.php b/lib/Layout/InlineBlockBox.php index 3fa7faf..f7141a0 100644 --- a/lib/Layout/InlineBlockBox.php +++ b/lib/Layout/InlineBlockBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/InlineBox.php b/lib/Layout/InlineBox.php index e250c81..460ee0c 100644 --- a/lib/Layout/InlineBox.php +++ b/lib/Layout/InlineBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -382,7 +382,7 @@ public function addBackgroundColorInstructions(array $element, $pdfX, $pdfY, $wi "{$rules['background-color'][0]} {$rules['background-color'][1]} {$rules['background-color'][2]} rg", "0 0 $width $height re", 'f', - 'Q' + 'Q', ]; $element = array_merge($element, $bgColor); } diff --git a/lib/Layout/LineBox.php b/lib/Layout/LineBox.php index 03097f7..9cc5ad6 100644 --- a/lib/Layout/LineBox.php +++ b/lib/Layout/LineBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/PageGroupBox.php b/lib/Layout/PageGroupBox.php index b250f17..ee60d00 100644 --- a/lib/Layout/PageGroupBox.php +++ b/lib/Layout/PageGroupBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/StyleBox.php b/lib/Layout/StyleBox.php index 861d9b1..5c9bf84 100644 --- a/lib/Layout/StyleBox.php +++ b/lib/Layout/StyleBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableBox.php b/lib/Layout/TableBox.php index b894fe9..6226d37 100644 --- a/lib/Layout/TableBox.php +++ b/lib/Layout/TableBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableCellBox.php b/lib/Layout/TableCellBox.php index 513251d..73d8e2e 100644 --- a/lib/Layout/TableCellBox.php +++ b/lib/Layout/TableCellBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -41,7 +41,7 @@ class TableCellBox extends BlockBox 'top' => '0', 'right' => '0', 'bottom' => '0', - 'left' => '0' + 'left' => '0', ]; /** @@ -197,7 +197,7 @@ public function setInitialBordersWidths(string $top, string $right, string $bott 'top' => $top, 'right' => $right, 'bottom' => $bottom, - 'left' => $left + 'left' => $left, ]; return $this; diff --git a/lib/Layout/TableColumnBox.php b/lib/Layout/TableColumnBox.php index 730b644..5432d3e 100644 --- a/lib/Layout/TableColumnBox.php +++ b/lib/Layout/TableColumnBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableColumnGroupBox.php b/lib/Layout/TableColumnGroupBox.php index eb8a399..001ff22 100644 --- a/lib/Layout/TableColumnGroupBox.php +++ b/lib/Layout/TableColumnGroupBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableFooterGroupBox.php b/lib/Layout/TableFooterGroupBox.php index 90b8fdd..90bcafb 100644 --- a/lib/Layout/TableFooterGroupBox.php +++ b/lib/Layout/TableFooterGroupBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableHeaderGroupBox.php b/lib/Layout/TableHeaderGroupBox.php index 5923fa0..4927ae1 100644 --- a/lib/Layout/TableHeaderGroupBox.php +++ b/lib/Layout/TableHeaderGroupBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableRowBox.php b/lib/Layout/TableRowBox.php index 87462b0..cc38f5b 100644 --- a/lib/Layout/TableRowBox.php +++ b/lib/Layout/TableRowBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableRowGroupBox.php b/lib/Layout/TableRowGroupBox.php index e910924..1fb8881 100644 --- a/lib/Layout/TableRowGroupBox.php +++ b/lib/Layout/TableRowGroupBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TableWrapperBox.php b/lib/Layout/TableWrapperBox.php index 9b23a80..d402778 100644 --- a/lib/Layout/TableWrapperBox.php +++ b/lib/Layout/TableWrapperBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Layout/TextBox.php b/lib/Layout/TextBox.php index ddd341b..22690ee 100644 --- a/lib/Layout/TextBox.php +++ b/lib/Layout/TextBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -148,7 +148,7 @@ public function getInstructions(): string $fontStr, "$textContent Tj", 'ET', - 'Q' + 'Q', ]; $this->drawTextOutline = false; if ($this->drawTextOutline) { @@ -159,7 +159,7 @@ public function getInstructions(): string "1 0 0 1 $pdfX $pdfY cm", "0 0 $textWidth $textHeight re", 'S', - 'Q' + 'Q', ]); } return implode("\n", $element); diff --git a/lib/Layout/WatermarkBox.php b/lib/Layout/WatermarkBox.php index d0e6a50..2f436cb 100644 --- a/lib/Layout/WatermarkBox.php +++ b/lib/Layout/WatermarkBox.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Layout * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Math.php b/lib/Math.php index 26cc07c..667d116 100644 --- a/lib/Math.php +++ b/lib/Math.php @@ -7,7 +7,7 @@ * @package YetiForcePDF * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Basic/ArrayObject.php b/lib/Objects/Basic/ArrayObject.php index 474466c..e50734e 100644 --- a/lib/Objects/Basic/ArrayObject.php +++ b/lib/Objects/Basic/ArrayObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -71,7 +71,7 @@ public function render(): string return implode("\n", [ $this->getRawId() . ' obj', '[ ' . implode(' ', $stringItems) . ' ]', - 'endobj' + 'endobj', ]); } } diff --git a/lib/Objects/Basic/BooleanObject.php b/lib/Objects/Basic/BooleanObject.php index e4b9a58..5225544 100644 --- a/lib/Objects/Basic/BooleanObject.php +++ b/lib/Objects/Basic/BooleanObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Basic/DictionaryObject.php b/lib/Objects/Basic/DictionaryObject.php index 731fbb6..75957ec 100644 --- a/lib/Objects/Basic/DictionaryObject.php +++ b/lib/Objects/Basic/DictionaryObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -109,7 +109,7 @@ public function render(): string { $values = [ $this->getRawId() . ' obj', - '<<' + '<<', ]; foreach ($this->values as $value) { $values[] = ' ' . implode(' ', $value); diff --git a/lib/Objects/Basic/IntegerObject.php b/lib/Objects/Basic/IntegerObject.php index de041ba..6bf5cc4 100644 --- a/lib/Objects/Basic/IntegerObject.php +++ b/lib/Objects/Basic/IntegerObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Basic/NameObject.php b/lib/Objects/Basic/NameObject.php index 276157f..7ddcf13 100644 --- a/lib/Objects/Basic/NameObject.php +++ b/lib/Objects/Basic/NameObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Basic/NullObject.php b/lib/Objects/Basic/NullObject.php index 0a64f85..f296dcd 100644 --- a/lib/Objects/Basic/NullObject.php +++ b/lib/Objects/Basic/NullObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Basic/RealObject.php b/lib/Objects/Basic/RealObject.php index 2e825b5..795c0f6 100644 --- a/lib/Objects/Basic/RealObject.php +++ b/lib/Objects/Basic/RealObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Basic/StreamObject.php b/lib/Objects/Basic/StreamObject.php index 197062f..fd357ac 100644 --- a/lib/Objects/Basic/StreamObject.php +++ b/lib/Objects/Basic/StreamObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -106,7 +106,7 @@ public function render(): string 'stream', $stream, 'endstream', - 'endobj' + 'endobj', ]); } } diff --git a/lib/Objects/Basic/StringObject.php b/lib/Objects/Basic/StringObject.php index f8a73d1..2964aa0 100644 --- a/lib/Objects/Basic/StringObject.php +++ b/lib/Objects/Basic/StringObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Font.php b/lib/Objects/Font.php index f45dc1e..f192655 100644 --- a/lib/Objects/Font.php +++ b/lib/Objects/Font.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -787,6 +787,6 @@ public function render(): string ' /CIDSystemInfo ' . $this->cidSystemInfo->getReference(), ' /CIDToGIDMap ' . $this->cidToGid->getReference(), '>>', - 'endobj']); + 'endobj', ]); } } diff --git a/lib/Objects/FontDescriptor.php b/lib/Objects/FontDescriptor.php index 025e97f..f98913a 100644 --- a/lib/Objects/FontDescriptor.php +++ b/lib/Objects/FontDescriptor.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -57,7 +57,7 @@ public function render(): string ' /MissingWidth ' . $descriptor['MissingWidth'], ' /FontFile2 ' . $this->font->getDataStream()->getReference(), '>>', - 'endobj' + 'endobj', ]); } } diff --git a/lib/Objects/FontEncoding.php b/lib/Objects/FontEncoding.php index ecadb44..f807f60 100644 --- a/lib/Objects/FontEncoding.php +++ b/lib/Objects/FontEncoding.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -36,7 +36,7 @@ public function render(): string ' /Type Encoding', ' /BaseEncoding /' . $this->encoding, '>>', - 'endobj' + 'endobj', ]); } } diff --git a/lib/Objects/GraphicState.php b/lib/Objects/GraphicState.php index 6e03465..7b4bdea 100644 --- a/lib/Objects/GraphicState.php +++ b/lib/Objects/GraphicState.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/ImageStream.php b/lib/Objects/ImageStream.php index 6eeb69a..7028ce0 100644 --- a/lib/Objects/ImageStream.php +++ b/lib/Objects/ImageStream.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -180,7 +180,7 @@ public function render(): string 'stream', $stream, 'endstream', - 'endobj' + 'endobj', ]); } diff --git a/lib/Objects/Meta.php b/lib/Objects/Meta.php index 8b221b3..2f4ffa4 100644 --- a/lib/Objects/Meta.php +++ b/lib/Objects/Meta.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/PdfObject.php b/lib/Objects/PdfObject.php index cbf44be..1f7295c 100644 --- a/lib/Objects/PdfObject.php +++ b/lib/Objects/PdfObject.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/Resource.php b/lib/Objects/Resource.php index 518fa12..217c929 100644 --- a/lib/Objects/Resource.php +++ b/lib/Objects/Resource.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Objects/TextStream.php b/lib/Objects/TextStream.php index 3fe1313..556adab 100644 --- a/lib/Objects/TextStream.php +++ b/lib/Objects/TextStream.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects\Basic * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -156,7 +156,7 @@ public function render(): string 'stream', $stream, 'endstream', - 'endobj' + 'endobj', ]); } } diff --git a/lib/Objects/Trailer.php b/lib/Objects/Trailer.php index 484dbe4..47e4635 100644 --- a/lib/Objects/Trailer.php +++ b/lib/Objects/Trailer.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Objects * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -76,7 +76,7 @@ public function render(): string ' /Root ' . $this->root->getReference(), ' /Size ' . $this->size, ' /Info ' . $this->document->getMeta()->getReference(), - '>>' + '>>', ]); } } diff --git a/lib/Page.php b/lib/Page.php index 3e447d3..8e5b825 100644 --- a/lib/Page.php +++ b/lib/Page.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Document * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -670,7 +670,7 @@ public function setMargins(float $left, float $top, float $right, float $bottom) 'right' => $right, 'bottom' => $bottom, 'horizontal' => $left + $right, - 'vertical' => $top + $bottom + 'vertical' => $top + $bottom, ]; $this->setFormat($this->format); return $this; @@ -1334,7 +1334,7 @@ public function render(): string $this->renderResources(), ' /Contents ' . $this->contentStream->getReference(), '>>', - 'endobj' + 'endobj', ]); } diff --git a/lib/Pages.php b/lib/Pages.php index f94f9b4..db93d7d 100644 --- a/lib/Pages.php +++ b/lib/Pages.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Document * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Color.php b/lib/Style/Color.php index 5ba3ea2..e66234d 100644 --- a/lib/Style/Color.php +++ b/lib/Style/Color.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -173,7 +173,7 @@ class Color 'white' => '#ffffff', 'whitesmoke' => '#f5f5f5', 'yellow' => '#ffff00', - 'yellowgreen' => '#9acd32' + 'yellowgreen' => '#9acd32', ]; /** diff --git a/lib/Style/Normalizer/Background.php b/lib/Style/Normalizer/Background.php index 68344d0..8756566 100644 --- a/lib/Style/Normalizer/Background.php +++ b/lib/Style/Normalizer/Background.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BackgroundColor.php b/lib/Style/Normalizer/BackgroundColor.php index 209266d..3d9ea60 100644 --- a/lib/Style/Normalizer/BackgroundColor.php +++ b/lib/Style/Normalizer/BackgroundColor.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BackgroundImage.php b/lib/Style/Normalizer/BackgroundImage.php index 47a08ec..7b3d54d 100644 --- a/lib/Style/Normalizer/BackgroundImage.php +++ b/lib/Style/Normalizer/BackgroundImage.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Border.php b/lib/Style/Normalizer/Border.php index 91f4340..8f18cea 100644 --- a/lib/Style/Normalizer/Border.php +++ b/lib/Style/Normalizer/Border.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderBottomColor.php b/lib/Style/Normalizer/BorderBottomColor.php index 0ed86bd..2a40168 100644 --- a/lib/Style/Normalizer/BorderBottomColor.php +++ b/lib/Style/Normalizer/BorderBottomColor.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderBottomStyle.php b/lib/Style/Normalizer/BorderBottomStyle.php index 10be7a6..649f73f 100644 --- a/lib/Style/Normalizer/BorderBottomStyle.php +++ b/lib/Style/Normalizer/BorderBottomStyle.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderBottomWidth.php b/lib/Style/Normalizer/BorderBottomWidth.php index b000e90..decd69b 100644 --- a/lib/Style/Normalizer/BorderBottomWidth.php +++ b/lib/Style/Normalizer/BorderBottomWidth.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderCollapse.php b/lib/Style/Normalizer/BorderCollapse.php index 0675132..a86ee07 100644 --- a/lib/Style/Normalizer/BorderCollapse.php +++ b/lib/Style/Normalizer/BorderCollapse.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderColor.php b/lib/Style/Normalizer/BorderColor.php index a8a3852..b9fc3ce 100644 --- a/lib/Style/Normalizer/BorderColor.php +++ b/lib/Style/Normalizer/BorderColor.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderLeftColor.php b/lib/Style/Normalizer/BorderLeftColor.php index f3646ec..cf190a9 100644 --- a/lib/Style/Normalizer/BorderLeftColor.php +++ b/lib/Style/Normalizer/BorderLeftColor.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderLeftStyle.php b/lib/Style/Normalizer/BorderLeftStyle.php index db0521d..d7ec611 100644 --- a/lib/Style/Normalizer/BorderLeftStyle.php +++ b/lib/Style/Normalizer/BorderLeftStyle.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderLeftWidth.php b/lib/Style/Normalizer/BorderLeftWidth.php index 3aff587..eec9f74 100644 --- a/lib/Style/Normalizer/BorderLeftWidth.php +++ b/lib/Style/Normalizer/BorderLeftWidth.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderRightColor.php b/lib/Style/Normalizer/BorderRightColor.php index 6d8a3fd..875a889 100644 --- a/lib/Style/Normalizer/BorderRightColor.php +++ b/lib/Style/Normalizer/BorderRightColor.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderRightStyle.php b/lib/Style/Normalizer/BorderRightStyle.php index 4a97652..b7aef24 100644 --- a/lib/Style/Normalizer/BorderRightStyle.php +++ b/lib/Style/Normalizer/BorderRightStyle.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderRightWidth.php b/lib/Style/Normalizer/BorderRightWidth.php index 1fd881d..a274d23 100644 --- a/lib/Style/Normalizer/BorderRightWidth.php +++ b/lib/Style/Normalizer/BorderRightWidth.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderSpacing.php b/lib/Style/Normalizer/BorderSpacing.php index 7fcc743..f0038c3 100644 --- a/lib/Style/Normalizer/BorderSpacing.php +++ b/lib/Style/Normalizer/BorderSpacing.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderStyle.php b/lib/Style/Normalizer/BorderStyle.php index 145153e..257d170 100644 --- a/lib/Style/Normalizer/BorderStyle.php +++ b/lib/Style/Normalizer/BorderStyle.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderTopColor.php b/lib/Style/Normalizer/BorderTopColor.php index 5db1b8c..fe59817 100644 --- a/lib/Style/Normalizer/BorderTopColor.php +++ b/lib/Style/Normalizer/BorderTopColor.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderTopStyle.php b/lib/Style/Normalizer/BorderTopStyle.php index 6bae1ba..3afae58 100644 --- a/lib/Style/Normalizer/BorderTopStyle.php +++ b/lib/Style/Normalizer/BorderTopStyle.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderTopWidth.php b/lib/Style/Normalizer/BorderTopWidth.php index c64f65c..bf51198 100644 --- a/lib/Style/Normalizer/BorderTopWidth.php +++ b/lib/Style/Normalizer/BorderTopWidth.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/BorderWidth.php b/lib/Style/Normalizer/BorderWidth.php index 7df58ca..a88a952 100644 --- a/lib/Style/Normalizer/BorderWidth.php +++ b/lib/Style/Normalizer/BorderWidth.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -30,6 +30,6 @@ public function normalize($ruleValue, string $ruleName = ''): array 'border-top-width', 'border-right-width', 'border-bottom-width', - 'border-left-width'], $ruleValue); + 'border-left-width', ], $ruleValue); } } diff --git a/lib/Style/Normalizer/BoxSizing.php b/lib/Style/Normalizer/BoxSizing.php index b306035..26b15d1 100644 --- a/lib/Style/Normalizer/BoxSizing.php +++ b/lib/Style/Normalizer/BoxSizing.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Color.php b/lib/Style/Normalizer/Color.php index d69d6fa..c2cb6fe 100644 --- a/lib/Style/Normalizer/Color.php +++ b/lib/Style/Normalizer/Color.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Display.php b/lib/Style/Normalizer/Display.php index aad2f90..9d83d72 100644 --- a/lib/Style/Normalizer/Display.php +++ b/lib/Style/Normalizer/Display.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/FontFamily.php b/lib/Style/Normalizer/FontFamily.php index e25fb32..5dc87f1 100644 --- a/lib/Style/Normalizer/FontFamily.php +++ b/lib/Style/Normalizer/FontFamily.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/FontSize.php b/lib/Style/Normalizer/FontSize.php index 8864e8e..74fe9b2 100644 --- a/lib/Style/Normalizer/FontSize.php +++ b/lib/Style/Normalizer/FontSize.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/FontStyle.php b/lib/Style/Normalizer/FontStyle.php index 54812b5..1924454 100644 --- a/lib/Style/Normalizer/FontStyle.php +++ b/lib/Style/Normalizer/FontStyle.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/FontWeight.php b/lib/Style/Normalizer/FontWeight.php index 9afeb9b..9c33f52 100644 --- a/lib/Style/Normalizer/FontWeight.php +++ b/lib/Style/Normalizer/FontWeight.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Height.php b/lib/Style/Normalizer/Height.php index 270744f..26687d0 100644 --- a/lib/Style/Normalizer/Height.php +++ b/lib/Style/Normalizer/Height.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/LineHeight.php b/lib/Style/Normalizer/LineHeight.php index 54670aa..1793b1a 100644 --- a/lib/Style/Normalizer/LineHeight.php +++ b/lib/Style/Normalizer/LineHeight.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Margin.php b/lib/Style/Normalizer/Margin.php index befc1b9..0710d8b 100644 --- a/lib/Style/Normalizer/Margin.php +++ b/lib/Style/Normalizer/Margin.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/MarginBottom.php b/lib/Style/Normalizer/MarginBottom.php index f3095c2..6533a5d 100644 --- a/lib/Style/Normalizer/MarginBottom.php +++ b/lib/Style/Normalizer/MarginBottom.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/MarginLeft.php b/lib/Style/Normalizer/MarginLeft.php index 5e936e4..80db914 100644 --- a/lib/Style/Normalizer/MarginLeft.php +++ b/lib/Style/Normalizer/MarginLeft.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/MarginRight.php b/lib/Style/Normalizer/MarginRight.php index b488b98..a0eeb20 100644 --- a/lib/Style/Normalizer/MarginRight.php +++ b/lib/Style/Normalizer/MarginRight.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/MarginTop.php b/lib/Style/Normalizer/MarginTop.php index 7e3c772..bca516c 100644 --- a/lib/Style/Normalizer/MarginTop.php +++ b/lib/Style/Normalizer/MarginTop.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/MaxWidth.php b/lib/Style/Normalizer/MaxWidth.php index 9922d29..5dbf9c7 100644 --- a/lib/Style/Normalizer/MaxWidth.php +++ b/lib/Style/Normalizer/MaxWidth.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/MinWidth.php b/lib/Style/Normalizer/MinWidth.php index 8d76759..1ea81f6 100644 --- a/lib/Style/Normalizer/MinWidth.php +++ b/lib/Style/Normalizer/MinWidth.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Normalizer.php b/lib/Style/Normalizer/Normalizer.php index 0c15156..4cf3876 100644 --- a/lib/Style/Normalizer/Normalizer.php +++ b/lib/Style/Normalizer/Normalizer.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -92,7 +92,7 @@ public function getNumberValues($ruleValue, bool $isFont = false) ->setValue($originalSize) ->setOriginal($originalSize . $originalUnit) ->setIsFont($isFont) - ->convert($this->style) + ->convert($this->style), ]; $matchesCount = \count($matches); if ($matchesCount >= 2) { diff --git a/lib/Style/Normalizer/Opacity.php b/lib/Style/Normalizer/Opacity.php index 07a2803..cbcbaff 100644 --- a/lib/Style/Normalizer/Opacity.php +++ b/lib/Style/Normalizer/Opacity.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Overflow.php b/lib/Style/Normalizer/Overflow.php index 807c56a..4979302 100644 --- a/lib/Style/Normalizer/Overflow.php +++ b/lib/Style/Normalizer/Overflow.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Padding.php b/lib/Style/Normalizer/Padding.php index e038b8e..ce1445c 100644 --- a/lib/Style/Normalizer/Padding.php +++ b/lib/Style/Normalizer/Padding.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/PaddingBottom.php b/lib/Style/Normalizer/PaddingBottom.php index c17e063..9a0d15a 100644 --- a/lib/Style/Normalizer/PaddingBottom.php +++ b/lib/Style/Normalizer/PaddingBottom.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/PaddingLeft.php b/lib/Style/Normalizer/PaddingLeft.php index 34716c5..2aaf98c 100644 --- a/lib/Style/Normalizer/PaddingLeft.php +++ b/lib/Style/Normalizer/PaddingLeft.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/PaddingRight.php b/lib/Style/Normalizer/PaddingRight.php index 1283a9b..70ea5be 100644 --- a/lib/Style/Normalizer/PaddingRight.php +++ b/lib/Style/Normalizer/PaddingRight.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/PaddingTop.php b/lib/Style/Normalizer/PaddingTop.php index 386e2eb..8c12d2a 100644 --- a/lib/Style/Normalizer/PaddingTop.php +++ b/lib/Style/Normalizer/PaddingTop.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/TextAlign.php b/lib/Style/Normalizer/TextAlign.php index 249f6b7..4c05cbe 100644 --- a/lib/Style/Normalizer/TextAlign.php +++ b/lib/Style/Normalizer/TextAlign.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Transform.php b/lib/Style/Normalizer/Transform.php index 5d8bd87..2475258 100644 --- a/lib/Style/Normalizer/Transform.php +++ b/lib/Style/Normalizer/Transform.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -24,7 +24,7 @@ public function normalize($ruleValue, string $ruleName = ''): array return $this->normalized; } $normalized = [ - 'transform' => [] + 'transform' => [], ]; $operations = preg_split('/\s+/i', $ruleValue); foreach ($operations as $operation) { diff --git a/lib/Style/Normalizer/TransformOrigin.php b/lib/Style/Normalizer/TransformOrigin.php index 347282f..5539569 100644 --- a/lib/Style/Normalizer/TransformOrigin.php +++ b/lib/Style/Normalizer/TransformOrigin.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -25,7 +25,7 @@ public function normalize($ruleValue, string $ruleName = ''): array } $values = $this->getNumberValues($ruleValue); return [ - 'transform-origin' => [$x, $y] + 'transform-origin' => [$x, $y], ]; } } diff --git a/lib/Style/Normalizer/TransformRotate.php b/lib/Style/Normalizer/TransformRotate.php index 0731710..8488525 100644 --- a/lib/Style/Normalizer/TransformRotate.php +++ b/lib/Style/Normalizer/TransformRotate.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -26,7 +26,7 @@ public function normalize($ruleValue, string $ruleName = ''): array $matches = []; preg_match('/\s?([0-9]+)([a-z]+)?\s?/i', $ruleValue, $matches); return [ - 'rotate' => $matches[1] + 'rotate' => $matches[1], ]; } } diff --git a/lib/Style/Normalizer/VerticalAlign.php b/lib/Style/Normalizer/VerticalAlign.php index e810ced..0aaf6f2 100644 --- a/lib/Style/Normalizer/VerticalAlign.php +++ b/lib/Style/Normalizer/VerticalAlign.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/WhiteSpace.php b/lib/Style/Normalizer/WhiteSpace.php index d778088..4583a07 100644 --- a/lib/Style/Normalizer/WhiteSpace.php +++ b/lib/Style/Normalizer/WhiteSpace.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/Width.php b/lib/Style/Normalizer/Width.php index 8240882..6926db3 100644 --- a/lib/Style/Normalizer/Width.php +++ b/lib/Style/Normalizer/Width.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Normalizer/WordWrap.php b/lib/Style/Normalizer/WordWrap.php index bebbd59..8fe1eda 100644 --- a/lib/Style/Normalizer/WordWrap.php +++ b/lib/Style/Normalizer/WordWrap.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style\Normalizer * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/NumericValue.php b/lib/Style/NumericValue.php index 06a69dc..470a776 100644 --- a/lib/Style/NumericValue.php +++ b/lib/Style/NumericValue.php @@ -6,7 +6,7 @@ * NumericValue class. * * @copyright YetiForce Sp. z o.o. - * @license YetiForce Public License 3.0 (licenses/LicenseEN.txt or yetiforce.com) + * @license MIT * @author Rafal Pospiech */ diff --git a/lib/Style/Style.php b/lib/Style/Style.php index edc36ae..a408e63 100644 --- a/lib/Style/Style.php +++ b/lib/Style/Style.php @@ -7,7 +7,7 @@ * @package YetiForcePDF\Style * * @copyright YetiForce Sp. z o.o - * @license YetiForce Public License v3 + * @license MIT * @author Rafal Pospiech */ @@ -173,7 +173,7 @@ class Style extends \YetiForcePDF\Base 'max-width' => 'none', 'min-width' => '0', 'white-space' => 'normal', - 'opacity' => '1' + 'opacity' => '1', ]; /** @@ -569,7 +569,7 @@ class Style extends \YetiForcePDF\Base 'text-align' => 'center', 'padding' => '1px', 'background-color' => '#ddd', - 'line-height' => '1.6em' + 'line-height' => '1.6em', ], 'thead' => [ 'display' => 'table-header-group', @@ -1467,7 +1467,7 @@ protected function parse() $finalRules['margin-bottom'] = '0'; } elseif (\in_array($finalRules['display'], [ 'table-cell', 'table-row', 'table-row-group', 'table-column', - 'table-column-group', 'table-header-group', 'table-footer-group' + 'table-column-group', 'table-header-group', 'table-footer-group', ])) { $finalRules['margin-top'] = '0'; $finalRules['margin-bottom'] = '0'; diff --git a/renovate.json b/renovate.json index f45d8f1..4f39080 100644 --- a/renovate.json +++ b/renovate.json @@ -1,5 +1,3 @@ { - "extends": [ - "config:base" - ] + "extends": ["config:base"] }