Commit Graph

25 Commits

Author SHA1 Message Date
4a6edc5767 MDL-63349 assignfeedback_editpdf: Rotate submitted image automatically 2019-10-11 15:26:53 +11:00
9432553b1c MDL-61537 assignfeedback_editpdf: Rotate PDF page
Add page rotation feature.
2019-03-15 15:02:33 +11:00
86c577093b MDL-60008 assignfeedback_editpdf: Show warnings
When not all files are available in the online pdf, display a warning to graders
that some files must be downloaded.
2018-12-06 12:11:47 +08:00
efacf3a099 MDL-61052 assign: Do not queue conversions
Identical submissions do not require individual conversions from the document converter. Text passing through
format_text cannot be trusted and is likely to be unique each time, even for the same text.
2018-10-22 11:56:57 +08:00
888d7b585f MDL-61052 assign: Improve strip_images() to avoid HTML5 tags errors 2018-10-22 11:56:33 +08:00
23fe1e2bed MDL-61194 assignfeedback_editpdf: Check if we can convert online text
This patch adds a check to make sure there is a converter available that
will be able to handle html->pdf conversion before adding onlinetext
submissions to the list of files to combine.
2018-05-03 16:44:27 +08:00
2c153c5649 MDL-55459 assignfeedback_editpdf: Add linked comments and markers to PDF 2017-03-24 09:48:42 +00:00
357712eabe MDL-55528 assignfeedback_editpdf: Remove unnecessary escapes 2017-03-10 10:45:47 +08:00
f7a9f1dd0e MDL-55528 assignfeedback_editpdf: Update to use fileconverter_unoconv 2017-03-10 10:45:46 +08:00
1f3556b010 MDL-55762 assignpdf: Handle errored pages better 2017-02-27 09:24:07 +05:30
fecfb4c6fb MDL-56122 assignfeedback_editpdf: Regenerate PDF & page images if blank 2017-02-13 17:23:42 +00:00
f5ba9ac995 MDL-45969 editpdf: The logic for showing a previous attempt is wrong
It originally was only ever going to show static pdfs for older versions,
but this doesn't make sense in the UI for 3.1.
2016-09-30 13:15:00 +08:00
fca211bf05 MDL-55374 mod_assign: Force utf-8 for DOMDocument
This prevents charset issues on some sites.
2016-07-29 10:43:25 +08:00
1356d85151 MDL-52954 core: Change from pandoc to unoconv - it gives better results
Most importantly it retains formatting better, and supports different charsets far better than pandoc.
2016-03-30 11:48:39 +08:00
2e76c14e11 MDL-52954 core: Add a document converter to file_storage
This lets us convert between common office formats. E.g. docx -> pdf
html -> pdf, html -> ods.

This commit also updates assignment editpdf plugin to use this converter
on all compatible submission files.
2016-03-30 11:48:39 +08:00
46686eafeb MDL-49998 editpdf: Clean code to make it more readable.
There was a big proliferation and reuse of $pdf variable
that was making the code hard to read/review. This commit
does change nothing but makes it more readable.

Also adds a couple of Close() calls, not strictly needed
because they don't have opened files. But think it makes
really clearer the scope of every variable. And, for sure
it frees some resources. That cannot be bad.
2015-04-30 10:55:08 +02:00
a916d557cf MDL-49998 unit tests: Close the pdf objects when needed.
When a pdf object is instantiated and any file is loaded
with set_pdf() or load_pdf(), the files remain open until
the pdf is saved with pdf_save() or outputted with Output()..

In that cases is needed to perform an explicit Close() in
order to free resources, parsers and, ultimately, fclose()
the files.

Note that only the uses detected in the editpdf unit tests have
been fixed. I'd recommend to analyse every instance of the tcpdf
libs.

Also, there was one incorrecly reused pdf instance in then
generate_combined_pdf_for_attempt() method. Apparently it was not
leading to problems, but better use a separate instance (#246).
2015-04-28 19:46:50 +02:00
9b65a08095 MDL-47475 mod_assign: Copy files to other group members for editpdf 2014-12-15 08:50:31 +08:00
7dbbb848c6 MDL-45580 assignfeedback_editpdf: Delete draft content on new submission 2014-06-23 14:17:24 +08:00
098f7dd438 MDL-45580 assignfeedback_editpdf: Store a readonly version of the PDF 2014-06-23 14:16:49 +08:00
ac2b4ffc8c MDL-43593 Assign editpdf: More robust handling of errors from TCPDF.
This includes a check to see if there are 0 pages in the combined pdf,
catching exceptions and suppressing php warnings and errors from bad pdf files.

Also - Use TCPDF directly to check if pdfs are compatible. The previous check was
letting dodgy PDFs through which then failed at generation time. This way dodgy
pdfs will get run through ghostscript early and cleaned up.
2014-01-24 16:16:38 +08:00
d40ce26f05 MDL-42031 assginfeedback_editpdf: fix next/previous/select page 2013-11-06 14:13:19 +08:00
aa3e4bdec7 MDL-42028 EditPDF: replace the loading icon by a progress bar 2013-10-28 13:48:22 +08:00
9dbe0313ce MDL-42222 Assignment: Added type check before checking mimetype
Online submission type pass string in files, so added check
to see if file is of type stored_file then check mimetype
2013-10-09 16:53:46 +08:00
5c3864723a MDL-42023 assign: Edit PDF plugin - Damyon's contributions 2013-10-03 09:30:32 +08:00