Comments (15)
I haven't run into an issue with this yet, but I see what you mean. If you write a patch, please use the Options and Argument classes to do so. https://github.com/JelteF/PyLaTeX/blob/master/pylatex/parameters.py
I am planning on refactoring a lot of the codebase this summer anyway, so this would probably have come up. But I always appreciate patches.
from pylatex.
I will. I somehow introduced them with my last request.
Getting testall.sh to run is quite a pain right now. Already took me >1h. Would you be interested in a vagrant configuration? I'm halfway there, so I guess I could provide the Vagrantfile once I'm finished.
from pylatex.
Is it really that hard? I'm currently working on the documentation, so could you let me know what troubles you ran into?
Have you tried pip install -e .[all]
? That should install all python requirements, the only thing that is then needed is a recent version of LaTeX. Is that the issue?
from pylatex.
I did, but matlabplotlib is not building without the freetype and libpng devel package on ubuntu. It's not that hard, it just takes time figuring everything out correctly.
I suppose for the test script to work properly one has to install pylatex using pip install -e . too?
On Jun 23, 2015 9:25 AM, Jelte Fennema [email protected] wrote:Is it really that hard? I'm currently working on the documentation, so could you let me know what troubles you ran into?
Have you tried pip install -e .[all]? That should install all python requirements, the only thing that is then needed is a recent version of LaTeX. Is that the issue?
βReply to this email directly or view it on GitHub.
from pylatex.
Ah, ok. That is what I always dislike about Ubuntu/Debian, that you always need all those devel packages.
And yeah, you should install it with pip install -e .
or you can just use python setup.py
which does the same without a lot of the dependency calculation pip does.
from pylatex.
I have just started refactoring (I needed a bit of a break from the documentation writing). The base_classes file has been split up into two different files and the BaseLaTeXNamedContainer
has been renamed to Environment
. I'm not sure how good git handles this if you made changes in the base_classes file before this change, so it might be easier to just copy and paste your changes if you already have some.
from pylatex.
Well actually the BaseLaTexNamedContainer
is pretty buggy anyway. It only supports a single string as parameter for both arguments and options although the docs explicitly allow either string, list or the respective class instance.
I'll just copy it over anyways. I also did an example on how to use PyLaTeX for custom commands and environments.
from pylatex.
So maybe a unit test would be appropriate too, making sure the parameters work as specified, which is not the case at the moment.
from pylatex.
I think I remember that I wanted to rewrite BaseLaTexNamedContainer
when the Command
class was created, which seemed like a good plan. But I think I ran into issues with circular imports because Command
used the BaseLaTeXClass
class which was in the same file. At that point I think I gave up, because I didn't feel like refactoring back then.
from pylatex.
I think the new docs will really help finding issues like this btw, since they are more in the open now, instead of only in the code.
from pylatex.
Yes, that is apparently an issue. Arguments
and Options
both rely on BaseLatexClass which is in the same module as BaseLaTexNamedContainer
. I currently solved it by doing the import inside BaseLaTexNamedContainer
. Not super elegant but the only way without splitting base_classes
.
from pylatex.
Take a look if you want
sebastianhaas@2c7c285
from pylatex.
I wrote down some comments after a quick look. Great that you made an example for extending PyLaTeX btw.
from pylatex.
I will try to meet your recommendations asap. Please just drop me a line on your decision regarding splitting the typo fix and the arguments
pluralization in two separate commits. I can clearly see your point there, but of course it implies resetting the commit so if you don't care too much ;)
from pylatex.
Closing this because it is fixed
from pylatex.
Related Issues (20)
- Multirow / Mulitcolumn failure
- [Question] How can I just compile an existing TeX document? HOT 2
- Can we have an option to disable utils.fix_filename? HOT 1
- Add sympy support
- Texify to tableofcontents HOT 1
- fontenc and inputenc should not be included
- Store the generated PDF in byteIO
- How to properly add math and refs to captions
- No LaTex compiler was found (Windows 10) HOT 8
- How to to compile .tex file? HOT 2
- File not found for files with dots in relative or absolute path to file
- How to Specify LaTeX Compiler
- "PermissionError: [WinError 5] Access is denied" with document.generate_pdf()
- Adding pandas dataframes to pylatex sections breaks with pandas 2.0
- Negative values in TextBlock
- Two-Column document HOT 1
- Question: Tiny text size HOT 1
- Python 3.12 install fails HOT 2
- Missing Options Paramter in Section classes
- Proposal for `add_item`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pylatex.