JuliaGraphics / Winston.jl

2D plotting for Julia
MIT License
171 stars 55 forks source link

Four changes in tkwidget.jl for 0.6.0 compatibility #284

Closed goszlanyi closed 1 month ago

goszlanyi commented 7 years ago

At present, Winston does not work with Julia 0.6.0.

After changing lines 49 and 53 to escape_string and lines 51 and 55 to String(take!(libpath)) it works again.

49        escape_string(libpath,abspath(tcldir,"..","share","tcl"),"{}")
          print(libpath,"}]")
51        tcl_eval(String(take!(libpath)),tclinterp)
          print(libpath,"set env(TK_LIBRARY) [subst -nocommands -novariables {")
53        escape_string(libpath,abspath(tcldir,"..","share","tk"),"{}")
          print(libpath,"}]")
55        tcl_eval(String(take!(libpath)),tclinterp)

I did these these changes for my local install, but could someone make these changes also for the repo?

Also, please keep Winston alive!

ararslan commented 7 years ago

Thanks for the report! It would be great if you could submit a pull request with this fix.

goszlanyi commented 7 years ago

Unfortunately, I do not know how to submit a pull request. The maximum I can contribute now is error reports.

ararslan commented 7 years ago

That's fine, error reports are much appreciated. In case you're interested in submitting a pull request in the future, here's how to do it:

  1. Fork JuliaGraphics/Winston.jl to your account using the "Fork" button in the upper right corner of the page on GitHub.

  2. Clone Winston locally and add your fork as a remote:

    git clone https://github.com/JuliaGraphics/Winston.jl.git
    cd Winston.jl
    git remote add GaborOszlanyi https://github.com/GaborOszlanyi/Winston.jl.git
  3. Check out a branch on which to make changes. A common convention is to prefix the branch name with your initials, then a slash, then a very brief description of the change. For example:

    git checkout -b go/fix-0.6.0
  4. Make the necessary changes.

  5. Commit your changes:

    git add -u # stage all modified files
    git commit -m "Some description of the change"
  6. Push the changes to your fork:

    git push GaborOszlanyi go/fix-0.6.0
  7. Open a pull request on this repo. If you go to https://github.com/JuliaGraphics/Winston.jl, a button should have shown up to create a pull request from the branch you pushed to your fork.

That's it!

goszlanyi commented 7 years ago

I truly appreciate your detailed instructions. But apart from the fear of messing up the site, I am even uncertain if Winston is the right place to make the changes.

tkwidget.jl is found in the Tk directory that in turn was brought by Winston, so maybe https://github.com/JuliaGraphics/Tk.jl is the right place for the changes.