Skip to content

Latest commit

 

History

History
97 lines (93 loc) · 24.2 KB

File metadata and controls

97 lines (93 loc) · 24.2 KB

1.3.0

Full Changelog

Enhancements

  • Added a Keynote Reader and a Keynote Writer, reading and writing the text, the speaker notes and the images of an Apple Keynote presentation, in #48
  • phpoffice/phpspreadsheet: Allow version 5.0 by @seanlynchwv in #879
  • Added ability to set rounded corner radius by @seanlynchwv in #880
  • Raised the minimum PHP version to 7.4 (dropped 7.1, 7.2 and 7.3) by @slayerfx in #894
  • Added an alternative text (description) on every shape, and not only on graphics, by @dkulyk in #898
  • Added the ability to mark a shape as decorative, so that assistive technologies skip it, by @dkulyk in #899
  • Added an outline on the data points of a chart serie, next to the fill they already had, by @dkulyk in #900
  • DocumentLayout::convertUnit() is public and static, so a value that belongs to no layout can be converted too, by @dkulyk in #921
  • Added Table::setFirstRow() and Table::setBandRow(), so that a table can say whether its first row is a header row, by @dkulyk in #904
  • PowerPoint2007 Reader : Read a group of shapes, and map the shapes it holds out of the coordinate space a:chOff/a:chExt declares, by @Wilkolicious in #870 and @dkulyk in #947
  • Added Shape\RichText\Field, so that a slide number, a slide count or a date can stand inside a sentence rather than take a whole shape, written and read back by the PowerPoint2007 Writer and Reader and by the ODPresentation Writer and Reader, by @dkulyk fixing #958 in #959
  • PowerPoint2007 Writer & Reader : Added a fill behind the data labels of a chart serie, so that a label stays readable over the chart it sits on, by @dkulyk in #963
  • ODPresentation Writer and Reader : Added the baseline of a font, so that a superscript and a subscript are written as style:text-position and read back, in a text run and in a chart font alike, by @dkulyk in #999

Bug fixes

  • PowerPoint2007 Reader : Fixed a node taken out of a node list being treated as an element without being asked whether it is one, which phpoffice/common 1.1.0 no longer promises, by @dkulyk in #1000

  • PowerPoint2007 Writer : Fixed Font::BASELINE_SUPERSCRIPT and Font::BASELINE_SUBSCRIPT being ten times too large, which raised a superscript by 300% and dropped a subscript by 250%, putting it on a line of its own, by @dkulyk fixing #997 in #998

  • PowerPoint2007 Reader : Fixed a colour with an alpha coming back opaque and one character short, taking the first digit of the colour with it, by @dkulyk in #961

  • Both Writers : Fixed a second shape holding the same picture, and a second chart holding the same numbers, being written as a reference to a part that was never put in the archive, which is what PowerPoint offers to repair, by @dkulyk in #948

  • PowerPoint2007 Writer : Fixed a group taking two shape identifiers and using the second, leaving a number no shape carries, by @dkulyk in #947

  • PowerPoint2007 Writer : Fixed a hyperlink, an image, a chart or a comment inside a group inside a group getting no relationship written for it, by @dkulyk in #947

  • PowerPoint2007 Writer : Fixed the rotation of a group of shapes being dropped on save, by @dkulyk in #947

  • Fixed adding custom SVGs by @seanlynchwv in #881

  • Guarded imagedestroy() calls behind a PHP version check (no-op since PHP 8.0, deprecated in PHP 8.5) by @slayerfx in #893

  • Fixed code coverage configuration for PHPUnit 10+ by @slayerfx in #895

  • Fixed static analysis on PHP 8.4 and 8.5 (PHPStan 1.x could not resolve the symbols of PHPUnit 13) by @yasumorishima in #897

  • ODPresentation Writer : Fixed the charts losing their data points, their background, their data labels and the colour of their series, and drawing a hidden legend by @dkulyk in #901

  • Fixed a hyperlink to another slide being written by the ODPresentation Writer as a PowerPoint action string, and read back by neither reader, by @dkulyk in #908

  • ODPresentation Writer : Fixed the header row of a table not being written at all, leaving its column labels announced as ordinary cells by @dkulyk in #905

  • ODPresentation Writer : Fixed a table cell border vanishing unless it was a plain single line, and honoured its dash style by @dkulyk in #907

  • PowerPoint2007 Writer : Fixed the name of a slide being lost on save, and read it back by @dkulyk in #902

  • ODPresentation Writer : Fixed the number of a slide and its date being written as dead text instead of the fields they are by @dkulyk in #913

  • A master slide is no longer born with a white background nobody asked for by @dkulyk in #909

  • ODPresentation Writer : Fixed the background of a master slide being dropped on save by @dkulyk in #912

  • PowerPoint2007 Reader : Fixed a shape that asked for no fill being read as having no fill at all, which crashes the ODPresentation Writer on save, by @dkulyk in #915

  • Fixed a file with no measurable size (an SVG, a video) warning on setPath(), and a fresh object being looked up in the hash table under a null key, by @dkulyk in #920

  • ODPresentation Writer and Reader : Fixed the italic, the bold, the underline and the strikethrough of a font being dropped on save and not read back, in a chart style and in a text run alike, by @dkulyk in #917

  • ODPresentation Writer : Fixed the tick labels of a chart axis being styled from getFont() rather than getTickLabelFont(), which is the font the PowerPoint2007 Writer uses for them, and fixed the strikethrough of those labels being read from the wrong font in the PowerPoint2007 Writer, by @dkulyk in #923

  • PowerPoint2007 Writer and Reader : Fixed the charset of a font being written in hexadecimal, which the schema forbids above 127 and the Reader read as decimal either way, by @dkulyk in #919

  • PowerPoint2007 Reader : Fixed the title of a chart axis, its rotation and the two fonts of the axis not being read back by @dkulyk in #918

  • PowerPoint2007 Reader : Fixed the minor tick mark of an axis being read into its major tick mark, and the outline of the value axis not being read at all, by @dkulyk in #918

  • Fixed the media part of an image whose path carries no extension being named with a trailing dot, and written under no content type, by @dkulyk in #922

  • PowerPoint2007 Reader : Fixed a text run written without a:rPr being dropped, which loses part of the text of a Keynote export, by @Wilkolicious in #871 and @dkulyk in #914

  • Style\Color : Fixed a colour written as a plain RGB being given an alpha it never asked for by @dkulyk in #910

  • PowerPoint2007 Reader : Fixed a slide size written with an explicit type="custom" crashing the reader instead of being read with its own dimensions by @SAY-5 in #929

  • DocumentLayout : Fixed setDocumentLayout() crashing on any layout name it has no preset for, custom among them, by @dkulyk in #930

  • ODPresentation Writer : Fixed a shape whose fill was set to null — which is what the PowerPoint2007 Reader gives a shape that names none — killing the save, so that reading a PPTX and writing it back as ODP works, by @dkulyk in #931

  • ODPresentation Reader : Fixed the alignment of a paragraph being dropped on load, and its direction being read as left to right whatever the file said, by @dkulyk in #927

  • PowerPoint2007 Writer : Fixed Axis::setFormatCode() having no effect, the number format of an axis being taken from the source data instead by @dkulyk in #903

  • Fixed the fill of a table row never reaching the file, in both Writers, by @dkulyk in #911

  • PowerPoint2007 Writer : Fixed a cell losing its own right and bottom borders whenever it had a neighbour on that side by @dkulyk in #906

  • PowerPoint2007 Reader : Fixed a slide number and a date being read back without the font, size and colour they were written with by @dkulyk in #916

  • Fixed a font set to null -- which every font setter accepts -- crashing both Writers on save, by @dkulyk in #924

  • ODPresentation Writer and Reader : Fixed the columns of a text shape being dropped on save and never read back, by @dkulyk in #925

  • Fixed the columns of a text shape always being written left to right, and added RichText::setColumnsRTL() to say the order outright, by @dkulyk in #926

  • Fixed a shadow set to null -- which AbstractShape::setShadow() accepts -- crashing all three Writers on save, by @phili67 in #887 and @dkulyk in #928

  • Fixed the shadow of a line, an autoshape, a group, a text shape and a table being dropped on save, so that a shadow is written whatever the shape wearing it, by @dkulyk fixing #736 in #937

  • Fixed a border colour set to null -- which Border::setColor() accepts -- crashing both Writers on save and Border::getHashCode() on its own, and honoured it as "no colour named" so the line takes the one its theme or its parent style gives it, by @dkulyk in #932

  • ODPresentation Writer : Fixed a text:list-style being written for every paragraph, bulleted or not, and pointed at by nothing, by @dkulyk in #933

  • ODPresentation Reader : Fixed a table not being read at all, so that a presentation holding one -- written by this library or by LibreOffice -- no longer loads with the table missing, by @dkulyk in #941

  • ODPresentation Writer : Fixed the header row of a table being written in the table model a text document uses, which costs the row its contents in LibreOffice, and said it the way a drawing table says it instead, by @dkulyk in #942

  • PowerPoint2007 Writer : Fixed a data label block being written for a series that shows no label, and Series::setDlblNumFormat() being dropped by every chart type but the bar, the doughnut and the pie, by @mindline-analytics and @Progi1984 in #853 and @dkulyk in #939

  • PowerPoint2007 Writer : Fixed a hyperlink set on a line, an autoshape, a table, a chart or a group being dropped on save while its relationship was still written, leaving the slide with a relationship nothing pointed at, by @dkulyk in #938

  • ODPresentation Writer : Fixed a hyperlink set on a shape being written for a picture only, so that a text frame, a table, a chart, a line, a group and a media shape keep the link they were given, by @dkulyk in #944

  • ODPresentation Writer : Fixed the styles of a slide note and of a group inside a group being referenced but never written, and shared one automatic style between everything that writes the same one, by @dkulyk in #935

  • ODPresentation Writer : Fixed a paragraph with a numeric bullet being written as nothing at all, losing its text along with its marker, by @dkulyk in #945

  • ODPresentation Writer : Fixed the paragraph that follows a list being written inside the last item of it, so that a list ends where the paragraphs asking for a marker end, by @dkulyk in #945

  • PowerPoint2007 Reader : Fixed eight of the nine kinds of chart not being recognised at all, so that an area, a bar in three dimensions, a doughnut, a line, a pie, a pie in three dimensions, a radar and a scatter chart are read rather than leaving a plot area with no type, by @dkulyk in #955

  • PowerPoint2007 Reader : Fixed the title, the categories and the values of a chart series never being read out of a file written without a worksheet, which is every file this library writes, and read the two axes a scatter chart names c:xVal and c:yVal, by @dkulyk in #955

  • PowerPoint2007 Writer : Fixed a pattern fill being written with no pattern in it, and the seventeen Fill::FILL_PATTERN_* constants naming the patterns of SpreadsheetML rather than the presets a presentation knows, so that none of them could have named one either, by @dkulyk in #952

  • PowerPoint2007 Reader : Fixed a pattern fill being read as no fill at all, by @dkulyk in #952

  • ODPresentation Writer : Fixed a pattern fill being written as no fill at all, so that the patterns OpenDocument can draw are written as the hatch that draws them and the rest are painted in the colour of the pattern, by @dkulyk in #957

  • ODPresentation Writer : Fixed the kind of field being taken from the shape's placeholder and then written on every run in it, so that a slide number placeholder holding more than one run no longer turns all of them into slide numbers, by @dkulyk in #959

  • ODPresentation Writer : Fixed the paragraph, the text and the graphic style of a slide note being referenced but never written, and shared one automatic style between everything that writes the same one, by @dkulyk in #935

  • ODPresentation Writer : Shared the graphic and the drawing-page styles between everything that writes the same one, the way the paragraph and the text ones are, by @dkulyk in #936

  • PowerPoint2007 Reader : Fixed a shadow's alignment being read off the effect list rather than off the shadow in it, and its colour and alpha being looked for under a preset colour the Writer never writes, and read a shape's wrap back, by @dkulyk in #982

  • ODPresentation Reader : Fixed a paragraph's line spacing being read out of the margin below it, so that every spacing came back as that margin in centimetres and every mode as points, by @dkulyk in #980

  • ODPresentation Reader : Fixed a shape's border being written as a stroke and never read back, so that every shape loaded from a file wore the default border rather than its own, by @dkulyk in #978

  • ODPresentation Reader : Fixed the speaker notes of a slide being written and never read back, so that a note written by this library or by LibreOffice was lost on load, by @dkulyk fixing #724 in #1001

  • PowerPoint2007 Reader and ODPresentation Reader : Fixed a line being written by both Writers and read back by neither, so that a deck loaded and saved again keeps the lines it had, by @dkulyk fixing #987 in #988

  • PowerPoint2007 Writer : Fixed a line that runs right to left being written mirrored, and one that runs up and to the left being written mirrored on both axes, by naming the axis a line is flipped on rather than always naming the vertical one, by @dkulyk fixing #987 in #988

  • PowerPoint97 Reader : Fixed a stream being read one byte past its end, raising Uninitialized string offset once per byte for each structure the parser walks off the end of, by @dkulyk in #995

BC Breaks

  • AbstractShape::setShadow() given null now stores a fresh Shadow instead of the null, so AbstractShape::getShadow() returns Shadow rather than ?Shadow. Code that read it back as null tests the shadow it gets instead (getShadow()->isVisible()); a subclass that overrode it with a nullable return type widens it.
  • \PhpOffice\PhpPresentation\Slide\SlideMaster is constructed without a background. A deck that relied on the white fill it used to write sets one with setBackground(), as the documentation shows.
  • The ODPresentation Writer styles the tick labels of a chart axis from Axis::getTickLabelFont() instead of Axis::getFont(), which is what the PowerPoint2007 Writer has always done. A deck that sized or coloured its ODP labels through getFont() sets them through the other font, as the documentation shows.
  • A table Cell and a table Row are born with Fill::FILL_UNSET rather than Fill::FILL_NONE, so that a cell nobody gave a fill can be told apart from one deliberately left transparent: the first takes the fill of its row, the second stays transparent whatever its row does. Code reading $cell->getFill()->getFillType() on an untouched cell now gets 'unset' where it used to get 'none'.
  • Row::nextCell() no longer overwrites the cell's fill with a copy of the row's. Walking a row used to replace the fill of every cell it passed, including cells that had been given one; the Writers now resolve the row's fill when they write, so nothing has to be copied.
  • A font setter given null now stores a fresh Font instead of the null, so Axis::getFont(), Axis::getTickLabelFont(), Title::getFont(), Legend::getFont(), Series::getFont() and Paragraph::getFont() return Font rather than ?Font. Code that read one of those getters back as null tests the font it gets instead; a subclass that overrode one with a nullable return type widens it.
  • AbstractShape::getFill() and Shape\Chart\Series::getFill() return a Fill rather than a ?Fill, and never hand back a null. setFill(null) is deprecated and now stores a Fill of type Fill::FILL_UNSET, which the Writers leave out of the file exactly as they left out a null. Code testing the result of getFill() for null keeps compiling; the branch simply never fires.
  • The seventeen Fill::FILL_PATTERN_* constants that named a SpreadsheetML pattern (FILL_PATTERN_DARKDOWN said darkDown, FILL_PATTERN_MEDIUMGRAY said mediumGray) now hold the DrawingML preset each was asking for (dkDnDiag, pct50). The names are kept and deprecated; code passing them keeps working, and gets the pattern it named instead of no pattern at all. Code comparing getFillType() against a string literal such as 'darkDown' compares against the constant instead. The 54 presets are available under their own names, as the documentation shows.