TeXCenterFigure being overwritten when opening a image.
Brought to you by:
tsy
Hello. Seems like it's hard to find a delphi compiler, so I figured I'd try reporting the problem:
Issue:
I've set these settings in TpX.ini:
TeXCenterFigure_Default=0
TeXFigure_Default=none
This way the tpx image wont be a figure and won't be centered. This all works fine when you first create a new image. However say close tpx.exe and later open the image by:
tpx.exe myimage.TpX
The next time you save the file it will have added \centering.
It seems like when you use the settings I have it adds:
TeXFigure="none">
to the TpX header, atleast when you start a fresh new image. I believe it actually should be:
TeXCenterFigure="0" TeXFigure="none"
Because when you run tpx.exe myimage.TpX later on, it will append:
TeXCenterFigure="1" TeXFigure="none"
Rather than listening to TpX.ini
Saw that you recently commented here. I hope you can help me with this.
Up on further investigation:
It seems like the problem appears in
InOut.pas. Line 5431:I believe it's better to set it to
TeXCenterFigure_Defaultlike so:Anyway here is a patch:
Not sure windows comes with a patch tool, but on linux the patch can be applied by
Had this been GitHub, I would've sent you a pull request.