Re: [Therion] Creating PDF/A map files

2020-10-22 Thread Martin Budaj
On Thu, Oct 22, 2020 at 6:39 PM Martin Sluka via Therion
 wrote:
>
> http://texdoc.net/texmf-dist/doc/latex/pdfx/pdfx.pdf

Hi,
this unfortunately requires LaTeX, while Therion uses Plain TeX. I'm
afraid I don't see any viable option to produce PDF/A directly from
Therion without reimplementing the functionality of that package in
Plain TeX.
Martin
___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Creating PDF/A map files

2020-10-22 Thread Martin Sluka via Therion
http://texdoc.net/texmf-dist/doc/latex/pdfx/pdfx.pdf

Martin


> 22. 10. 2020 v 18:30, Tarquin Wilton-Jones via Therion :
> 
>> we need tranparency (I think)
> 
> Render your survey to SVG, and you will very quickly see that yes, you
> need transparency, wherever you get a lot of overlaps. The only other
> option would be for Therion to implement its own opacity engine and
> output a computed rendering, and I doubt anyone here wants to implement
> that.
> 
>> We can gzip the files after creation but a
>> foo.PDF.gz is a lot less handy than a foo.PDF with internal
>> compression.
> 
> And Windows users would not know what to do with it.
> 
> Does it take much space to bundle the fonts? Those can be extremely
> large in some cases (though I guess that part is simplified by Therion
> using just one font).
> 
> If those are bundled, isn't it pretty much self contained?
> 
> I personally see no need to remove compression. It's not like a PDF
> viewer is going to somehow lose support for it in future. Browsers have
> not dropped support for deflate or gzip. If anything, viewers (for as
> long as PDF viewers exist) will gain support for things like that over
> time, rather than losing it.
> ___
> Therion mailing list
> Therion@speleo.sk
> https://mailman.speleo.sk/listinfo/therion

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Creating PDF/A map files

2020-10-22 Thread Tarquin Wilton-Jones via Therion
> we need tranparency (I think)

Render your survey to SVG, and you will very quickly see that yes, you
need transparency, wherever you get a lot of overlaps. The only other
option would be for Therion to implement its own opacity engine and
output a computed rendering, and I doubt anyone here wants to implement
that.

> We can gzip the files after creation but a
> foo.PDF.gz is a lot less handy than a foo.PDF with internal
> compression.

And Windows users would not know what to do with it.

Does it take much space to bundle the fonts? Those can be extremely
large in some cases (though I guess that part is simplified by Therion
using just one font).

If those are bundled, isn't it pretty much self contained?

I personally see no need to remove compression. It's not like a PDF
viewer is going to somehow lose support for it in future. Browsers have
not dropped support for deflate or gzip. If anything, viewers (for as
long as PDF viewers exist) will gain support for things like that over
time, rather than losing it.
___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Creating PDF/A map files

2020-10-22 Thread Wookey
On 2020-10-22 08:17 -0500, Bill Gee wrote:
>The new feature I propose is to modify the PDF creation code so that it
>produces files that are PDF/A version 1b (or possibly version 2)
>compliant.
>https://en.wikipedia.org/wiki/PDF/A

Therion would need to use PDF/A-2 because we need tranparency (I think).

And whilst this is mostly sensible why on earth do they think banning
LZW compression is a good idea? That's probably why your file expanded
from 4 to 52MB. The last patents on it expired in 2004 and free
implementations have been available for decades. If it wasn't for that
we could have made it a standard output format (because self-contained
files are a very good thing, and I'd expect my therion PDFs to already
have this property). We can gzip the files after creation but a
foo.PDF.gz is a lot less handy than a foo.PDF with internal
compression.

Wookey
-- 
Principal hats:  Linaro, Debian, Wookware, ARM
http://wookware.org/


signature.asc
Description: PGP signature
___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Creating PDF/A map files

2020-10-22 Thread Xavier Robert
Hi, 

This is a good idea, but I totally agree with Benedikt, the source files (both 
.th and .th2) are the most important files as this are text files that contains 
all the information of the survey and the drawing. For me, these are the files 
that should be archived and shared.

Moreover, if I good understood, the pdf/A-1 does not allow transparency and 
layers. I am not a pdf specialist, but it seems to me that is not compatible 
with Therion outputs (for instance, If I open a pdf from Therion in 
Illustrator, I see sub-layers). Pdf/A-2 seems to be better as it allows both 
transparency and layers.

Cheers,

Xavier

> Le 22 oct. 2020 à 15:43, Benedikt Hallinger  a écrit :
> 
> Hi,
> instalation of veraPDF was straightforward.
> 
> For a test run i get this:
>  failedChecks="1846">
> This will be a long road.
> 
> But your idea is quite good, as it will preserve valuable work.
> OTOH the PDFs are just results, what is really valuable would be the source 
> files. And they are pretty good to archive already, as they are just text 
> files!
> Therion should be fine to run a long time into the future, hopefully. And as 
> its OpenSource, there are no constraints whatsoever to fix bugs in the future 
> to make it work again...
> 
> 
> Am 2020-10-22 15:17, schrieb Bill Gee:
>> Hello everyone -
>> I propose a new feature for Therion. This will probably take some
>> work, and I am sure there will be discussion about how to implement
>> it.
>> It seems to me that the maps we produce with Therion are likely going
>> to be stored for a very long time, perhaps running into multiple tens
>> of years. As we all know, computer technology over that amount of time
>> will change drastically. Just think about the contrast in both
>> hardware and software in the last 25 years - from Windows 95 running
>> on 486dx processors to Linux and Windows 10 running on i7 and i9
>> processors.
>> I think we have some obligation to make sure the cave maps we generate
>> are still usable many years from now. Saving them in PDF format is a
>> large - but incomplete - step in that direction.
>> The new feature I propose is to modify the PDF creation code so that
>> it produces files that are PDF/A version 1b (or possibly version 2)
>> compliant.
>> https://en.wikipedia.org/wiki/PDF/A  [1]
>> I have checked all of the PDF files I created in Therion, and none of
>> them are flagged as PDF/A compliant. It is possible that they are, in
>> fact, compliant and simply do not have the necessary flag. The experts
>> can check that against the PDF/A specifications.
>> Existing PDF documents can be checked for PDF/A compliance with a
>> command-line tool called "verapdf". The web site for that tool is
>> https://openpreservation.org/products/verapdf/ 
>>  [2]
>> It is possible to use GhostScript to transform an existing PDF into a
>> PDF/A file. The command line is daunting.
>> https://www.mcbsys.com/blog/2018/10/batch-convert-pdf-to-pdf-a-2018-edition/ 
>> 
>> [3]
>> I tried the GhostScript conversion on one of my Therion maps.
>> Immediately at startup it produced this message three times:
>> "GPL Ghostscript 9.53.3: UTF16BE text string detected in DOCINFO
>> cannot be represented in XMP for PDF/A1, reverting to normal PDF
>> output"
>> The process continued running and took about 10 minutes. The resulting
>> file failed verapdf analysis. It also increased the file size from 4.3
>> megabytes to over 52 megabytes! The output file displayed correctly in
>> Okular.
>> I do not have any idea how Therion produces PDF files. It probably
>> uses some combination of TeX and GhostScript to get it done. The new
>> feature may be as simple as adding some additional parameters to the
>> command lines that call the external programs.
>> Let the discussion begin! :-)
>> --
>> Bill Gee
>> Links:
>> --
>> [1] https://en.wikipedia.org/wiki/PDF/A 
>> [2] https://openpreservation.org/products/verapdf/ 
>> 
>> [3] 
>> https://www.mcbsys.com/blog/2018/10/batch-convert-pdf-to-pdf-a-2018-edition/ 
>> 
>> ___
>> Therion mailing list
>> Therion@speleo.sk 
>> https://mailman.speleo.sk/listinfo/therion 
>> 
> ___
> Therion mailing list
> Therion@speleo.sk 
> https://mailman.speleo.sk/listinfo/therion 
> 
___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Creating PDF/A map files

2020-10-22 Thread Benedikt Hallinger

Hi,
instalation of veraPDF was straightforward.

For a test run i get this:
failedChecks="1846">

This will be a long road.

But your idea is quite good, as it will preserve valuable work.
OTOH the PDFs are just results, what is really valuable would be the 
source files. And they are pretty good to archive already, as they are 
just text files!
Therion should be fine to run a long time into the future, hopefully. 
And as its OpenSource, there are no constraints whatsoever to fix bugs 
in the future to make it work again...



Am 2020-10-22 15:17, schrieb Bill Gee:

Hello everyone -

I propose a new feature for Therion. This will probably take some
work, and I am sure there will be discussion about how to implement
it.

It seems to me that the maps we produce with Therion are likely going
to be stored for a very long time, perhaps running into multiple tens
of years. As we all know, computer technology over that amount of time
will change drastically. Just think about the contrast in both
hardware and software in the last 25 years - from Windows 95 running
on 486dx processors to Linux and Windows 10 running on i7 and i9
processors.

I think we have some obligation to make sure the cave maps we generate
are still usable many years from now. Saving them in PDF format is a
large - but incomplete - step in that direction.

The new feature I propose is to modify the PDF creation code so that
it produces files that are PDF/A version 1b (or possibly version 2)
compliant.

https://en.wikipedia.org/wiki/PDF/A [1]

I have checked all of the PDF files I created in Therion, and none of
them are flagged as PDF/A compliant. It is possible that they are, in
fact, compliant and simply do not have the necessary flag. The experts
can check that against the PDF/A specifications.

Existing PDF documents can be checked for PDF/A compliance with a
command-line tool called "verapdf". The web site for that tool is

https://openpreservation.org/products/verapdf/ [2]

It is possible to use GhostScript to transform an existing PDF into a
PDF/A file. The command line is daunting.

https://www.mcbsys.com/blog/2018/10/batch-convert-pdf-to-pdf-a-2018-edition/
[3]

I tried the GhostScript conversion on one of my Therion maps.
Immediately at startup it produced this message three times:

"GPL Ghostscript 9.53.3: UTF16BE text string detected in DOCINFO
cannot be represented in XMP for PDF/A1, reverting to normal PDF
output"

The process continued running and took about 10 minutes. The resulting
file failed verapdf analysis. It also increased the file size from 4.3
megabytes to over 52 megabytes! The output file displayed correctly in
Okular.

I do not have any idea how Therion produces PDF files. It probably
uses some combination of TeX and GhostScript to get it done. The new
feature may be as simple as adding some additional parameters to the
command lines that call the external programs.

Let the discussion begin! :-)

--

Bill Gee



Links:
--
[1] https://en.wikipedia.org/wiki/PDF/A
[2] https://openpreservation.org/products/verapdf/
[3] 
https://www.mcbsys.com/blog/2018/10/batch-convert-pdf-to-pdf-a-2018-edition/

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


[Therion] Creating PDF/A map files

2020-10-22 Thread Bill Gee
Hello everyone -

I propose a new feature for Therion.  This will probably take some work, and I 
am sure there will be discussion about how to implement it.

It seems to me that the maps we produce with Therion are likely going to be 
stored for a very long time, perhaps running into multiple tens of years.  As 
we all know, computer technology over that amount of time will change 
drastically.  Just think about the contrast in both hardware and software in 
the last 25 years - from Windows 95 running on 486dx processors to Linux and 
Windows 10 running on i7 and i9 processors.

I think we have some obligation to make sure the cave maps we generate are 
still usable many years from now.  Saving them in PDF format is a large - but 
incomplete - step in that direction.

The new feature I propose is to modify the PDF creation code so that it 
produces files that are PDF/A version 1b (or possibly version 2) compliant.

https://en.wikipedia.org/wiki/PDF/A 

I have checked all of the PDF files I created in Therion, and none of them are 
flagged as PDF/A compliant.  It is possible that they are, in fact, compliant 
and simply do not have the necessary flag.  The experts can check that against 
the PDF/A specifications.

Existing PDF documents can be checked for PDF/A compliance with a command-line 
tool called "verapdf".  The web site for that tool is

https://openpreservation.org/products/verapdf/ 

It is possible to use GhostScript to transform an existing PDF into a PDF/A 
file.  The command line is daunting.

https://www.mcbsys.com/blog/2018/10/batch-convert-pdf-to-pdf-a-2018-edition/ 

I tried the GhostScript conversion on one of my Therion maps.  Immediately at 
startup it produced this message three times:

"GPL Ghostscript 9.53.3: UTF16BE text string detected in DOCINFO cannot be 
represented in XMP for PDF/A1, reverting to normal PDF output"

The process continued running and took about 10 minutes.  The resulting file 
failed verapdf analysis.  It also increased the file size from 4.3 megabytes to 
over 52 megabytes!  The output file displayed correctly in Okular.

I do not have any idea how Therion produces PDF files.  It probably uses some 
combination of TeX and GhostScript to get it done.  The new feature may be as 
simple as adding some additional parameters to the command lines that call the 
external programs.

Let the discussion begin!  :-)

-- 
Bill Gee

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Tarquin Wilton-Jones via Therion
> Is the solution to the problem and very easy.

Bravo Xavier.

https://therion.speleo.sk/wiki/tips#drawing_a_symbol_on_the_legend_which_is_not_used_on_the_map
___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Martin Sluka via Therion
This is the trick! 

Thanks!

Martin

> 22. 10. 2020 v 13:23, Xavier Robert :
> 
> Hi,
> 
> Or a possibility : In one of your th2 for the plan, draw the missing 
> symbol(s) from your plan that appears in your extended elevation, but draw 
> them outside of the cave’s walls, and with the option -clip on. 
> I have not tried, but they should then appear in the legend of your plan-pdf, 
> but not in the plan view.
> 
> Cheers,
> 
> Xavier
> 
>> Le 22 oct. 2020 à 13:00, Tarquin Wilton-Jones via Therion 
>>  a écrit :
>> 
>> On 22/10/2020 11:44, Martin Sluka via Therion wrote:
>>> Sorry, invisible symbols are not included in legend.
>> 
>> you might be able to include a custom symbol that looks the same, which
>> chooses to draw nothing when not in the legend. that's quite a hack though.
>> 
>> ___
>> Therion mailing list
>> Therion@speleo.sk
>> https://mailman.speleo.sk/listinfo/therion
> 
> ___
> Therion mailing list
> Therion@speleo.sk
> https://mailman.speleo.sk/listinfo/therion

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Evaristo Quiroga

Thank you Xavier.

Is the solution to the problem and very easy.

Cheers,

Evaristo.

El 22/10/2020 a las 13:23, Xavier Robert escribió:

Hi,

Or a possibility : In one of your th2 for the plan, draw the missing symbol(s) 
from your plan that appears in your extended elevation, but draw them outside 
of the cave’s walls, and with the option -clip on.
I have not tried, but they should then appear in the legend of your plan-pdf, 
but not in the plan view.

Cheers,

Xavier


Le 22 oct. 2020 à 13:00, Tarquin Wilton-Jones via Therion  a 
écrit :

On 22/10/2020 11:44, Martin Sluka via Therion wrote:

Sorry, invisible symbols are not included in legend.

you might be able to include a custom symbol that looks the same, which
chooses to draw nothing when not in the legend. that's quite a hack though.

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion



___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Xavier Robert
Hi,

Or a possibility : In one of your th2 for the plan, draw the missing symbol(s) 
from your plan that appears in your extended elevation, but draw them outside 
of the cave’s walls, and with the option -clip on. 
I have not tried, but they should then appear in the legend of your plan-pdf, 
but not in the plan view.

Cheers,

Xavier

> Le 22 oct. 2020 à 13:00, Tarquin Wilton-Jones via Therion  
> a écrit :
> 
> On 22/10/2020 11:44, Martin Sluka via Therion wrote:
>> Sorry, invisible symbols are not included in legend.
> 
> you might be able to include a custom symbol that looks the same, which
> chooses to draw nothing when not in the legend. that's quite a hack though.
> 
> ___
> Therion mailing list
> Therion@speleo.sk
> https://mailman.speleo.sk/listinfo/therion

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Tarquin Wilton-Jones via Therion
On 22/10/2020 12:00, Tarquin Wilton-Jones via Therion wrote:
> On 22/10/2020 11:44, Martin Sluka via Therion wrote:
>> Sorry, invisible symbols are not included in legend.
> 
> you might be able to include a custom symbol that looks the same, which
> chooses to draw nothing when not in the legend. that's quite a hack though.

Should be this easy, I think (not that I have tested it):

text en "point u:placeholder1" "the title you want"
code metapost
  def p_u_placeholder1 (expr P,R,S,A)=
T:=identity shifted P;
  enddef;
  initsymbol("p_u_placeholder1");
  def p_u_placeholder1_legend (expr P,R,S,A)=
p_therealsymbolyouwanted_SKBB(P,R,S,A);
  enddef;
endcode

Now on your plan, add a point "u" -subtype placeholder1
___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Tarquin Wilton-Jones via Therion
On 22/10/2020 11:44, Martin Sluka via Therion wrote:
> Sorry, invisible symbols are not included in legend.

you might be able to include a custom symbol that looks the same, which
chooses to draw nothing when not in the legend. that's quite a hack though.

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Martin Sluka via Therion
Sorry, invisible symbols are not included in legend.

Martin


> 22. 10. 2020 v 11:33, Martin Sluka via Therion :
> 
> I think you may add them to plan as invisible. But not sure they’ll be in the 
> legend.
> 
> Martin
> 
> 
>> 21. 10. 2020 v 23:08, Evaristo Quiroga > >:
>> 
>> Hy,
>> 
>> I have create a map with extended profile and plant together, with the 
>> following commands: 
>> export map -projection  extended -o alzado.pdf -layout Layout_ECB \
>> -layout-map-header 0 0 off \
>> -layout-map-header 0 0 nw \
>> -layout empty_header
>>
>> export map -projection plan -o ./00_OUTPUT/EstebanFelipe_TOPO_800.pdf 
>> -layout Layout_ECB \
>>-layout-map-image 35 110 s "./alzado.pdf" \
>> -layout-map-header -30 80 nw\
>>-layout-legend on\
>>-layout recuadro\
>>-layout longitud \
>>-layout-map-image 102 0 e "./LOGO_ECG.png"
>> 
>> system "del alzado.pdf"
>> 
>> 
>> I have a problem. I have lost the symbols that appear in the legend of the 
>> extended profile and that are not in the legend of the plant.
>> 
>> How can I force the legend of the plant to include symbols not used in it?
>> 
>> Regards,
>> 
>> Evaristo. 
>> 
>> 
>> 
>> ___
>> Therion mailing list
>> Therion@speleo.sk 
>> https://mailman.speleo.sk/listinfo/therion
> 
> ___
> Therion mailing list
> Therion@speleo.sk
> https://mailman.speleo.sk/listinfo/therion

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion


Re: [Therion] Include additional symbols in the legend

2020-10-22 Thread Martin Sluka via Therion
I think you may add them to plan as invisible. But not sure they’ll be in the 
legend.

Martin


> 21. 10. 2020 v 23:08, Evaristo Quiroga :
> 
> Hy,
> 
> I have create a map with extended profile and plant together, with the 
> following commands: 
> export map -projection  extended -o alzado.pdf -layout Layout_ECB \
> -layout-map-header 0 0 off \
> -layout-map-header 0 0 nw \
> -layout empty_header
>
> export map -projection plan -o ./00_OUTPUT/EstebanFelipe_TOPO_800.pdf 
> -layout Layout_ECB \
>-layout-map-image 35 110 s "./alzado.pdf" \
> -layout-map-header -30 80 nw\
>-layout-legend on\
>-layout recuadro\
>-layout longitud \
>-layout-map-image 102 0 e "./LOGO_ECG.png"
> 
> system "del alzado.pdf"
> 
> 
> I have a problem. I have lost the symbols that appear in the legend of the 
> extended profile and that are not in the legend of the plant.
> 
> How can I force the legend of the plant to include symbols not used in it?
> 
> Regards,
> 
> Evaristo. 
> 
> 
> 
> ___
> Therion mailing list
> Therion@speleo.sk
> https://mailman.speleo.sk/listinfo/therion

___
Therion mailing list
Therion@speleo.sk
https://mailman.speleo.sk/listinfo/therion