model railroad track planning
Moderators: andrew, Husky, J-J
Re: model railroad track planning
So that's it for the moment. Any comment is appreciated. If you have any question or suggestion or if you find (some of the surely existing) bugs, please write a comment here.
Re: model railroad track planning
Hello smf,
thank you very much for this Script and Tutorial! I'm really impressed!!!
1. Decimal Point:
I run your script on a Computer with a German OS (WinXP).
My OS settings for the Decimal Point = Comma.
My QCAD settings for the Decimal Point = Dot.
- Your script is using the OS settings and not the QCAD settings - would it be possible that your script will adopt the settings from QCAD? Right now your script will change a given value from 250.0 into 2500,0
If I use directly in QCAD wrong Character I will see a red warning which indicates that I do something wrong ...
2.
Consecutive extension:
It's limited to two - why I can't use more?
3. Language:
I have the feeling that I know a couple guys in Germany which would love to use your script in QCAD .....
- Do you have any plans to provide a possibility to translate the relevant dialogs in your script? Like ts files .. ?
thank you very much for this Script and Tutorial! I'm really impressed!!!
I have just started testing the script but may I ask you the first questions ....smf wrote:So that's it for the moment. Any comment is appreciated. If you have any question or suggestion or if you find (some of the surely existing) bugs, please write a comment here.
1. Decimal Point:
I run your script on a Computer with a German OS (WinXP).
My OS settings for the Decimal Point = Comma.
My QCAD settings for the Decimal Point = Dot.
- Your script is using the OS settings and not the QCAD settings - would it be possible that your script will adopt the settings from QCAD? Right now your script will change a given value from 250.0 into 2500,0
If I use directly in QCAD wrong Character I will see a red warning which indicates that I do something wrong ...
2.
Consecutive extension:
It's limited to two - why I can't use more?
3. Language:
I have the feeling that I know a couple guys in Germany which would love to use your script in QCAD .....
- Do you have any plans to provide a possibility to translate the relevant dialogs in your script? Like ts files .. ?
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Re: model railroad track planning
Hello Husky,
thank you for your response. Hopefully the scripts are of help and have not too many bugs...
thank you for your response. Hopefully the scripts are of help and have not too many bugs...
In fact, I have no idea how to change this behaviour. I'm working on an English XUbuntu, all dialogs are designed with Qt4 Designer using a QDoubleSpinBox. Andrew already pointed out that QCad is using a special input box where the user is allowed enter expressions. I will try to migrate to this input box, then I hope my dialogs will behave like the original QCad ones.1. Decimal Point:
I run your script on a Computer with a German OS (WinXP).
My OS settings for the Decimal Point = Comma.
Uhm, I'm sorry for not fully understanding. What do you mean with "limited to two"? The undo-function is limited to the last inserted track, yes. I thought it would be easier to delete more than one element with the "normal" QCad functions. Adding of elements should be unlimited. Could you please specify what limits the input?2.Consecutive extension:
It's limited to two - why I can't use more?
Hehe. As I'm playing with "Märklin C-Gleis" for a few weeks now, I think I know what you mean. I never tried the ts-files before, but it seems that everything has a first time. I will have a look at the translation and will provide a German version as soon as possible. I would be pleased to see my scripts used and to see model railroad plans created with QCad.3. Language:
I have the feeling that I know a couple guys in Germany which would love to use your script in QCAD .....
- Do you have any plans to provide a possibility to translate the relevant dialogs in your script? Like ts files .. ?
Re: model railroad track planning
Sorry - my bad! I misinterpreted the left/right box as a multi copy counter. I tested it before I read your manual ...smf wrote:Uhm, I'm sorry for not fully understanding. What do you mean with "limited to two"? The undo-function is limited to the last inserted track, yes. I thought it would be easier to delete more than one element with the "normal" QCad functions. Adding of elements should be unlimited. Could you please specify what limits the input?2.Consecutive extension:
It's limited to two - why I can't use more?
Questions: Would it make sense to label the top of the columns or change 1, 2 into l, r (=left, right) to prevent confusions?
Drawing navigation with open "Consecutive extension" Window:
It would be nice if I could still navigate (zoom in and out etc) during I use the "Consecutive extension" Tool. Similar to the QCAD Selection Filter Functionality.
Sounds good to me - I think the ts files are working very well to get the script multilingual.smf wrote: Hehe. As I'm playing with "Märklin C-Gleis" for a few weeks now, I think I know what you mean. I never tried the ts-files before, but it seems that everything has a first time. I will have a look at the translation and will provide a German version as soon as possible. I would be pleased to see my scripts used and to see model railroad plans created with QCad.
Question to "Create Track" dialog:
1. Block name - If I use accidentally the same block name twice - the first created block will be overwritten by this action.
The warning is only in the Command line but not everybody works with a visible CL.
I think some kind of protection in the dialog like the warnings in QCAD would be nice.
2. Cost:
Would it be possible to fill in a full price like 12.70 instead of 1270?
3. Remember function:
I can change the pre filled Fields but after restarting the tool everything is back to default.
Would it be possible that the dialog remembers the last used dimensions?
Question to: "Show Part List":
In QCAD we have already a "Export Block List" script which will print the Block List in a Text file.
(Misc/Block/Export Block List)
Would it make sense to have the "Show Part List" also printed in a Text File?
However - your scripts are amazing!!!
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Re: model railroad track planning
I tried to insert translation files, and it seems to work "sometimes". Attached is a new version with some basic translations. Menu items and Dialogs are translated, but most of the console output is not yet translated. Starting QCad without parameter seems to work, but unfortunately, with inserted translation files and with enabled script debugger QCad seems to crash. Calling
results in
So I'm surely doing something wrong, but I don't have a clue what. I created ts-files using something like
and then edited this ts-file with Qt Linguist. As the "normal" ts files seem not to work in QCad (?), I saved them additionally as qm files, then the translation appeared.
Code: Select all
qcad -rescan -enable-script-debugger
Code: Select all
Warning: QWidget::repaint: Recursive repaint detected
/opt/qcad-3.6.0-pro-linux-x86_64/qcad: line 18: 4979 Segmentation fault (core dumped) LD_LIBRARY_PATH="$DIR" "$binary" -style plastique "$@"
Code: Select all
lupdate Variegate* -source-language en -target-language de -ts ts/Variegate_de.ts
- Attachments
-
- QCTrack_V51_TranslationBase.zip
- (41.92 KiB) Downloaded 1448 times
Re: model railroad track planning
Hi Husky,
thanks again for your suggestions!
I have some other work to do now but will post here as soon as possible. Thanks again for your suggestions!
thanks again for your suggestions!
Yes indeed. I didn't figure out how to do this in a "nice" way, but I will have a look at this.Would it make sense to label the top of the columns or change 1, 2 into l, r (=left, right) to prevent confusions?
Again: yes. I tried several approaches, but never succeeded. Andrew helped me out at some points, but my main problem was/is the data exchange between multiple script engines. I will try to understand the QCad Selection Filter, perhaps this points into the right direction for a better solution.Drawing navigation with open "Consecutive extension" Window:
It would be nice if I could still navigate (zoom in and out etc) during I use the "Consecutive extension" Tool. Similar to the QCAD Selection Filter Functionality.
I will insert this in the (hopefully soon released) next version.1. Block name - If I use accidentally the same block name twice - the first created block will be overwritten by this action.
The warning is only in the Command line but not everybody works with a visible CL.
I think some kind of protection in the dialog like the warnings in QCAD would be nice.
I thought of this, but as floating points are not really precise, I decided to use integer numbers. But I admit that this is not very comfortable. Would it be helpful to display the result formatted, i.e. to divide the Cents by 100 for the output?2. Cost:
Would it be possible to fill in a full price like 12.70 instead of 1270?
Yes, as soon as I change the DoubleSpinBox to RMathLineEdit or the already updated WidgetFactory is inserted. The persistent Widget functionallity was inserted but removed for the releases as the DoubleSpinBox aren't persistent with QCad 3.7.5.3. Remember function:
I can change the pre filled Fields but after restarting the tool everything is back to default.
Would it be possible that the dialog remembers the last used dimensions?
Thank you for this hint - I did not recognize this function but will look at it. Of course a text file would be of help for many people.Question to: "Show Part List":
In QCAD we have already a "Export Block List" script which will print the Block List in a Text file.
(Misc/Block/Export Block List)
Would it make sense to have the "Show Part List" also printed in a Text File?
I have some other work to do now but will post here as soon as possible. Thanks again for your suggestions!
Last edited by smf on Fri Jan 09, 2015 9:31 pm, edited 1 time in total.
Re: model railroad track planning
Hi there,
I now inserted some improvements(?) to have the new attached version.
Unfortunately, the column header thing didn't worked too well, so I decided to insert a ToolTip clarifying the SpinBox in the ConsecExtend dialog. As for now, the dialog is still modal so you can not zoom / move while the dialog is open. But if you select "Select new destination", you may zoom and move the window and get back to the same dialog immediately. I am still in search of a better solution.
On creation there now will be an error message in an alert-box additionally to the console output.
Everything should be translated now and available in German if QCad is set to German user interface. For unknown reasons, QCad stopped crashing if debugger is enabled, so my question above is obsolete.
I now inserted some improvements(?) to have the new attached version.
Unfortunately, the column header thing didn't worked too well, so I decided to insert a ToolTip clarifying the SpinBox in the ConsecExtend dialog. As for now, the dialog is still modal so you can not zoom / move while the dialog is open. But if you select "Select new destination", you may zoom and move the window and get back to the same dialog immediately. I am still in search of a better solution.
On creation there now will be an error message in an alert-box additionally to the console output.
Everything should be translated now and available in German if QCad is set to German user interface. For unknown reasons, QCad stopped crashing if debugger is enabled, so my question above is obsolete.
- Attachments
-
- QCTrack_V54_CreateErrorBeautify.zip
- QCTrack version 54
- (50.18 KiB) Downloaded 1418 times
Re: model railroad track planning
What I have seen till now looks pretty good! I'm a native German speaker ...smf wrote:Everything should be translated now and available in German if QCad is set to German user interface. For unknown reasons, QCad stopped crashing if debugger is enabled, so my question above is obsolete.
Note: The "Duplicate and move" command isn't working in the V54.
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Re: model railroad track planning
I don't know why but now it's working. Maybe I did something wrong ....Husky wrote:Note: The "Duplicate and move" command isn't working in the V54.
Sorry!
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Re: model railroad track planning
Attached is the new version 56 with most of the discussed features. Still missing are "save last options in Create" and "move/zoom while Consecutive Extension" - as for now I'm sure with a "normal" widget instead of the dialog, for each track to be inserted the connection track end has to be selected. In sum this would be better than the current approach I must admit, but I think I need some more time to change this concept.
Cost is now based on integer during calculation but can be entered as "normal" dollars / euros / whatever. The output is formatted accordingly, all existing plans will work without change (the text on TR_COST still contains Cent).
Cost is now based on integer during calculation but can be entered as "normal" dollars / euros / whatever. The output is formatted accordingly, all existing plans will work without change (the text on TR_COST still contains Cent).
- Attachments
-
- QCTrack_V56_Cost100.zip
- QCTrack version 56
- (52.33 KiB) Downloaded 1387 times
Re: model railroad track planning
Ich auch - ich befürchtete bereits, man würde es dem holprigen englischen Text anmerken...I'm a native German speaker ...
Re: model railroad track planning
Hi Stefan
Well you have certainly been busy with this project, thank you for your step by step tutorial, when I get the time I will digest it and try out what you have accomplished so far, all that remains is to say very well done indeed Stefan I am sure your addition will attract quite a few people and encourage others to use QCAD for implementing their own extensions.
Well you have certainly been busy with this project, thank you for your step by step tutorial, when I get the time I will digest it and try out what you have accomplished so far, all that remains is to say very well done indeed Stefan I am sure your addition will attract quite a few people and encourage others to use QCAD for implementing their own extensions.
For the best support please state your operating system, QCAD version and add any supporting DXF/DWG files, screenshots etc...
Re: model railroad track planning
Hi smf - thanks again! I will play around with the new version ....
Take your time - nobody is chasing you!smf wrote:... but I think I need some more time to change this concept.
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Re: model railroad track planning
Da gingen meine Ahnungen ja in die richtige Richtung - so gut konnte keine "Online Übersetzung" sein!smf wrote:Ich auch - ich befürchtete bereits, man würde es dem holprigen englischen Text anmerken...
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Re: model railroad track planning
And now I've seen that a Tool Bar is also in progress. Nice!
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."