[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2023-10-04 Thread Michal Hoftich
Update of bug #552 (project tex4ht):

 Open/Closed:Open => Closed 

___

Follow-up Comment #7:

This can also be closed, I hope.

___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/



[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2022-02-11 Thread Michal Hoftich
Follow-up Comment #6, bug #552 (project tex4ht):

You can do something like this:

%
\documentclass[12pt,a4paper]{article}

\usepackage[comma,colon]{natbib}
\newcommand\possiblebreak{\hspace{0pt}}

\begin{document}

\begin{thebibliography}{}

\bibitem[{Gulf News}(2021)]{gul21OHB}
{Gulf News} (2021) {Video: A rare migratory bird rescued by Dubai resident
(2021 May 20).}
Downloaded from https://gulfnews.com/\possiblebreak uae/\possiblebreak
environment/\possiblebreak
video-a-rare-migratory-bird-rescued-by-dubai-resident-1.79307000.

\end{thebibliography}

\end{document} 
%

And then redefine the \possiblebreak in the .cfg file:

%%
\Preamble{xhtml}
\renewcommand\possiblebreak{\nobreak}
\begin{document}
\EndPreamble
%%

___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/



[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2022-02-10 Thread Taichi Kato
Follow-up Comment #5, bug #552 (project tex4ht):

Thank you.  The compilation with make4ht passed.

Redefining the \hspace trick would be promising for me (since
I can control the locations of the possible breaks).

I will try with more URLs to see whether Breakurl gives
reasonable results with for platex and make4ht.
(In my ordinary journal submissions, the style files are for
platex or pdflatex, but some journals require .docx.
I want to use the same .bib file to produce reasonable outputs
for the both).



___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/



[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2022-02-10 Thread Michal Hoftich
Follow-up Comment #4, bug #552 (project tex4ht):

It seems that the Breakurl package inserts some PostScript code in the DVI
mode. This causes TeX4ht error. It should be fixed with the attached
usepackage.4ht and breakurl-hooks.4ht files.

Regarding the \hspace trick, you could also define a custom command for this
purpose, and redefine it to do nothing with TeX4ht. But in general, I think
that \url is better. It is weird that it doesn't break with platex.
Unfortunatelly I am not familiar with this engine.

(file #505, file #506, file #507)
___

Additional Item Attachment:

File name: usepackage.4ht Size:3 KB
File name: breakurl-hooks.4ht Size:0 KB
File name: break.odt  Size:7 KB


___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/



[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2022-02-09 Thread Taichi Kato
Follow-up Comment #3, bug #552 (project tex4ht):

The next one (test10-1.tex, also attached) was fine with
platex, but make4ht resulted an error.

[ERROR]   htlatex: Compilation errors in the htlatex run
[ERROR]   htlatex: Filename LineMessage
[ERROR]   htlatex:
/usr/share/texlive/texmf-dist/tex/generic/tex4ht/mathml.4ht 1390 
Undefined
control sequence.

%%%
\documentclass[12pt,a4paper]{article}

\usepackage[comma,colon]{natbib}
\usepackage{hyperref}
\usepackage{breakurl}

\begin{document}

\begin{thebibliography}{}

\bibitem[{Gulf News}(2021)]{gul21OHB}
  {Gulf News} (2021) {Video: A rare migratory bird rescued by Dubai resident
  (2021 May 20).}
  Downloaded from
\url{https://gulfnews.com/uae/environment/video=1=2
ratory=3=4=5=6=7=1.79307000}.

\end{thebibliography}

\end{document}


(file #504)
___

Additional Item Attachment:

File name: test10-1.tex   Size:0 KB


___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/



[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2022-02-09 Thread Taichi Kato
Follow-up Comment #2, bug #552 (project tex4ht):

I tried with test10.tex and obtained different results
between teX4ht (test10.odt) and platex (test10.pdf).
The long URL line is not broken by platex.
I wanted to specify where to break (such as after &)
by using \hspace{0pt}. This worked as desired in platex,
but not in teX4ht.

If there is a good tip to produce similarly broken
long URLs by teX4ht and platex from the same .tex source,
I would be happy to know it.


(file #500, file #501, file #502)
___

Additional Item Attachment:

File name: test10.tex Size:0 KB
File name: test10.pdf Size:10 KB
File name: test10.odt Size:7 KB


___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/



[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2022-02-09 Thread Michal Hoftich
Follow-up Comment #1, bug #552 (project tex4ht):

TeX4ht doesn't do anything with \hspace. The issue here is that the link is
broken into two lines, and LO displays the line break as space:

 
 Downloaded   from   https://gulfnews.com/uae/environment/
  video-a-rare-migratory-bird-rescued-by-dubai-resident-1.79307000.


I would use the \url{} command. It handles line breaks in PDF automatically,
and it works correctly in TeX4ht. Moreover, you will get a clickable link.

___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/



[tex4ht] [bug #552] Unwanted space at \hspace{0pt}

2022-02-08 Thread Taichi Kato
URL:
  

 Summary: Unwanted space at \hspace{0pt}
 Project: tex4ht
Submitted by: tk2022
Submitted on: Wed Feb  9 02:45:01 2022
Category: None
Priority: 5 - Normal
Severity: 5 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any

___

Details:

Unnecessary spaces are inserted at \hspace{0pt}.
(platex-compiled test9.pdf is also attached).

%%%
\documentclass[12pt,a4paper]{article}

\usepackage[comma,colon]{natbib}

\begin{document}

\begin{thebibliography}{}

\bibitem[{Gulf News}(2021)]{gul21OHB}
  {Gulf News} (2021) {Video: A rare migratory bird rescued by Dubai resident
  (2021 May 20).}
  Downloaded from
https://gulfnews.com/\hspace{0pt}uae/\hspace{0pt}environment/\hspace{0pt}video-a-rare-migratory-bird-rescued-by-dubai-resident-1.79307000.

\end{thebibliography}

\end{document}




___

File Attachments:


---
Date: Wed Feb  9 02:45:01 2022  Name: test9.odt  Size: 7kB   By: tk2022


---
Date: Wed Feb  9 02:45:01 2022  Name: test9.pdf  Size: 7kB   By: tk2022



___

Reply to this item at:

  

___
  Message sent via/by Puszcza
  http://puszcza.gnu.org.ua/