finish uppercasing all globals

[?]
May 18, 2022, 2:33 AM
AVQ5MC5DWNLI6LUUIPGBLGP4LKRPGWBY4THNY25OBT2FAVHC6MCAC

Dependencies

  • [2] TGICJQD3 bugfix: move mode
  • [3] HDC3AAQP silly reason my screenshots had an ugly black line down the left
  • [4] XLDKEAFZ make sure to show the border of a drawing immediately after creating it
  • [5] IK3N7J3B reset zoom
  • [6] NW7X4AGM much better help color and copy
  • [7] MGOQ5XAV start uppercasing globals
  • [8] 2FBLO5FH adjust window size
  • [9] 2KRK3OBV don't rely on defaults
  • [10] 2INHXC3K position cursor by clicking on text
  • [11] 3XD6M3CF refactor
  • [12] 2FMZNSD7 experiment: only show drawing borders when they can be edited
  • [13] 2C7CTIQY make space for multiple kinds of width
  • [14] H7OEU6WP experimental approach to combining keyboard and mouse while drawing
  • [15] ICIIP4DB slightly better default sizing of drawings
  • [16] 3D5RFWHV stop handling drawings in cursor_pos computations
  • [17] NL5J7Z5H new mode: polygon
  • [18] PWHZPJJM always show current filename in window title
  • [19] JCSLDGAH beginnings of support for multiple shapes
  • [20] FBDRL6LH delete points or shapes
  • [21] HWPK4SMP new mode: manhattan
  • [22] 6LJZN727 handle chords
  • [23] 3CS5KKCI up/down cursor movement
  • [24] VVXVV2D2 change data model; text can now have metadata
  • [25] UTF73CBL reorg
  • [26] KCIM5UTV revert: back to freehand
  • [27] WDWXNW7V slightly strange way to move points
  • [28] OFA3PRBS autosave on keystrokes
  • [29] 5T2E3PDV couple of bugfixes to file-handling
  • [30] OTIBCAUJ love2d scaffold
  • [31] 4NDYV4WD fix 2 bugs in line selection
  • [32] 6J6EEUAY respect zoom when printing online help
  • [33] ZOOY3ME4 new mode: circle arc
  • [34] TEIKBO2T don't try to append text to drawings
  • [35] CXCAERTB icons for current_mode
  • [36] IFGAJAF7 add a level of indirection to vertices of shapes
  • [37] JVRL5TWL store device-independent coordinates inside drawings
  • [38] RXE6NQTN changing your mind mid-shape
  • [39] QCQHLMST always have a filename
  • [40] EFMLTMZG bugfix: restrict strokes to the drawing they started in
  • [41] 7Q4B6M2D esc to cancel a shape mid-click
  • [42] HDCVGN6G save each line's y coordinate, whether it's a drawing or not
  • [43] 6F6DF5T3 .
  • [44] FQJ2LBUR respect zoom when drawing drawings
  • [45] M36DBSDE bit more polish to help screen
  • [46] IYW7X3WL left/right cursor movement, deleting characters
  • [47] MNWHXPBL more lightweight; select just the stroke at the mouse
  • [48] ZD63LJ2T bugfix: keep the click to create a new drawing from creating a new shape in the drawing
  • [49] FMQ74DP3 new mode: circle
  • [50] Z4KNS42N to open a file without a terminal, drag it on!
  • [51] POT3XFCT rename
  • [52] FJ4L6N74 draw lines by default
  • [53] RJGZD4IN binary search to most natural up/down with proportional fonts
  • [54] G77XIN7M selecting a stroke
  • [55] JS6JSYOT online contextual help
  • [56] IZZVOCLB confirm that we have access to all of the love API
  • [57] HJ3PM2VT .
  • [58] ZUOL7X6V move
  • [59] IHG5RXP5 allow text to be typed while mouse hovers over drawing
  • [60] BJ5X5O4A let's prevent the text cursor from ever getting on a drawing
  • [61] T76KKDWZ turn strokes into horizontal and vertical lines
  • [62] 3SYFA5JQ show cursor even on empty lines
  • [63] L5USRTY2 inline
  • [64] TNTYISW6 rename
  • [65] VXORMHME delete experimental REPL
  • [66] 6PUNJS5B backspace
  • [67] TRCAEE2A clip drawings inside the border
  • [68] KHFU5NFD bugfix: up/down across drawings
  • [69] 7RN3AETY bugfix: text sometimes getting colored like drawing borders
  • [70] D2GCFTTT clean up repl functionality
  • [71] YKRF5V3Z starting to load/save
  • [72] V5TP27FP ctrl-+ and ctrl-- to adjust font size
  • [73] SNDZOK6Q slightly less strange now that we have the same two ways to move points as any other operation
  • [74] W4UVZETR 2 regressions:
  • [75] XX7G2FFJ intermingle freehand line drawings with text
  • [76] PLLSUOCI some missing transitions

Change contents

  • replacement in main.lua at line 33
    [7.35][8.14:30](),[8.223][8.14:30](),[8.14][8.14:30]()
    cursor_line = 1
    [7.35]
    [8.30]
    Cursor_line = 1
  • replacement in main.lua at line 39
    [8.148][7.36:76]()
    cursor_pos = #Lines[cursor_line].data+1
    [8.148]
    [8.1238]
    Cursor_pos = #Lines[Cursor_line].data+1
  • replacement in main.lua at line 41
    [8.1239][8.3:45](),[8.14][8.3:45]()
    screenw, screenh, screenflags = 0, 0, nil
    [8.1239]
    [8.1240]
    Screen_width, Screen_height, Screen_flags = 0, 0, nil
  • replacement in main.lua at line 43
    [8.1241][8.3:25](),[8.25][8.3:23]()
    current_mode = 'line'
    previous_mode = nil
    [8.1241]
    [8.3]
    Current_mode = 'line'
    Previous_mode = nil
  • replacement in main.lua at line 47
    [8.79][8.79:142](),[8.142][8.2:28]()
    -- into 256 parts. `drawingw` describes their width in pixels.
    drawingw = nil -- pixels
    [8.79]
    [8.168]
    -- into 256 parts. `Drawing_width` describes their width in pixels.
    Drawing_width = nil -- pixels
  • replacement in main.lua at line 50
    [8.207][8.207:231]()
    return n*drawingw/256
    [8.207]
    [8.231]
    return n*Drawing_width/256
  • replacement in main.lua at line 53
    [8.273][8.273:309]()
    return math.floor(n*256/drawingw)
    [8.273]
    [8.309]
    return math.floor(n*256/Drawing_width)
  • replacement in main.lua at line 56
    [8.2][8.2:13]()
    zoom = 1.5
    [8.2]
    [8.3]
    Zoom = 1.5
  • replacement in main.lua at line 58
    [8.4][8.1:24]()
    filename = 'lines.txt'
    [8.4]
    [8.47]
    Filename = 'lines.txt'
  • replacement in main.lua at line 63
    [8.136][8.46:102]()
    screenw, screenh, screenflags = love.window.getMode()
    [8.136]
    [8.24]
    Screen_width, Screen_height, Screen_flags = love.window.getMode()
  • replacement in main.lua at line 65
    [8.78][8.78:166]()
    screenw = screenw-100
    screenh = screenh-100
    love.window.setMode(screenw, screenh)
    [8.78]
    [8.1]
    Screen_width = Screen_width-100
    Screen_height = Screen_height-100
    love.window.setMode(Screen_width, Screen_height)
  • replacement in main.lua at line 69
    [8.43][8.1:42]()
    drawingw = math.floor(screenw/2/40)*40
    [8.43]
    [8.2]
    Drawing_width = math.floor(Screen_width/2/40)*40
  • replacement in main.lua at line 72
    [8.63][8.63:85]()
    filename = arg[1]
    [8.63]
    [8.157]
    Filename = arg[1]
  • replacement in main.lua at line 74
    [8.163][7.77:112]()
    Lines = load_from_disk(filename)
    [8.163]
    [7.112]
    Lines = load_from_disk(Filename)
  • replacement in main.lua at line 77
    [8.430][8.430:452]()
    cursor_line = i
    [8.430]
    [8.452]
    Cursor_line = i
  • replacement in main.lua at line 80
    [8.466][8.44:99](),[8.60][8.44:99]()
    love.window.setTitle('Text with Lines - '..filename)
    [8.466]
    [8.2]
    love.window.setTitle('Text with Lines - '..Filename)
  • replacement in main.lua at line 84
    [8.39][8.39:71]()
    filename = file:getFilename()
    [8.39]
    [8.71]
    Filename = file:getFilename()
  • replacement in main.lua at line 90
    [8.532][8.532:554]()
    cursor_line = i
    [8.532]
    [8.554]
    Cursor_line = i
  • replacement in main.lua at line 93
    [8.568][8.100:155](),[8.16][8.100:155]()
    love.window.setTitle('Text with Lines - '..filename)
    [8.568]
    [8.183]
    love.window.setTitle('Text with Lines - '..Filename)
  • replacement in main.lua at line 99
    [8.243][3.2:64]()
    love.graphics.rectangle('fill', 0, 0, screenw-1, screenh-1)
    [8.243]
    [8.302]
    love.graphics.rectangle('fill', 0, 0, Screen_width-1, Screen_height-1)
  • replacement in main.lua at line 103
    [7.245][8.14:32](),[8.36][8.14:32]()
    y = y+15*zoom
    [7.245]
    [8.1]
    y = y+15*Zoom
  • replacement in main.lua at line 110
    [7.356][8.569:666](),[8.428][8.569:666]()
    if cursor_line >= i then
    cursor_line = cursor_line+1
    [7.356]
    [8.666]
    if Cursor_line >= i then
    Cursor_line = Cursor_line+1
  • replacement in main.lua at line 114
    [8.613][8.1:34]()
    if i == cursor_line then
    [8.613]
    [8.34]
    if i == Cursor_line then
  • replacement in main.lua at line 123
    [8.62][4.1:82]()
    if pmx < 16+drawingw and pmy > line.y and pmy < line.y+pixels(line.h) then
    [8.62]
    [8.156]
    if pmx < 16+Drawing_width and pmy > line.y and pmy < line.y+pixels(line.h) then
  • replacement in main.lua at line 125
    [8.203][8.203:279](),[8.279][2.2:92]()
    love.graphics.rectangle('line', 16,line.y, drawingw,pixels(line.h))
    if icon[current_mode] then
    icon[current_mode](16+drawingw-20, line.y+4)
    [8.203]
    [2.92]
    love.graphics.rectangle('line', 16,line.y, Drawing_width,pixels(line.h))
    if icon[Current_mode] then
    icon[Current_mode](16+Drawing_width-20, line.y+4)
  • replacement in main.lua at line 129
    [2.105][2.105:161]()
    icon[previous_mode](16+drawingw-20, line.y+4)
    [2.105]
    [2.161]
    icon[Previous_mode](16+Drawing_width-20, line.y+4)
  • replacement in main.lua at line 169
    [8.546][8.33:79](),[8.79][8.1:32](),[8.1294][8.1:32]()
    love.graphics.draw(text, 25,y, 0, zoom)
    if i == cursor_line then
    [8.546]
    [8.32]
    love.graphics.draw(text, 25,y, 0, Zoom)
    if i == Cursor_line then
  • replacement in main.lua at line 172
    [8.50][8.1:142]()
    love.graphics.print('_', cursor_x(line.data, cursor_pos), y+6) -- drop the cursor down a bit to account for the increased font size
    [8.50]
    [8.411]
    love.graphics.print('_', cursor_x(line.data, Cursor_pos), y+6) -- drop the cursor down a bit to account for the increased font size
  • replacement in main.lua at line 184
    [8.60][8.249:350]()
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+drawingw then
    [8.60]
    [8.1397]
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+Drawing_width then
  • replacement in main.lua at line 195
    [8.1677][8.24:61]()
    elseif current_mode == 'move' then
    [8.1677]
    [7.468]
    elseif Current_mode == 'move' then
  • replacement in main.lua at line 198
    [8.149][8.149:246]()
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+drawingw then
    [8.149]
    [8.246]
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+Drawing_width then
  • replacement in main.lua at line 212
    [8.229][8.80:136](),[8.136][8.280:361](),[8.280][8.280:361]()
    if x >= 16 and y >= line.y and y < y+15*zoom then
    cursor_line = i
    cursor_pos = nearest_cursor_pos(line.data, x, 1)
    [8.229]
    [8.361]
    if x >= 16 and y >= line.y and y < y+15*Zoom then
    Cursor_line = i
    Cursor_pos = nearest_cursor_pos(line.data, x, 1)
  • replacement in main.lua at line 219
    [8.132][8.132:444]()
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+drawingw then
    if current_mode == 'freehand' then
    drawing.pending = {mode=current_mode, points={{x=coord(x-16), y=coord(y-drawing.y)}}}
    elseif current_mode == 'line' or current_mode == 'manhattan' then
    [8.132]
    [8.444]
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+Drawing_width then
    if Current_mode == 'freehand' then
    drawing.pending = {mode=Current_mode, points={{x=coord(x-16), y=coord(y-drawing.y)}}}
    elseif Current_mode == 'line' or Current_mode == 'manhattan' then
  • replacement in main.lua at line 224
    [8.526][8.526:626]()
    drawing.pending = {mode=current_mode, p1=j}
    elseif current_mode == 'polygon' then
    [8.526]
    [8.626]
    drawing.pending = {mode=Current_mode, p1=j}
    elseif Current_mode == 'polygon' then
  • replacement in main.lua at line 227
    [8.708][8.708:815]()
    drawing.pending = {mode=current_mode, vertices={j}}
    elseif current_mode == 'circle' then
    [8.708]
    [8.815]
    drawing.pending = {mode=Current_mode, vertices={j}}
    elseif Current_mode == 'circle' then
  • replacement in main.lua at line 230
    [8.897][8.897:955]()
    drawing.pending = {mode=current_mode, center=j}
    [8.897]
    [8.955]
    drawing.pending = {mode=Current_mode, center=j}
  • replacement in main.lua at line 239
    [8.1626][8.211:301]()
    if current_mode == 'move' then
    current_mode = previous_mode
    previous_mode = nil
    [8.1626]
    [7.570]
    if Current_mode == 'move' then
    Current_mode = Previous_mode
    Previous_mode = nil
  • replacement in main.lua at line 295
    [8.2109][8.2:21](),[8.21][7.3123:3157]()
    if filename then
    save_to_disk(Lines, filename)
    [8.2109]
    [8.55]
    if Filename then
    save_to_disk(Lines, Filename)
  • replacement in main.lua at line 509
    [8.47][7.3158:3216]()
    if Lines[cursor_line].mode == 'drawing' then return end
    [8.47]
    [8.490]
    if Lines[Cursor_line].mode == 'drawing' then return end
  • replacement in main.lua at line 511
    [8.509][8.509:534](),[8.534][7.3217:3285]()
    if cursor_pos > 1 then
    byteoffset = utf8.offset(Lines[cursor_line].data, cursor_pos-1)
    [8.509]
    [8.597]
    if Cursor_pos > 1 then
    byteoffset = utf8.offset(Lines[Cursor_line].data, Cursor_pos-1)
  • replacement in main.lua at line 516
    [8.629][7.3286:3419](),[8.1081][8.747:775](),[7.3419][8.747:775](),[8.747][8.747:775](),[8.775][8.62:81](),[8.85][8.62:81](),[8.81][7.3420:3454]()
    Lines[cursor_line].data = string.sub(Lines[cursor_line].data, 1, byteoffset)..t..string.sub(Lines[cursor_line].data, byteoffset+1)
    cursor_pos = cursor_pos+1
    if filename then
    save_to_disk(Lines, filename)
    [8.629]
    [8.115]
    Lines[Cursor_line].data = string.sub(Lines[Cursor_line].data, 1, byteoffset)..t..string.sub(Lines[Cursor_line].data, byteoffset+1)
    Cursor_pos = Cursor_pos+1
    if Filename then
    save_to_disk(Lines, Filename)
  • replacement in main.lua at line 527
    [8.224][7.3455:3518](),[8.1145][8.465:516](),[7.3518][8.465:516](),[8.465][8.465:516]()
    table.insert(Lines, cursor_line+1, {mode='text', data=''})
    cursor_line = cursor_line+1
    cursor_pos = 1
    [8.224]
    [8.31]
    table.insert(Lines, Cursor_line+1, {mode='text', data=''})
    Cursor_line = Cursor_line+1
    Cursor_pos = 1
  • replacement in main.lua at line 531
    [8.66][8.692:719](),[8.719][7.3519:3667]()
    if cursor_pos > 1 then
    local byte_start = utf8.offset(Lines[cursor_line].data, cursor_pos-1)
    local byte_end = utf8.offset(Lines[cursor_line].data, cursor_pos)
    [8.66]
    [8.867]
    if Cursor_pos > 1 then
    local byte_start = utf8.offset(Lines[Cursor_line].data, Cursor_pos-1)
    local byte_end = utf8.offset(Lines[Cursor_line].data, Cursor_pos)
  • replacement in main.lua at line 536
    [8.917][7.3668:3804]()
    Lines[cursor_line].data = string.sub(Lines[cursor_line].data, 1, byte_start-1)..string.sub(Lines[cursor_line].data, byte_end)
    [8.917]
    [8.1053]
    Lines[Cursor_line].data = string.sub(Lines[Cursor_line].data, 1, byte_start-1)..string.sub(Lines[Cursor_line].data, byte_end)
  • replacement in main.lua at line 538
    [8.1066][7.3805:3894]()
    Lines[cursor_line].data = string.sub(Lines[cursor_line].data, 1, byte_start-1)
    [8.1066]
    [8.1155]
    Lines[Cursor_line].data = string.sub(Lines[Cursor_line].data, 1, byte_start-1)
  • replacement in main.lua at line 540
    [8.1167][8.1167:1201]()
    cursor_pos = cursor_pos-1
    [8.1167]
    [8.1201]
    Cursor_pos = Cursor_pos-1
  • replacement in main.lua at line 542
    [8.1211][8.1211:1243](),[8.1243][7.3895:3991]()
    elseif cursor_line > 1 then
    if Lines[cursor_line-1].mode == 'drawing' then
    table.remove(Lines, cursor_line-1)
    [8.1211]
    [8.1377]
    elseif Cursor_line > 1 then
    if Lines[Cursor_line-1].mode == 'drawing' then
    table.remove(Lines, Cursor_line-1)
  • replacement in main.lua at line 547
    [7.4014][7.4014:4201]()
    cursor_pos = utf8.len(Lines[cursor_line-1].data)+1
    Lines[cursor_line-1].data = Lines[cursor_line-1].data..Lines[cursor_line].data
    table.remove(Lines, cursor_line)
    [7.4014]
    [8.1411]
    Cursor_pos = utf8.len(Lines[Cursor_line-1].data)+1
    Lines[Cursor_line-1].data = Lines[Cursor_line-1].data..Lines[Cursor_line].data
    table.remove(Lines, Cursor_line)
  • replacement in main.lua at line 551
    [8.1537][8.1537:1571]()
    cursor_line = cursor_line-1
    [8.1421]
    [8.1292]
    Cursor_line = Cursor_line-1
  • replacement in main.lua at line 554
    [8.1330][8.1330:1391]()
    if cursor_pos > 1 then
    cursor_pos = cursor_pos - 1
    [8.1330]
    [8.1391]
    if Cursor_pos > 1 then
    Cursor_pos = Cursor_pos-1
  • replacement in main.lua at line 558
    [8.1430][7.4202:4253](),[8.2147][8.1476:1510](),[7.4253][8.1476:1510](),[8.1476][8.1476:1510]()
    if cursor_pos <= #Lines[cursor_line].data then
    cursor_pos = cursor_pos + 1
    [8.1430]
    [8.517]
    if Cursor_pos <= #Lines[Cursor_line].data then
    Cursor_pos = Cursor_pos+1
  • replacement in main.lua at line 562
    [8.189][8.189:208]()
    cursor_pos = 1
    [8.189]
    [8.208]
    Cursor_pos = 1
  • replacement in main.lua at line 564
    [8.237][7.4254:4298]()
    cursor_pos = #Lines[cursor_line].data+1
    [8.237]
    [8.26]
    Cursor_pos = #Lines[Cursor_line].data+1
  • replacement in main.lua at line 566
    [8.58][7.4299:4498]()
    if cursor_pos <= #Lines[cursor_line].data then
    local byte_start = utf8.offset(Lines[cursor_line].data, cursor_pos)
    local byte_end = utf8.offset(Lines[cursor_line].data, cursor_pos+1)
    [8.58]
    [8.257]
    if Cursor_pos <= #Lines[Cursor_line].data then
    local byte_start = utf8.offset(Lines[Cursor_line].data, Cursor_pos)
    local byte_end = utf8.offset(Lines[Cursor_line].data, Cursor_pos+1)
  • replacement in main.lua at line 571
    [8.307][7.4499:4635]()
    Lines[cursor_line].data = string.sub(Lines[cursor_line].data, 1, byte_start-1)..string.sub(Lines[cursor_line].data, byte_end)
    [8.307]
    [8.443]
    Lines[Cursor_line].data = string.sub(Lines[Cursor_line].data, 1, byte_start-1)..string.sub(Lines[Cursor_line].data, byte_end)
  • replacement in main.lua at line 573
    [8.456][7.4636:4725]()
    Lines[cursor_line].data = string.sub(Lines[cursor_line].data, 1, byte_start-1)
    [8.456]
    [8.545]
    Lines[Cursor_line].data = string.sub(Lines[Cursor_line].data, 1, byte_start-1)
  • replacement in main.lua at line 575
    [8.557][8.557:592]()
    -- no change to cursor_pos
    [8.557]
    [8.592]
    -- no change to Cursor_pos
  • replacement in main.lua at line 580
    [8.553][7.4726:4772](),[7.4772][8.1596:1636](),[8.1596][8.1596:1636]()
    assert(Lines[cursor_line].mode == 'text')
    local new_cursor_line = cursor_line
    [8.553]
    [8.1636]
    assert(Lines[Cursor_line].mode == 'text')
    local new_cursor_line = Cursor_line
  • replacement in main.lua at line 585
    [7.4825][7.4825:4897](),[7.4897][8.1835:1873](),[8.1835][8.1835:1873](),[8.1873][7.4898:4982]()
    local old_x = cursor_x(Lines[new_cursor_line].data, cursor_pos)
    cursor_line = new_cursor_line
    cursor_pos = nearest_cursor_pos(Lines[cursor_line].data, old_x, cursor_pos)
    [7.4825]
    [8.1874]
    local old_x = cursor_x(Lines[new_cursor_line].data, Cursor_pos)
    Cursor_line = new_cursor_line
    Cursor_pos = nearest_cursor_pos(Lines[Cursor_line].data, old_x, Cursor_pos)
  • replacement in main.lua at line 592
    [8.746][7.4983:5029](),[7.5029][8.1935:1975](),[8.1935][8.1935:1975]()
    assert(Lines[cursor_line].mode == 'text')
    local new_cursor_line = cursor_line
    [8.746]
    [7.5030]
    assert(Lines[Cursor_line].mode == 'text')
    local new_cursor_line = Cursor_line
  • replacement in main.lua at line 597
    [7.5121][7.5121:5193](),[7.5193][8.2179:2217](),[8.2179][8.2179:2217](),[8.2217][7.5194:5278]()
    local old_x = cursor_x(Lines[new_cursor_line].data, cursor_pos)
    cursor_line = new_cursor_line
    cursor_pos = nearest_cursor_pos(Lines[cursor_line].data, old_x, cursor_pos)
    [7.5121]
    [8.2218]
    local old_x = cursor_x(Lines[new_cursor_line].data, Cursor_pos)
    Cursor_line = new_cursor_line
    Cursor_pos = nearest_cursor_pos(Lines[Cursor_line].data, old_x, Cursor_pos)
  • replacement in main.lua at line 604
    [8.166][8.1:30](),[8.30][8.166:186](),[8.166][8.166:186](),[8.186][8.31:60]()
    drawingw = drawingw/zoom
    zoom = zoom+0.5
    drawingw = drawingw*zoom
    [8.166]
    [8.186]
    Drawing_width = Drawing_width/Zoom
    Zoom = Zoom+0.5
    Drawing_width = Drawing_width*Zoom
  • replacement in main.lua at line 608
    [8.215][8.61:90](),[8.90][8.215:235](),[8.215][8.215:235](),[8.235][5.1:30]()
    drawingw = drawingw/zoom
    zoom = zoom-0.5
    drawingw = drawingw*zoom
    [8.215]
    [5.30]
    Drawing_width = Drawing_width/Zoom
    Zoom = Zoom-0.5
    Drawing_width = Drawing_width*Zoom
  • replacement in main.lua at line 612
    [5.59][5.59:103](),[5.103][8.91:120](),[8.235][8.91:120]()
    drawingw = drawingw/zoom
    zoom = 1.5
    drawingw = drawingw*zoom
    [5.59]
    [8.656]
    Drawing_width = Drawing_width/Zoom
    Zoom = 1.5
    Drawing_width = Drawing_width*Zoom
  • replacement in main.lua at line 620
    [8.559][8.111:141](),[8.111][8.111:141]()
    current_mode = 'freehand'
    [8.559]
    [8.560]
    Current_mode = 'freehand'
  • replacement in main.lua at line 622
    [8.620][8.3:32](),[8.1964][8.3:32]()
    current_mode = 'polygon'
    [8.620]
    [8.32]
    Current_mode = 'polygon'
  • replacement in main.lua at line 624
    [8.86][8.1964:1993](),[8.1964][8.1964:1993]()
    current_mode = 'polygon'
    [8.86]
    [8.87]
    Current_mode = 'polygon'
  • replacement in main.lua at line 636
    [8.407][8.1993:2077](),[8.1993][8.1993:2077]()
    elseif love.mouse.isDown('1') and chord == 'p' and current_mode == 'polygon' then
    [8.407]
    [8.2077]
    elseif love.mouse.isDown('1') and chord == 'p' and Current_mode == 'polygon' then
  • replacement in main.lua at line 642
    [8.681][8.1382:1410](),[8.1382][8.1382:1410](),[8.1410][8.2005:2088]()
    current_mode = 'circle'
    elseif love.mouse.isDown('1') and chord == 'a' and current_mode == 'circle' then
    [8.681]
    [8.2088]
    Current_mode = 'circle'
    elseif love.mouse.isDown('1') and chord == 'a' and Current_mode == 'circle' then
  • replacement in main.lua at line 652
    [8.462][8.462:490]()
    current_mode = 'circle'
    [8.462]
    [8.490]
    Current_mode = 'circle'
  • replacement in main.lua at line 663
    [8.195][8.195:221]()
    current_mode = 'line'
    [8.195]
    [8.221]
    Current_mode = 'line'
  • replacement in main.lua at line 674
    [8.906][8.447:473]()
    current_mode = 'line'
    [8.906]
    [8.906]
    Current_mode = 'line'
  • replacement in main.lua at line 680
    [8.1377][8.1377:1408]()
    current_mode = 'manhattan'
    [8.1377]
    [8.1408]
    Current_mode = 'manhattan'
  • replacement in main.lua at line 693
    [8.742][8.1494:1525](),[8.40][8.1494:1525]()
    current_mode = 'manhattan'
    [8.742]
    [8.40]
    Current_mode = 'manhattan'
  • replacement in main.lua at line 706
    [8.930][8.930:993](),[8.993][8.319:379]()
    previous_mode = current_mode
    current_mode = 'move'
    drawing.pending = {mode=current_mode, target_point=p}
    [8.930]
    [7.5279]
    Previous_mode = Current_mode
    Current_mode = 'move'
    drawing.pending = {mode=Current_mode, target_point=p}
  • replacement in main.lua at line 714
    [8.537][8.537:660]()
    previous_mode = current_mode
    current_mode = 'move'
    drawing.pending = {mode=current_mode, target_point=p}
    [8.537]
    [7.5310]
    Previous_mode = Current_mode
    Current_mode = 'move'
    drawing.pending = {mode=Current_mode, target_point=p}
  • replacement in main.lua at line 759
    [8.739][8.236:283]()
    return 25+text_before_cursor:getWidth()*zoom
    [8.739]
    [8.778]
    return 25+text_before_cursor:getWidth()*Zoom
  • replacement in main.lua at line 800
    [8.3094][8.895:994](),[8.955][8.895:994]()
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+drawingw then
    [8.3094]
    [8.1054]
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+Drawing_width then
  • replacement in main.lua at line 812
    [8.292][8.995:1094]()
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+drawingw then
    [8.292]
    [8.1094]
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+Drawing_width then
  • replacement in main.lua at line 829
    [8.1290][8.1290:1389]()
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+drawingw then
    [8.1290]
    [8.1389]
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+Drawing_width then
  • replacement in main.lua at line 846
    [8.1690][8.1690:1789]()
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+drawingw then
    [8.1690]
    [8.1789]
    if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 16 and x < 16+Drawing_width then
  • replacement in main.lua at line 1086
    [8.775][8.1:79](),[8.79][6.1:106](),[6.106][8.193:574](),[8.193][8.193:574](),[8.574][8.1273:1310](),[8.1273][8.1273:1310](),[8.1310][8.575:693]()
    love.graphics.print("Things you can do:", 16+30,y, 0, zoom)
    y = y+15*zoom
    love.graphics.print("* Press the mouse button to start drawing a "..current_shape(), 16+30,y, 0, zoom)
    y = y+15*zoom
    love.graphics.print("* Hover on a point and press 'ctrl+v' to start moving it,", 16+30,y, 0, zoom)
    y = y+15*zoom
    love.graphics.print("then press the mouse button to finish", 16+30+bullet_indent(),y, 0, zoom)
    y = y+15*zoom
    love.graphics.print("* Hover on a point or shape and press 'ctrl+d' to delete it", 16+30,y, 0, zoom)
    y = y+15*zoom
    y = y+15*zoom
    if current_mode ~= 'freehand' then
    love.graphics.print("* Press 'ctrl+f' to switch to drawing freehand strokes", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.775]
    [8.1414]
    love.graphics.print("Things you can do:", 16+30,y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print("* Press the mouse button to start drawing a "..current_shape(), 16+30,y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print("* Hover on a point and press 'ctrl+v' to start moving it,", 16+30,y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print("then press the mouse button to finish", 16+30+bullet_indent(),y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print("* Hover on a point or shape and press 'ctrl+d' to delete it", 16+30,y, 0, Zoom)
    y = y+15*Zoom
    y = y+15*Zoom
    if Current_mode ~= 'freehand' then
    love.graphics.print("* Press 'ctrl+f' to switch to drawing freehand strokes", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1101
    [8.1420][8.1420:1453](),[8.1453][8.694:801]()
    if current_mode ~= 'line' then
    love.graphics.print("* Press 'ctrl+l' to switch to drawing lines", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.1420]
    [8.1546]
    if Current_mode ~= 'line' then
    love.graphics.print("* Press 'ctrl+l' to switch to drawing lines", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1105
    [8.1552][8.1552:1590](),[8.1590][8.802:929]()
    if current_mode ~= 'manhattan' then
    love.graphics.print("* Press 'ctrl+m' to switch to drawing horizontal/vertical lines", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.1552]
    [8.1703]
    if Current_mode ~= 'manhattan' then
    love.graphics.print("* Press 'ctrl+m' to switch to drawing horizontal/vertical lines", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1109
    [8.1709][8.1709:1744](),[8.1744][8.930:1044]()
    if current_mode ~= 'circle' then
    love.graphics.print("* Press 'ctrl+c' to switch to drawing circles/arcs", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.1709]
    [8.1844]
    if Current_mode ~= 'circle' then
    love.graphics.print("* Press 'ctrl+c' to switch to drawing circles/arcs", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1113
    [8.1850][8.1850:1886](),[8.1886][8.1045:1155]()
    if current_mode ~= 'polygon' then
    love.graphics.print("* Press 'ctrl+g' to switch to drawing polygons", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.1850]
    [8.1982]
    if Current_mode ~= 'polygon' then
    love.graphics.print("* Press 'ctrl+g' to switch to drawing polygons", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1117
    [8.1988][8.1156:1262](),[8.1262][5.104:178](),[5.178][8.1262:1278](),[8.1262][8.1262:1278](),[8.1278][5.179:195](),[5.195][8.1278:1372](),[8.1278][8.1278:1372]()
    love.graphics.print("* Press 'ctrl+=' or 'ctrl+-' to zoom in or out", 16+30,y, 0, zoom)
    y = y+15*zoom
    love.graphics.print("* Press 'ctrl+0' to reset zoom", 16+30,y, 0, zoom)
    y = y+15*zoom
    y = y+15*zoom
    love.graphics.print("Hit 'esc' now to hide this message", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.1988]
    [6.107]
    love.graphics.print("* Press 'ctrl+=' or 'ctrl+-' to Zoom in or out", 16+30,y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print("* Press 'ctrl+0' to reset Zoom", 16+30,y, 0, Zoom)
    y = y+15*Zoom
    y = y+15*Zoom
    love.graphics.print("Hit 'esc' now to hide this message", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1125
    [6.146][6.146:245]()
    love.graphics.rectangle('fill', 16,drawing.y, drawingw, math.max(pixels(drawing.h),y-drawing.y))
    [6.146]
    [8.1988]
    love.graphics.rectangle('fill', 16,drawing.y, Drawing_width, math.max(pixels(drawing.h),y-drawing.y))
  • replacement in main.lua at line 1131
    [8.2175][6.246:349](),[6.349][8.1470:1568](),[8.1470][8.1470:1568](),[8.1568][8.2342:2379](),[8.2342][8.2342:2379](),[8.2379][6.350:451](),[6.451][8.1677:1695](),[8.1677][8.1677:1695](),[8.1695][8.2491:2559](),[8.2491][8.2491:2559](),[8.2559][6.452:551](),[6.551][8.1793:1811](),[8.1793][8.1793:1811](),[8.1811][8.2660:2699](),[8.2660][8.2660:2699]()
    love.graphics.print("You're currently drawing a "..current_shape(drawing.pending), 16+30,y, 0, zoom)
    y = y+15*zoom
    love.graphics.print('Things you can do now:', 16+30,y, 0, zoom)
    y = y+15*zoom
    if current_mode == 'freehand' then
    love.graphics.print('* Release the mouse button to finish drawing the stroke', 16+30,y, 0, zoom)
    y = y+15*zoom
    elseif current_mode == 'line' or current_mode == 'manhattan' then
    love.graphics.print('* Release the mouse button to finish drawing the line', 16+30,y, 0, zoom)
    y = y+15*zoom
    elseif current_mode == 'circle' then
    [8.2175]
    [8.2699]
    love.graphics.print("You're currently drawing a "..current_shape(drawing.pending), 16+30,y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print('Things you can do now:', 16+30,y, 0, Zoom)
    y = y+15*Zoom
    if Current_mode == 'freehand' then
    love.graphics.print('* Release the mouse button to finish drawing the stroke', 16+30,y, 0, Zoom)
    y = y+15*Zoom
    elseif Current_mode == 'line' or Current_mode == 'manhattan' then
    love.graphics.print('* Release the mouse button to finish drawing the line', 16+30,y, 0, Zoom)
    y = y+15*Zoom
    elseif Current_mode == 'circle' then
  • replacement in main.lua at line 1143
    [8.2744][6.552:655](),[6.655][8.1918:2029](),[8.1918][8.1918:2029]()
    love.graphics.print('* Release the mouse button to finish drawing the circle', 16+30,y, 0, zoom)
    y = y+15*zoom
    love.graphics.print("* Press 'a' to draw just an arc of a circle", 16+30,y, 0, zoom)
    [8.2744]
    [8.2938]
    love.graphics.print('* Release the mouse button to finish drawing the circle', 16+30,y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print("* Press 'a' to draw just an arc of a circle", 16+30,y, 0, Zoom)
  • replacement in main.lua at line 1147
    [8.2947][6.656:756]()
    love.graphics.print('* Release the mouse button to finish drawing the arc', 16+30,y, 0, zoom)
    [8.2947]
    [8.3037]
    love.graphics.print('* Release the mouse button to finish drawing the arc', 16+30,y, 0, Zoom)
  • replacement in main.lua at line 1149
    [8.3045][8.2130:2148](),[8.2148][8.3058:3098](),[8.3058][8.3058:3098](),[8.3098][6.757:859](),[6.859][8.2249:2373](),[8.2249][8.2249:2373]()
    y = y+15*zoom
    elseif current_mode == 'polygon' then
    love.graphics.print('* Release the mouse button to finish drawing the polygon', 16+30,y, 0, zoom)
    y = y+15*zoom
    love.graphics.print("* Press 'p' to add a vertex to the polygon", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.3045]
    [8.3294]
    y = y+15*Zoom
    elseif Current_mode == 'polygon' then
    love.graphics.print('* Release the mouse button to finish drawing the polygon', 16+30,y, 0, Zoom)
    y = y+15*Zoom
    love.graphics.print("* Press 'p' to add a vertex to the polygon", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1156
    [8.3300][8.2374:2521](),[8.243][8.3311:3344](),[8.2521][8.3311:3344](),[8.3311][8.3311:3344](),[8.3344][8.2522:2624]()
    love.graphics.print("* Press 'esc' then release the mouse button to cancel the current shape", 16+30,y, 0, zoom)
    y = y+15*zoom
    y = y+15*zoom
    if current_mode ~= 'line' then
    love.graphics.print("* Press 'l' to switch to drawing lines", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.3300]
    [8.3432]
    love.graphics.print("* Press 'esc' then release the mouse button to cancel the current shape", 16+30,y, 0, Zoom)
    y = y+15*Zoom
    y = y+15*Zoom
    if Current_mode ~= 'line' then
    love.graphics.print("* Press 'l' to switch to drawing lines", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1163
    [8.3438][8.3438:3476](),[8.3476][8.2625:2747]()
    if current_mode ~= 'manhattan' then
    love.graphics.print("* Press 'm' to switch to drawing horizontal/vertical lines", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.3438]
    [8.3584]
    if Current_mode ~= 'manhattan' then
    love.graphics.print("* Press 'm' to switch to drawing horizontal/vertical lines", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1167
    [8.3590][8.3590:3625](),[8.3625][8.2748:2857]()
    if current_mode ~= 'circle' then
    love.graphics.print("* Press 'c' to switch to drawing circles/arcs", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.3590]
    [8.3720]
    if Current_mode ~= 'circle' then
    love.graphics.print("* Press 'c' to switch to drawing circles/arcs", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1171
    [8.3726][8.3726:3762](),[8.3762][8.2858:2963]()
    if current_mode ~= 'polygon' then
    love.graphics.print("* Press 'g' to switch to drawing polygons", 16+30,y, 0, zoom)
    y = y+15*zoom
    [8.3726]
    [8.3853]
    if Current_mode ~= 'polygon' then
    love.graphics.print("* Press 'g' to switch to drawing polygons", 16+30,y, 0, Zoom)
    y = y+15*Zoom
  • replacement in main.lua at line 1176
    [6.899][6.899:998]()
    love.graphics.rectangle('fill', 16,drawing.y, drawingw, math.max(pixels(drawing.h),y-drawing.y))
    [6.899]
    [8.3859]
    love.graphics.rectangle('fill', 16,drawing.y, Drawing_width, math.max(pixels(drawing.h),y-drawing.y))
  • replacement in main.lua at line 1180
    [6.1029][8.3898:3935](),[8.3898][8.3898:3935]()
    if current_mode == 'freehand' then
    [6.1029]
    [8.3935]
    if Current_mode == 'freehand' then
  • replacement in main.lua at line 1182
    [8.3964][8.3964:4001]()
    elseif current_mode == 'line' then
    [8.3964]
    [8.4001]
    elseif Current_mode == 'line' then
  • replacement in main.lua at line 1184
    [8.4028][8.4028:4070]()
    elseif current_mode == 'manhattan' then
    [8.4028]
    [8.4070]
    elseif Current_mode == 'manhattan' then
  • replacement in main.lua at line 1186
    [8.4108][6.1030:1101]()
    elseif current_mode == 'circle' and shape and shape.start_angle then
    [8.4108]
    [6.1101]
    elseif Current_mode == 'circle' and shape and shape.start_angle then
  • replacement in main.lua at line 1189
    [8.4115][8.4115:4139]()
    return current_mode
    [8.4115]
    [8.4139]
    return Current_mode