09-28-2013, 11:05 PM | #121 |
Well trained by Cats
Posts: 29,818
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
What I found hilarious was the one language I counted my self proficient in' Allows the user to shoot you in the foot'
My wife is famous for finding weakness in my frequently used code that existed for years without ever causing me any grief |
09-29-2013, 07:22 AM | #122 |
Color me gone
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
|
If someone else wants to take over this project, the sensible thing is to start over in Python. It can be more easily maintained and it would be much easier to find code contributors.
The only problem is the million or so lines of code (not all of which would be needed in Python.) The origin of Sigil was not to develop an epub editor per se, but a project through which the original developer could get his degree. In that regard, it was a great success, since graduated and got a job at Google. Expansion and maintainability were not the primary aims. I wish I could help but my knowledge is in electronic hardware maintenance. |
Advert | |
|
09-29-2013, 01:18 PM | #123 |
Indie Advocate
Posts: 2,863
Karma: 18794463
Join Date: Sep 2010
Location: Melbourne, Australia
Device: Kindle
|
|
09-29-2013, 01:55 PM | #124 | ||
Grand Sorcerer
Posts: 6,111
Karma: 34000001
Join Date: Mar 2008
Device: KPW1, KA1
|
Quote:
The obvious disadvantage of Python compared to C++ is sheer speed, but then, a program such as Sigil does not need a lot of speed. However, if need be, there are possibilities to actually compile Python to an executable (py2exe, cx_Freeze), and if a function is needed that is *really* heavy on calculation, it could be written in C (or C++), compiled, and then called from Python. Quote:
Mind you, I'm not saying I'm going to write the successor to Sigil. Maybe some day, but don't hold your breath. Still, I may look into Python further, because there are some (small) things I want to change/add in at least one Calibre plugin. |
||
09-29-2013, 05:51 PM | #125 |
Grand Sorcerer
Posts: 7,452
Karma: 7185064
Join Date: Oct 2007
Location: Linköpng, Sweden
Device: Kindle Voyage, Nexus 5, Kindle PW
|
Why do you think it can be more easily maintained? I would say that for big programs Python is harder to maintain than C++.
|
Advert | |
|
09-29-2013, 06:12 PM | #126 | |
Grand Sorcerer
Posts: 6,111
Karma: 34000001
Join Date: Mar 2008
Device: KPW1, KA1
|
Quote:
C++ is much harder to program in that Python (which seems a lot like PHP, with regard to programming ease), because much more stuff needs to be done by the programmer himself; this alone gives you MUCH more time to maintain a Python program. Let me tell you, as a C / C++ programmer (who normally writes embedded software to make stuff run, such as microcontrollers, where no GUI's are used and speed/code compactness is paramount): I would NEVER use C or C++ for a desktop application nowadays, if I can get away with it. I've been looking around. Many seem to "just" design the GUI in QT Designer, and call that from Python (using PyQT or PySide), rather than coding the GUI by hand, and then compile their speed-critical parts to external modules using Cython. Cython basically takes Python (amended with some type information), translates it into C, and then compiles it into machine code. That way, you have all the advantages: rapid GUI prototyping in a designer, rapid code writing in Python, and if you need speed, compilation of critical parts using Cython. The best part is that most of the nitty-gritty details "under water" are taken care of for you, which makes code a lot easier to maintain, especially for newcomers to a project. |
|
09-29-2013, 06:38 PM | #127 | |
Grand Sorcerer
Posts: 7,452
Karma: 7185064
Join Date: Oct 2007
Location: Linköpng, Sweden
Device: Kindle Voyage, Nexus 5, Kindle PW
|
Quote:
But it depends a bit on the expected complexity and code size. If you get a small Python program that one person easily can develop than the smallness is such an advantage that this is preferred. |
|
09-29-2013, 06:39 PM | #128 |
Grand Sorcerer
Posts: 7,452
Karma: 7185064
Join Date: Oct 2007
Location: Linköpng, Sweden
Device: Kindle Voyage, Nexus 5, Kindle PW
|
|
09-29-2013, 06:56 PM | #129 |
Grand Sorcerer
Posts: 6,111
Karma: 34000001
Join Date: Mar 2008
Device: KPW1, KA1
|
You often make assumptions of which you cannot be certain that they are true:
1. You assume someone with a full time job has unlimited time and money to spend on writing a book. People who have a day job hardly have unlimited time, and often not unlimited money either. Yeah, if you don't mind spending 20 years on writing that book, but that's hardly practical. 2. You assume everybody can just read text as close as they would like. There are many far-sighted people in this world who will need to keep their reading at a minimum distance, even using glasses. You assume the books I bought were cheap because they were old conversions. They may be old conversions, but they are still the ones sold today. Except for Kobo Netherlands, these books are *not* cheap. They cost $12.99 / £8.49 everywhere else. I'll drop it here, because this is not the point of the topic. Last edited by Katsunami; 09-29-2013 at 06:58 PM. |
10-02-2013, 10:48 PM | #130 | |
creator of calibre
Posts: 43,867
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Quote:
http://www.ohloh.net/p/calibre |
|
10-03-2013, 06:00 AM | #131 | |
Grand Sorcerer
Posts: 7,452
Karma: 7185064
Join Date: Oct 2007
Location: Linköpng, Sweden
Device: Kindle Voyage, Nexus 5, Kindle PW
|
Quote:
|
|
10-03-2013, 08:32 AM | #132 |
creator of calibre
Posts: 43,867
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
For any large code base to be maintainable, the programmers involved have to be disciplined and experienced, regardless of the language. For example, my own style of python coding has evolved significantly over the decade or so that I have been writing python code.
I just find that python leads to much higher maintainability than C++. The advantage that static typing in C++ brings is easily compensated for by just using descriptive names in python. However, I dont really want to get into a debate on the relative merits of various languages. If you are happy with C++ -- more power to you |
10-03-2013, 12:06 PM | #133 |
eBook FANatic
Posts: 18,301
Karma: 16071131
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
Upgrading Sigil
Can C++ communicate (send and receive) with Python?
|
10-03-2013, 12:10 PM | #134 |
creator of calibre
Posts: 43,867
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Sure, you can even host a python interpreter inside a C++ application and vice versa (run c++ code in a python application with a wrapper). I'd assume that would be the approach adding plugin functionality to Sigil would take.
|
10-03-2013, 01:38 PM | #135 |
eBook FANatic
Posts: 18,301
Karma: 16071131
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
Upgrading Sigil
I have been browsing through the sigil code and see the major problem with sigil naintenance. NO PROPER DOCEMENTATION!!!
Unless the programmer thinks, eats, breathes, and dreams in C++, understanding what is going on is very difficult and not being totaly knowledgeable in the general functioning (epub operations) maintaining the code will be a huge learning curve. Each modile should be accompanied by a pseudo code file defining and demonstrating the desired inputs, outputs, and data manipulation to be performed. The US military tried to overcome these problems with ADA, even then with limited success. Pseudo code is written to be understood by humans whereas code is written to be understood by machines. IF the folks who have brought Ssigil to this point can be convinced to create this information, Sigil becomes eminently maintainable and can be easily expanded. |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
SAD NEWS | Nate the great | Lounge | 6 | 12-29-2007 03:24 PM |
Sad news about Jim Baen | Liviu_5 | News | 2 | 06-17-2006 09:29 PM |