Navigation

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Users
    • Groups
    • Solved
    • Unsolved
    • Search
    1. Home
    2. Recent
    Log in to post
    • All categories
    • Announcements
    • General Discussion
    • Tutorials
    • Code snippets
    • Feature Requests
    • Bugs
    • All Topics
    • New Topics
    • Watched Topics
    • Unreplied Topics

    • snaders

      SOLVED Using global variables input
      General Discussion • drawbot as module user interaction variables drawbot package vanilla • 21 Oct 2019, 11:45 • snaders   22 Oct 2019, 07:48

      3
      0
      Votes
      3
      Posts
      152
      Views

      snaders 22 Oct 2019, 07:48

      Hello @gferreira, Thanks for the quick reply. I mistakenly thought vanilla just ment that it didn't have any 'addons'. Like vanilla JS... This makes a lot more sense, will look into that! Thanks a lot!
    • JD

      SOLVED New Drawbot version
      Bugs • 20 Oct 2019, 18:32 • JD   21 Oct 2019, 17:24

      3
      0
      Votes
      3
      Posts
      145
      Views

      JD 21 Oct 2019, 17:24

      Thanks Frederik, that solved the issue. JD
    • eduairet

      SOLVED Radial animation
      Tutorials • animation • 4 Oct 2019, 03:50 • eduairet   16 Oct 2019, 02:18

      5
      0
      Votes
      5
      Posts
      461
      Views

      eduairet 16 Oct 2019, 02:18

      @gferreira wow, this is huge!!! thank you again
    • jansindl3r

      SOLVED Find out whether a point is placed within an area
      General Discussion • 9 Oct 2019, 09:55 • jansindl3r   9 Oct 2019, 09:59

      2
      0
      Votes
      2
      Posts
      139
      Views

      gferreira 9 Oct 2019, 09:59

      @jansindl3r yes, have a look at BezierPath.pointInside(xy)
    • frederik

      DrawBot3.121 is released
      Announcements • 4 Oct 2019, 09:55 • frederik   4 Oct 2019, 09:55

      1
      2
      Votes
      1
      Posts
      512
      Views

      No one has replied

    • jansindl3r

      SOLVED How can I split a path into multiple segments?
      General Discussion • bezierpath • 18 Sept 2019, 19:20 • jansindl3r   2 Oct 2019, 15:54

      8
      0
      Votes
      8
      Posts
      419
      Views

      gferreira 2 Oct 2019, 15:54

      there’s an example of FlattePen + BezierPath here
    • jo

      SOLVED bezierPath.polygon()?
      Feature Requests • bezierpath • 27 Sept 2019, 07:35 • jo   30 Sept 2019, 07:43

      2
      1
      Votes
      2
      Posts
      228
      Views

      frederik 30 Sept 2019, 07:43

      continue here https://github.com/typemytype/drawbot/issues/301 thanks!
    • KevinKarney

      SOLVED Newby request
      General Discussion • bezierpath geometry boolean operations • 26 Sept 2019, 17:41 • KevinKarney   26 Sept 2019, 19:24

      2
      0
      Votes
      2
      Posts
      185
      Views

      gferreira 26 Sept 2019, 19:24

      hello @KevinKarney, welcome to DrawBot! 1. I need the option to build compound objects (with unions, differences, intersections). Is it possible to make (e.g) a torus by differencing 2 circles. Or do I have to create two bezier paths and then do the difference. both methods are possible: you can do it with a single BezierPath by drawing two circles in opposing directions: x, y = 500, 500 r1 = 400 r2 = 300 B = BezierPath() B.oval(x-r1, y-r1, r1*2, r1*2) B.reverse() B.oval(x-r2, y-r2, r2*2, r2*2) fill(0, 1, 0) stroke(1, 0, 0) strokeWidth(10) drawPath(B) or you can draw two separate circles, and get the difference between them: B1 = BezierPath() B1.oval(x-r1, y-r1, r1*2, r1*2) B2 = BezierPath() B2.oval(x-r2, y-r2, r2*2, r2*2) B3 = B1.difference(B2) drawPath(B3) 2. with primitives such as oval or rect, can I incorporate the fill, stroke, strokewidth, etc into the call. In Nodebox 1, I can say (e.g) a = rect(0,0,20,20,stroke=Red,strokewidth=3,fill=Grey, draw=False) This creates an object call a, but does not draw it.... grouping colors and geometry can be done with functions: def a(): stroke(1, 0, 0) strokeWidth(3) fill(0.5) rect(0, 0, 20, 20) a() hope this helps… have fun with the movies, and let us know if you have any other questions.
    • eduairet

      SOLVED Output text
      Tutorials • text formatting • 30 Aug 2019, 03:19 • eduairet   24 Sept 2019, 23:13

      9
      0
      Votes
      9
      Posts
      500
      Views

      eduairet 24 Sept 2019, 23:13

      @gferreira thanks, it worked, I'm coming with some new exercises. Cheers.
    • rachelkriebel

      SOLVED some problems importing noise module
      General Discussion • modules noise • 12 Jun 2019, 18:39 • rachelkriebel   20 Sept 2019, 08:01

      4
      0
      Votes
      4
      Posts
      428
      Views

      gferreira 20 Sept 2019, 08:01

      hello @burnier & everyone else with the same problem, the latest version of Python is 3.7 DrawBot currently embeds Python 3.6 if you recently installed “Python 3” from python.org, you probably have 3.7. to make modules available in DrawBot, they need to be installed for Python 3.6 (not 3.7). so, the first step is to make sure that you have Python 3.6 installed in your system. you can check that by typing python3.6 in Terminal. if you get -bash: python3.6: command not found, then you need to install Python 3.6 first. you can get it from python.org/downloads. pip is included in Python, so once you have Python 3.6 you should have pip3.6 too. please give it a try, and let us know how it goes… good luck!
    • jansindl3r

      SOLVED How to get width of text, including metrics?
      General Discussion • text • 16 Sept 2019, 10:53 • jansindl3r   16 Sept 2019, 15:59

      4
      0
      Votes
      4
      Posts
      187
      Views

      jansindl3r 16 Sept 2019, 15:59

      @gferreira I also believe that you meant textSize('string')
    • MishaHeesakkers

      UNSOLVED Trying to install Drawbot as a module gives this error.
      Bugs • modules • 3 Sept 2019, 06:47 • MishaHeesakkers   11 Sept 2019, 15:54

      4
      0
      Votes
      4
      Posts
      313
      Views

      frederik 11 Sept 2019, 15:54

      mm strange, can you send an example script that fails with this traceback A wild guess is that the drawBot package is not installed. Did you do this last step (next to installing all the dependencies) cd path/To/drawBot pytho3.7 setup.py install
    • jansindl3r

      SOLVED Place stroke on a shape's contour, with no offset
      General Discussion • stroke clipping outline • 9 Sept 2019, 12:23 • jansindl3r   9 Sept 2019, 15:37

      2
      0
      Votes
      2
      Posts
      176
      Views

      gferreira 9 Sept 2019, 15:37

      hello @jansindl3r, you can use the contours of the letters as a clipping mask, so the outside half of the stroke is not visible: size(2000, 1000) stroke(1, 0, 0) strokeWidth(30) B = BezierPath() B.text('a', (110, 130), fontSize=1400) # clip external stroke with savedState(): clipPath(B) drawPath(B) # normal stroke translate(1000, 0) drawPath(B) cheers!
    • eduairet

      SOLVED Grid
      Tutorials • grid layout • 22 Aug 2019, 04:15 • eduairet   22 Aug 2019, 23:46

      3
      0
      Votes
      3
      Posts
      327
      Views

      eduairet 22 Aug 2019, 23:46

      @gferreira said in Grid: w = (width() - gutter * (cols + 1)) / cols h = (height() - gutter * (rows + 1)) / rows Thank you very much, it worked way much better, I also tried to add a margin feature that worked well so now I can design over the grid size(1000, 1000) cols = 3 rows = 3 gutter = 12 #Margin mTop = 10 - gutter mBottom = 20 - gutter mLeft = 10 - gutter mRight = 10 - gutter w = (width() - gutter * (cols + 1)) / cols - ((mRight + mLeft) / cols) h = (height() - gutter * (rows + 1)) / rows - ((mTop + mBottom) / rows) fill(None) strokeWidth(1) stroke(0, 1, 1) for col in range(cols): for row in range(rows): x = gutter + col * (w + gutter) y = gutter + row * (h + gutter) rect(x + mLeft, y + mBottom, w, h)
    • jo

      Lissajous table
      Code snippets • lissajous • 19 Aug 2019, 19:32 • jo   19 Aug 2019, 19:32

      1
      2
      Votes
      1
      Posts
      339
      Views

      No one has replied

    • habakuk

      SOLVED How to mirror/flip a object?
      General Discussion • transformations • 11 Aug 2019, 08:48 • habakuk   15 Aug 2019, 17:41

      9
      0
      Votes
      9
      Posts
      510
      Views

      habakuk 15 Aug 2019, 17:41

      Hallo @jo thanks alot - at the moment i use the lissajus only to create different nice looking loops. I changed the values as you suggested and of course it is working now and delivers a new nice looking loop. I`d love to make some more loops with more "natural, subtle and slow" movements. I saw your great visualisations of the different variable font movements and hoped to create a custom path to do so - but i failed... if you like to play around with my very first 5 letter variable font (HABKU) you are very welcome. http://habaland.ch/images/habaroll8GX.ttf i added the the plus and minus to avoid the font doing the whole move to the min and max, because the backgraound would be visible then. (but most likely i created only a mess ) and by the way, i hate the black circle i had to ad "behind the scene" - id love o have a cleaner solution. ...at the moment i am trying to figure out where to append the savedState() without messing everything up... greetings from Bern
    • ThunderNixon

      UNSOLVED Efficient way to convert all text to outlines in a multi-page doc?
      General Discussion • bezierpath text • 14 Aug 2019, 03:33 • ThunderNixon   15 Aug 2019, 17:14

      8
      0
      Votes
      8
      Posts
      429
      Views

      frederik 15 Aug 2019, 17:14

      mmm, generate an instance with fontTools, use that font with a path and generate the pdf? wondering if the Bad font object... error is also reported with old-style-static-fonts?
    • ThunderNixon

      SOLVED Is there a way to build "bleed" into a file, for printing?
      General Discussion • layout • 13 Aug 2019, 12:40 • ThunderNixon   14 Aug 2019, 14:21

      4
      0
      Votes
      4
      Posts
      324
      Views

      andyclymer 14 Aug 2019, 14:21

      Until there's a new feature for this, I think you could replace your newPage() calls to a custom newPageWithBleed() that goes something like this, and wouldn't need to change any of your other drawing code — def newPageWithBleed(w, h, bleed): newPage(w + bleed * 2, h + bleed * 2) translate(bleed, bleed) W, H = 400, 400 bleed = 25 newPage(W, H) rect(0, 0, 20, 20) newPageWithBleed(W, H, bleed) rect(0, 0, 20, 20)
    • MauriceMeilleur

      UNSOLVED Using arcTo() for variable-radius corner-rounding
      General Discussion • trigonometry • 8 Aug 2019, 20:24 • MauriceMeilleur   8 Aug 2019, 20:24

      1
      0
      Votes
      1
      Posts
      193
      Views

      No one has replied

    • ThunderNixon

      SOLVED How do I size an image with the ImageObject (or without)?
      General Discussion • image transformations • 2 Aug 2019, 18:17 • ThunderNixon   3 Aug 2019, 16:02

      5
      0
      Votes
      5
      Posts
      381
      Views

      ThunderNixon 3 Aug 2019, 16:02

      Ahh this is a very clear-headed approach. Thanks for showing me how it's done! This is very helpful.
    Drawing With Python