slightly shrink the clickable area for a button

akkartik
Feb 23, 2024, 11:29 PM
OL5RDL6ZVYSPSTOH4EQYFEQQPQHW35B5YWV725FN534SAIWZ6QFQC

Dependencies

  • [2] Q3EQI5LI some keyboard shortcuts on non-mobile devices
  • [3] U76D4P36 fix a typo
  • [4] OAHNWDYG .
  • [5] PW2VGQWN indent
  • [6] PP2IIHL6 stop putting button state in a global
  • [7] GDJSZLYT allow buttons to nest as well
  • [8] XX7G2FFJ intermingle freehand line drawings with text
  • [9] ZNLTRNNK highlight another global
  • [10] RK2ASPN7 add lots of buttons to the toolbar
  • [11] LJUJH5GP bugfix: propagate mouse press if any button would
  • [12] YR7AXEYB add keyboard shortcuts for common operations

Change contents

  • replacement in button.lua at line 25
    [3.139][3.2535:2597](),[3.512][3.2535:2597](),[3.2535][3.2535:2597]()
    if x>ev.x and x<ev.x+ev.w and y>ev.y and y<ev.y+ev.h then
    [3.512]
    [3.18]
    if x>ev.x and x<ev.x+ev.w-1 and y>ev.y and y<ev.y+ev.h-1 then
  • replacement in button.lua at line 42
    [2.190][2.190:254]()
    if x>ev.x and x<ev.x+ev.w and y>ev.y and y<ev.y+ev.h then
    [2.190]
    [2.254]
    if x>ev.x and x<ev.x+ev.w-1 and y>ev.y and y<ev.y+ev.h-1 then
  • replacement in 0060-next_pane_button at line 2
    [3.6252][3.6252:6368]()
    button(Global_state, 'right', {x=r-30, y=Menu_bottom, w=100, h=App.screen.height, bg={r=0.5, g=0.5, b=0.5, a=0.2},
    [3.6252]
    [3.6368]
    button(Global_state, 'right', {x=r-30, y=Menu_bottom, w=30, h=App.screen.height, bg={r=0.5, g=0.5, b=0.5, a=0.2},