diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/qpdf/QPDFObjectHandle.hh | 5 | ||||
-rw-r--r-- | include/qpdf/QUtil.hh | 9 |
2 files changed, 13 insertions, 1 deletions
diff --git a/include/qpdf/QPDFObjectHandle.hh b/include/qpdf/QPDFObjectHandle.hh index 4c986af7..41646b79 100644 --- a/include/qpdf/QPDFObjectHandle.hh +++ b/include/qpdf/QPDFObjectHandle.hh @@ -476,6 +476,11 @@ class QPDFObjectHandle static QPDFObjectHandle newReal(std::string const& value); QPDF_DLL static QPDFObjectHandle newReal(double value, int decimal_places = 0); + // ABI: combine with other newReal by adding trim_trailing_zeroes + // above as an optional parameter with a default of true. + QPDF_DLL + static QPDFObjectHandle newReal(double value, int decimal_places, + bool trim_trailing_zeroes); QPDF_DLL static QPDFObjectHandle newName(std::string const& name); QPDF_DLL diff --git a/include/qpdf/QUtil.hh b/include/qpdf/QUtil.hh index 5b1f8aae..769c5fd7 100644 --- a/include/qpdf/QUtil.hh +++ b/include/qpdf/QUtil.hh @@ -47,9 +47,16 @@ namespace QUtil QPDF_DLL std::string int_to_string_base(long long, int base, int length = 0); QPDF_DLL - std::string uint_to_string_base(unsigned long long, int base, int length = 0); + std::string uint_to_string_base(unsigned long long, int base, + int length = 0); QPDF_DLL std::string double_to_string(double, int decimal_places = 0); + // ABI: combine with other double_to_string by adding + // trim_trailing_zeroes above as an optional parameter with a + // default of true. + QPDF_DLL + std::string double_to_string(double, int decimal_places, + bool trim_trailing_zeroes); // These string to number methods throw std::runtime_error on // underflow/overflow. |