QtPyVCP - GCodeEditor - Widget Styling - Please review and comment.

More
27 Dec 2019 14:42 #153278 by Donb9261
There is a second version stored in the home/qtpyvcp folder. It is the example set. Not the runtime set.
The following user(s) said Thank You: Leon82

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 14:43 #153279 by KCJ
That's awesome Don! Can't wait to check it out.
The following user(s) said Thank You: Leon82

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 14:43 #153280 by Leon82

Ooops.... Typo.... missing underscore

/home/YOUR_USER_NAME/.local/lib/python2.7/site-packages/qtpyvcp/widgets/input_widgets/gcode_editor.py


that path worked thanks

if we update qtpyvcp do we have to redo the changes made to this and machine actions file?

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 14:44 #153281 by Leon82

There is a second version stored in the home/qtpyvcp folder. It is the example set. Not the runtime set.


cool, thanks

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 14:47 #153282 by Donb9261
You will have to copy over all files to any new vcp's and any updates will require these files to copied and replaced. None of these files are in mainline yet. Once in mainline, any updates will have them included. Need to make sure all bugs and issues are worked out else everyone will have the same problems.

Please post any bugs, concerns here in this thread so that they can be narrowed to a working model for inclusion in mainline.
The following user(s) said Thank You: Leon82

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 14:57 #153284 by Donb9261
All,

As an aside there are some things to understand about the QtPyVCP install and Kurt can correct me if I am wrong.

There are 2 copies of all files related to QtPyVCP. 1 in your home directory. The other in the .local site packages used by Python.

The one in your home directory is an example folder and is not used at all when you start LinuxCNC with your VCP.

The one in your .local site packages is the RUNTIME file set that is actually used to run your VCP.

That said, if you want to take advantage of any BETA versions I post they must be edited in the site packages versions of all files else you will not have successful results.

Also, cutting and pasting in Python can cause you some real issues as Python relies exclusively on indentation for interpreting your code. I suggest you download the community addition of PyCharm. It is free and it works with WinSUCKS, Mac, and Linux(Debian).

PyCharm or IntelliJ Community will highlight and show you where you have issues. Lots of TUTS out there on how to set it up and use it. And it is FREE.

Download and install IntelliJ here >>
The following user(s) said Thank You: Leon82

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 15:29 #153286 by KCJ
If you have QtPyVCP files in your home directory they almost certainly came from a git clone. These are the source files and are what you should be editing.

The files located in .local site packages are copied from the main directory in home when you run pip install. These are installed files and should not be edited!!

If you modify files in the main source directory you will have to update the installed files by running 'pip install .' from the top level of the source directory (the one containing the setup.py file).

This is a pain since you have to do it every time you edit a file. To avoid this pip has what is called an editable install. This means that instead of copying the files to .local site packages it creates what is called an egg link to the source files. Any change will automatically be picked up and you won't have to do anything for your changes to take effect. So you should always use an editable install if you plan to experiment.

To convert a normal install to an editable one first run ‘pip uninstall qtpyvcp’ to remove all qtpyvcp related files from .local site packages (make sure you back up any changes you have made there). Then from the top level of the qtpyvcp source dir run ‘pip install-editable .’ From now on make changes only to the files in the source directory. When you run QtPyVCP your changes will take effect and you will only have one set of files to keep track of.

Hope this clears up some confusion and makes it easier for y'all to experiment.

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 15:30 #153287 by KCJ
+1 on the PyCharm recommendation! I use it even for non python projects.

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 15:39 #153288 by Donb9261
Always best to hear it from an expert. Which I am not.

Thanks for that advice. Seems I was reversed in my thoughts. Makes sense too. This will allow for less file manipulation.:)

Not used having a dev set. Usually only have the runtime set with a backup folder. << Difficult. Easy peasy with PIP.

I bow to your gracious knowledge Master Kurt,

Don San (Pebble taken from your hand)

Please Log in or Create an account to join the conversation.

More
27 Dec 2019 15:47 - 27 Dec 2019 15:49 #153291 by Leon82
My install seems to use the gcode editor from the local folder. I replaced the one in the home folder originally and it did not show when I started the sim

I'll have to try that
Last edit: 27 Dec 2019 15:49 by Leon82.

Please Log in or Create an account to join the conversation.

Moderators: KCJLcvette
Time to create page: 0.104 seconds
Powered by Kunena Forum