mgeier/insipid-sphinx-theme

Line breaks in function / class names (in autosummary tables)

sikersten opened this issue · 6 comments

With insipid-sphinx-theme version >= 0.3.0, unwanted line breaks are in some cases inserted in function and class names before the last letter. For example

Thanks for reporting this!

I've changed the behavior in #72 and #87, because not breaking those lines is IMHO no option on small screens (like smartphones).

The problem now seems to be that the function name allows line breaks but the argument list doesn't, which looks very awkward.

Any ideas how to fix this?

I've created #100, which is hopefully a bit better?

It's still not great, so if you have some suggestions, please let me know!

I've just released version 0.3.2, can you please check if that improves the situation?

Again, if you have further suggestions, please let me know!

Thank you for your effort and sorry for responding so late! It definitely improves the situation:
version 0.3.1:
grafik
version 0.3.2:
grafik

As you are asking for suggestions: now line breaks sometimes appear within parameter names (see above). Solutions for this I could think of would be to more strictly allow breaks only at "," or to shorten the parameter list depending of the length of the parameters and add something like "..." instead. But I am not familiar with how sphinx works.
What's your opinion?

Thanks for checking this!

Solutions for this I could think of would be to more strictly allow breaks only at "," or to shorten the parameter list depending of the length of the parameters and add something like "..." instead.
But I am not familiar with how sphinx works.

The line breaks are not created by Sphinx but by the browser. So I guess any solution would have to be done using CSS.

If somebody knows how to improve the CSS rules, please let me know!

There are ways to cut off the end of a string and add "..." with CSS, but I think this will be confusing since some of the signatures already have "..." in them!

I'm closing this for now. It's not perfect, but I think it's acceptable. If anybody has ideas for improvements, please speak up!