1. 02 Oct, 2018 1 commit
  2. 27 Nov, 2017 2 commits
  3. 21 Nov, 2017 1 commit
  4. 13 Nov, 2017 1 commit
  5. 04 Feb, 2017 1 commit
  6. 25 Jan, 2017 2 commits
  7. 22 Jan, 2017 1 commit
  8. 15 Jan, 2017 1 commit
  9. 08 Jan, 2017 2 commits
    • Craig Watson's avatar
      Adjust text item size upon loading to account for platform-to-platform variability · ae380e4e
      Craig Watson authored
      The same font, in the same point size, can be displayed differently
      depending on platform (this is a Qt limitation). This can lead to text
      items being the wrong size when importing a document created on a
      different computer.
      
      As a workaround, when saving a text item to SVG, the size of 1pt in
      pixels is calculated and saved. Upon loading, this value is calculated
      again and, if it is different from the saved value, the text item is
      scaled accordingly.
      
      Thus, any document created from this version onward will have
      correctly-scaled text boxes. If an old document (not containing a
      pixel-per-point attribute for text items) is loaded, the scene is marked
      as modified to make sure that all text items are then saved with the
      pixels-per-point value (even if the document is not edited). This allows
      old documents to be "fixed" by simply opening them once from a new
      version of OpenBoard.
      
      save text item font size in pixels, and scale it on load
      
      fixed loading of text item pixel height
      
      Save and load pixels-per-point rather than text pixel height
      
      Upon loading a text item from SVG, make sure that it will be saved with a pixel-per-point value
      ae380e4e
    • Craig Watson's avatar
  10. 06 Nov, 2016 1 commit
    • Craig Watson's avatar
      Fix saving of polygons' fill rule · 8365f2f7
      Craig Watson authored
      Up until now, the fill rule of a polygon was always saved as even-odd,
      despite the fact that in most if not all cases, polygons are drawn with
      winding fill within OpenBoard.
      Saving is now fixed, but there is no way to know upon loading whether
      the polygon was correctly saved or whether; so for now, we just set the
      fill rule to Winding when loading a polygon.
      8365f2f7
  11. 10 Sep, 2016 1 commit
  12. 03 Sep, 2016 1 commit
  13. 02 Sep, 2016 1 commit
    • Craig Watson's avatar
      User-resizable background grid: · 081dbee1
      Craig Watson authored
      - The background selection palette now includes a slider to change the
      size of the background grid. Default min/max values are 16 and 64px,
      defined in UBSettings. Grid resizes dynamically as the slider is moved.
      - Measuring tools' (ruler, triangle) markers follow grid size: 1 square
      of the background grid corresponds to 1cm
      - Grid size can be different for each page of a document
      - Grid size is saved in the .svg
      - Documents with a background grid but no specified grid size follow the
      default size defined in UBSettings.
      
      Previously, grid size was calculated based on DPI, which can vary from
      one OS, computer or display to the next. This new setting allows
      documents to be migrated from one machine to another with no unexpected
      changes in grid size happening. It also makes it easy to correct any
      problems importing old documents (whose grid size might be smaller or
      larger than expected when imported on a new version of OpenBoard).
      081dbee1
  14. 27 Jun, 2016 1 commit
    • Craig Watson's avatar
      Fixes to import and export of files containing PDFs · 3abf154d
      Craig Watson authored
      The scale of PDF items was sometimes badly calculated when opening a
      document made with a previous version of OpenBoard or made on another
      computer.
      
      Specifically, this solves the following issues:
      
      - PDF scale calculation in documents that did not specify the pageDPI
      used to render the PDF (happened with documents created with some old
      versions of OpenBoard)
      
      - PDF scale calculation in multi-page documents (it was set correctly
      for the first page, but not the following ones)
      3abf154d
  15. 22 Jun, 2016 1 commit
    • Craig Watson's avatar
      Document's pageDpi is now stored in UBDocumentProxy rather than in UBSettings · 3995d007
      Craig Watson authored
      This fixes an issue where if one document was imported with a different
      DPI than the current one, any document created thereafter would have
      this same value (which could then cause problems if a PDF was added to
      that new document).
      
      Saving this value to UBDocumentProxy not only makes more sense, it also
      fixes this issue.
      3995d007
  16. 13 May, 2016 1 commit
  17. 26 Apr, 2016 1 commit
  18. 25 Apr, 2016 1 commit
  19. 20 Apr, 2016 1 commit
  20. 07 Mar, 2016 1 commit
  21. 01 Mar, 2016 1 commit
    • Craig Watson's avatar
      Overhaul of UBGraphicsMediaItem class · fe9affee
      Craig Watson authored
      - Removed inheritance of UBGraphicsProxyWidget; cleaned up related code
      - Added two children classes: UBGraphicsVideoItem and
      UBGraphicsAudioItem. UBGraphicsMediaItem is now an abstract class.
      - Better encapsulation; the Scene and other external classes no longer
      access the mediaObject directly
      
      There is now less distinction between audio and video items to outside
      code: apart from the UBSvgSubsetAdaptor, there is no need to know
      whether a media item holds a video or audio file. Creation is handled
      through the static function `UBGraphicsMediaItem::createMediaItem(URL,
      parent)`
      fe9affee
  22. 24 Feb, 2016 1 commit
  23. 17 Feb, 2016 2 commits
    • Craig Watson's avatar
      Removed forgotten debug message · c619a9db
      Craig Watson authored
      c619a9db
    • Craig Watson's avatar
      Fixed pen strokes not being loaded in right position · 0879179c
      Craig Watson authored
      - Modified UBvgSubsetAdaptor to correctly save and load strokes, so the
      transform matrices that were saved are now loaded correctly.
      
      - Added handling of mousePress / Move / Release events to
      UBGraphicsStrokesGroup, so that the transform matrix is calculated and
      stored after moving a pen stroke directly (by clicking on it, and not on
      its frame). Note: this duplicates quite a bit of code that is in
      UBGraphicsDelegateFrame. It may be best to go back and modify both
      classes so that the same functions can be called when moving a stroke.
      0879179c
  24. 15 Feb, 2016 1 commit
  25. 23 Dec, 2015 1 commit
  26. 21 Dec, 2015 1 commit
    • Craig Watson's avatar
      Corrected pen stroke duplication issue (see below) · 6faeea9d
      Craig Watson authored
      Presumably due to the change in how pen strokes were saved to file (commit
      8ed2e245), pen strokes with pressure levels were badly saved. They were
      converted to lines instead of polygons, meaning that every time a page
      was saved or duplicated, the lines would look worse and worse -- and
      artefacts would appear.
      
      This should now be fixed.
      6faeea9d
  27. 14 Dec, 2015 1 commit
    • Craig Watson's avatar
      Quick fix for issue #14 · 2cec22c9
      Craig Watson authored
      Page DPI is now saved as the DPI that was read when opening the file.
      While not a perfectly fool-proof fix, it will at least allow files to be
      migrated between OB 1.02 and 1.10.
      2cec22c9
  28. 11 Dec, 2015 1 commit
    • Craig Watson's avatar
      Fix video loading from file · 76636f73
      Craig Watson authored
      - Added an overload for setMatrix in UBGraphicsMediaItem, to propagate
        matrix changes to the child videoItem
      - Upon loading a video, the child videoItem is now added correctly, and
        set to the right position
      76636f73
  29. 10 Dec, 2015 2 commits
  30. 09 Dec, 2015 1 commit
  31. 08 Dec, 2015 1 commit
    • Craig Watson's avatar
      Removed export of polygons outside of groups · 8ed2e245
      Craig Watson authored
      The lines removed in this commit led to (presumably) unintended
      behavior: when saving a document, pen strokes were saved not as a group,
      but just as their constituent polygons.
      This meant that the following block of code, that handles saving pen
      strokes correctly, was never executed.
      
      This doesn't fix the z-Value issue (#12), but it seems to be a step in the right
      direction.
      8ed2e245
  32. 09 Nov, 2015 1 commit
  33. 06 Nov, 2015 1 commit
  34. 05 Nov, 2015 1 commit
  35. 25 Apr, 2014 1 commit