1. 09 May, 2018 1 commit
    • Leon Arnott's avatar
      Implemented the (event:) macro, an alternative to (live:), along with the "when" lambda clause. · 4a431f886235
      Leon Arnott authored
      (event:), unlike (live:), live-renders the hook only once, and only when the given lambda, which is run every 20ms, produces true. The new lambda clause, "when", is just a version of "where" typed to only be accepted by (event:). Moreover, it can't take any temp variables or refer to "it" - it must refer to globals or local temp variables outside of it. This contradicts the definition of a "lambda", but I needed a way to express deferred computation to make this macro work, and this seems smoothest from the coder's perspective.
      
      Also fixed a bug where debug view would write messages referring to global variables as if they were in a temp variable store.
      4a431f886235
  2. 16 Apr, 2018 1 commit
    • Leon Arnott's avatar
      Implemented basic functionality for the "matches" operator. · 53288f790075
      Leon Arnott authored
      This supports basic structural matching, using datatype names as the 'blanks'.
      
      Also:
      
       * Renamed typenames (the user-facing Harlowe construct) to datatypes, to avoid confusion with internals' use of "typename".
      
       * Removed some typenames whose utility seems low (lambda, hookset, typename, data) at present.
      
       * Added "or a" as an invalid operator, to preclude people writing "$a is a number or a string".
      53288f790075
  3. 15 Apr, 2018 1 commit
  4. 14 Apr, 2018 1 commit
  5. 13 Apr, 2018 1 commit
  6. 11 Apr, 2018 1 commit
    • Leon Arnott's avatar
      Added a string-specific shorthand of (repeated:) called (str-repeated:). · 412b30269ce6
      Leon Arnott authored
      This will be followed by a number of other str- macros in the coming days.
      
      Additionally, the (text:) macro now has another alias, (str:). This alias will now be the preferred name for this macro in the documentation, mainly due to the arrival of other string macros that begin with "str-", and additionally to avoid semantic conflict with the various "text-" changer macros like (text-style:).
      412b30269ce6
  7. 10 Apr, 2018 1 commit
  8. 25 Feb, 2018 1 commit
  9. 15 Jan, 2018 1 commit
  10. 07 Dec, 2017 1 commit
  11. 06 Dec, 2017 3 commits
  12. 20 Nov, 2017 2 commits
  13. 02 Aug, 2017 1 commit
  14. 16 Jun, 2017 1 commit
  15. 25 May, 2017 1 commit
    • Leon Arnott's avatar
      Changed (link-repeat:)'s documentation to match current behaviour. · 476a743d3003
      Leon Arnott authored
      The current implementation erroneously appends each iteration of (link-repeat:) instead of replacing - but in the interests of backwards-compatibility, I can't change this until another major release.
      
      Also fixes a few places where old version numbers were recorded.
      
      Closes #92.
      476a743d3003
  16. 30 Apr, 2017 1 commit
  17. 26 Apr, 2017 1 commit
  18. 08 Mar, 2017 1 commit
    • Leon Arnott's avatar
      Fixed (enchant: ?Page) not being able to override default CSS (or other CSS) on <tw-story>. · ff6e94bb72a5
      Leon Arnott authored
      This fix forcibly checks which CSS properties are being applied to the <tw-enchantment> by style changers, and adds matching "inherit" inline styles to the <tw-story> below. Yes, it's unfortunate that the <tw-story> has to be permuted for this… oh well.
      
      Also added CodeMirror mode CSS that keeps the line-break marker gutter at left:0, which, for reasons yet unknown, it sometimes isn't.
      
      Version changed to 2.0.1.
      
      Closes #85. Closes #83.
      ff6e94bb72a5
  19. 14 Feb, 2017 4 commits
  20. 31 Jan, 2017 1 commit
  21. 25 Jan, 2017 1 commit
  22. 23 Jan, 2017 1 commit
  23. 19 Jan, 2017 1 commit
    • Leon Arnott's avatar
      More documentation additions. · c22a05845ea6
      Leon Arnott authored
       * Added documentation for the (altered:) macro.
      
       * Fixed various macro doc mistakes or errors.
      
       * Altered the documentation generation script to add a "changes" section pulling two recent versions' changes directly from README.md.
      
       * Now, the new invalid operators like "x" and "are" are no longer syntax-highlighted orange when inside string literals.
      c22a05845ea6
  24. 17 Jan, 2017 3 commits
  25. 10 Dec, 2016 1 commit
  26. 03 Dec, 2016 1 commit
  27. 01 Dec, 2016 1 commit
    • Leon Arnott's avatar
      Added the (undo:) macro. · e2f2768af7da
      Leon Arnott authored
      This, along with a forthcoming (redo:) macro (which, in order to be used correctly, would require a (future:) macro, I guess), would allow the current default sidebar to be bootstrapped (constructed anew) from Harlowe code.
      
      Also changed the CSS of <html> such that its font declaration is now on <tw-story>, and fixed the CSS of <tw-error>s to make them white-on-black alongside the rest. (I may revise the latter some more to make it work when black-on-white is being used.)
      e2f2768af7da
  28. 30 Nov, 2016 1 commit
    • Leon Arnott's avatar
      Changed Harlowe 2 to use white-on-black CSS by default. · b7f75aa1c921
      Leon Arnott authored
      I've wanted to do this for a long time. I feel like white-on-black is the superior default for Twine, and was so during Twine 1, for a few reasons - black suggests a greater degree of intimacy, away from the "public" space of the white-on-black web, and invites more personal writing. Instructions for changing it back using (enchant:) are in the update notes. (Yes, I'm aware (enchant:) still needs to be documented.)
      b7f75aa1c921
  29. 26 Nov, 2016 2 commits
  30. 21 Nov, 2016 1 commit
    • Leon Arnott's avatar
      Added the (for:) macro. · 1b4be85e5df5
      Leon Arnott authored
      The addition of "each" lambdas was the final piece of this puzzle - expressing which temp variable to loop over in an unambiguous and readable syntactic way.
      1b4be85e5df5
  31. 19 Nov, 2016 1 commit
    • Leon Arnott's avatar
      Added the "each" lambda keyword, to enable no-clause lambdas to be expressed. · cb3f67c2913a
      Leon Arnott authored
      The "each" keyword is a lambda "clause" that simply sets the lambda's subject, but, importantly, it allows one to create a lambda with no actual clauses. Formerly, such a lambda would be syntactically identical to (and unable to be disambiguated from) a plain temp variable. This allows future macros (such as a possible (loop:) macro) to use lambdas that iterate over the entire sequence, without specifying any specific selection or modification.
      cb3f67c2913a