[tw5] Filter to exclude tiddlers from includeWikis

2022-01-03 Thread Louis Davout
Hello,

I'm running several TW 5.2.1 wikis on node and I use the includeWikis 
properties in tiddlywiki.info file. Example wiki AAA has

"includeWikis": [
   {"path": "../BBB"}
]

Is there a filter expression I can use from within wiki AAA that will 
exclude tiddlers from BBB?

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/316c974c-c76a-44b7-b1dd-794f8a246cc2n%40googlegroups.com.


[tw5] Macro Parameters & Quotes: Macros v Variables

2021-12-24 Thread Louis Davout
 

I just discovered something that was inhibiting my understanding of TW. 
It's probably somewhere in the docs and I either missed it or forgot it. 
But it might help someone else in the future.

In context of being a parameter, macros and variables behave differently 
from each other when enclosed in quotes.

If macro parameter is set to a variable that is not surrounded by quotes, 
variable is evaluated as expected. (A below).

If macro parameter is set to a variable that is surrounded by quotes, 
variable is *not* evaluated. (B & C below).

If macro parameter is set to a macro, that second macro is expanded *regardless 
of quotes* (D, E, F below).
```
\define mac(mac_param)
<$text text="$mac_param$"/>
\end

\define mac2(mac_param) MMM: $mac_param$

<$set name="var" value="VVV">
A: <$macrocall $name="mac" mac_param=<>/>
B: <$macrocall $name="mac" mac_param="<>"/>
C: <$macrocall $name="mac" mac_param="""<>"""/>
D: <$macrocall $name="mac" mac_param=<>/>
E: <$macrocall $name="mac" mac_param="<>"/>
F: <$macrocall $name="mac" mac_param="""<>"""/>

```

A: VVV
B: <>
C: <>
D: MMM: AAA
E: <$macrocall $name="mac" mac_param="MMM: AAA"/>
F: <$text text="MMM: AAA"/>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/44dfcc8d-b12a-4c4d-ba36-7febd338b47bn%40googlegroups.com.


[tw5] Upgrade to 5.2.1 cleaned out plugin dir

2021-12-22 Thread Louis Davout
I'm running TW 5.2.0 on node 14.16.1 on windows 10. I upgraded TW to 5.2.1 
via ` npm update -g tiddlywiki` After it was done, the plugin dir of my 
install AppData\Roaming\npm\node_modules\tiddlywiki\plugins\ was cleaned 
out - all files gone. I keep an offsite back up of my files, so it wasn't a 
big deal. I was able to restore all the plugins. Is that normal expected 
beahvior?

Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/541fe276-ec9c-4a23-82f6-368567989bcdn%40googlegroups.com.


[tw5] Re: Javascript non-macros

2021-12-16 Thread Louis Davout
Thanks, I will look at creating custom widgets.

If what I want to do is simple, such as set a field to a constant value, 
yea sure I can do that. But once something involves complex logic I often 
get stymied. It seems every time I gain an insight into how TW works, I 
discover it doesn't work as I thought. At this point I have become 
incredibly frustrated. I find the syntax inconsistent with too many 
exceptions plus when and how to "hook together" different code types 
(macros, widgets, etc). https://groktiddlywiki.com & 
https://anthonymuscio.github.io/#Standard%20Nomenclature have been helpful 
but it is eluding my understanding. Despite javascript's own quirks, at 
least it makes sense to me.

On Thursday, December 16, 2021 at 11:00:07 AM UTC-5 PMario wrote:

> On Thursday, December 16, 2021 at 4:24:14 PM UTC+1 davou...@gmail.com 
> wrote:
>
>> The dev documentation 
>>  states 
>> "Macros are just used to return a chunk of wikitext for further processing. 
>> They should not make modifications to tiddlers in the wiki store."
>>
>
> The main reason, why macros shouldn't have side effects is, that they 
> don't have a .refresh() function of their own. They are refreshed by 
> "parent" widgets. 
>
> So if you want to implement your own functionality, that survives a page 
> refresh you need to create widgets. 
>  
>
>> Is there a hook point where I can have my own js code that can modify 
>> tiddlers?
>>
>
> Widgets.
>  
>
>> Basically I want to be able to set field values from js. As I'd much 
>> rather use js than the conglomerate that is wikitext, widgets, filters, and 
>> macros.
>>
>
> It depends on what you really want to do. If you just want to change some 
> fields you are probably a 100 times faster to get stuff done if you use the 
> existing wikitext functionality. 
>
> If you just want to see how the TW internals work you could have a closer 
> look how widgets work. 
>
> In TW everything is driven by the "refresh" mechanism, which is 
> automatically triggered as soon as you change a tiddler content in the 
> store. 
>
> Changes to the tiddler store are usually driven by user interaction with 
> "buttons" and "action widgets". .. So user actions change the tiddler 
> content, which in turn automatically updates the UI. ... 
>
> The internal tiddler store is immutable. So changing tiddlers is only 
> possible writing a completely new tiddler. Overwriting a tiddler is done in 
> the following way. -- read tiddler content -- modify the content -- write 
> tiddler with the same or a new title. Once the store is updated a "change" 
> event is fired by the core. All widgets that depend on the tiddler content 
> that has been changed, trigger their .refresh() function, which may write 
> new HTML output to the DOM. 
>
> ... So it really depends, what you want to do. .. If you could be more 
> specific about your usecase, I could probably point you in the right 
> direction in the core code. 
>
> -mario
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/fba0883c-5824-437f-8db4-c2735049932dn%40googlegroups.com.


[tw5] Javascript non-macros

2021-12-16 Thread Louis Davout
The dev documentation 
 states 
"Macros are just used to return a chunk of wikitext for further processing. 
They should not make modifications to tiddlers in the wiki store."

Is there such a thing as a Javascript non-macro? Is there a hook point 
where I can have my own js code that can modify tiddlers? Basically I want 
to be able to set field values from js. As I'd much rather use js than the 
conglomerate that is wikitext, widgets, filters, and macros.

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/03612a8e-a9c0-4cfe-b03d-d4fbc6988116n%40googlegroups.com.


[tw5] Re: Creating custom excise dropdown

2021-11-10 Thread Louis Davout
Thanks for the reply.

I see that my post did not include my image. Let's try this 
https://github.com/davout1806/temp/blob/main/excise-dropdown.png

Say we have the following tiddler ABC with Tags: Example, Contrived

Line 1

Line 2

Line 3
-

I select Line 2 and click my new excise button with the new form. 

If the first checkbox ("Prepend Title of this tiddler + '/' to Title of new 
tiddler ") is checked then the name of the new tiddler would be prepended 
with 'ABC/'. Whether the script puts that string into form field "Title of 
new tiddler" or only in the background, does not matter to me.

If the third checkbox ("Tag new tiddler with the same Tags as this 
tiddler") is checked then the tags Example and Contrived will be added to 
the new tiddler. I realize this may be more difficult especially if tiddler 
ABC is new and has yet to be saved.

Thanks.
On Wednesday, November 10, 2021 at 9:28:58 AM UTC-5 Mark S. wrote:

> It looks like you're doing well. It might help if you explained what you 
> want your new excise to do. It might not require a new js script. 
>
> On Monday, November 8, 2021 at 4:23:10 PM UTC-8 davou...@gmail.com wrote:
>
>> Hi,
>>
>> I would like to create a custom excise dropdown. I'd rather not modify 
>> anything related to core. So I cloned:
>>
>>- $:/core/ui/EditorToolbar/excise-dropdown to 
>>$:/davout/ui/EditorToolbar/excise-dropdown
>>   - Came up with:
>>- $:/core/ui/EditorToolbar/excise to $:/davout/ui/EditorToolbar/excise
>>   - changed dropdown to $:/davout/ui/EditorToolbar/excise-dropdown
>>- $:/core/modules/editor/operations/text/excise.js to $:/
>>davout/modules/editor/operations/text/excise.js
>>
>> A few questions. (BTW, I'm using 5.2.0)
>>
>>1. Am I going about this the right way? If this is even possible?
>>2. How can get my button to use my 
>> $:/davout/modules/editor/operations/text/excise.js 
>>rather than the default  $:/
>>core/modules/editor/operations/text/excise.js 
>>3. In  $:/core/ui/EditorToolbar/excise-dropdown what is 
>>$config-title$ referring to?
>>
>> Thanks.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/815c749a-e1fd-463d-a60a-03b5be3becb0n%40googlegroups.com.


[tw5] Creating custom excise dropdown

2021-11-08 Thread Louis Davout
Hi,

I would like to create a custom excise dropdown. I'd rather not modify 
anything related to core. So I cloned:

   - $:/core/ui/EditorToolbar/excise-dropdown to 
   $:/davout/ui/EditorToolbar/excise-dropdown
  - Came up with:
   - $:/core/ui/EditorToolbar/excise to $:/davout/ui/EditorToolbar/excise
  - changed dropdown to $:/davout/ui/EditorToolbar/excise-dropdown
   - $:/core/modules/editor/operations/text/excise.js to $:/
   davout/modules/editor/operations/text/excise.js

A few questions. (BTW, I'm using 5.2.0)

   1. Am I going about this the right way? If this is even possible?
   2. How can get my button to use my 
$:/davout/modules/editor/operations/text/excise.js 
   rather than the default  $:/core/modules/editor/operations/text/excise.js 
   3. In  $:/core/ui/EditorToolbar/excise-dropdown what is $config-title$ 
   referring to?

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/bb026271-02f0-4797-95b2-14cc06f471den%40googlegroups.com.


[tw5] Generating Static Sites & Plugins

2021-08-18 Thread Louis Davout
So I'm using the render command to generate a static site. I'm also using 
some plugins that at the very least include css such as TW-Shiraz. Is there 
a best practice for getting this to work or do I need to manually modify my 
render template to include references to all the css files used and copy 
via script all those css files to my exported directory?

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/b44208bc-f08a-4388-a15a-a7a9f688301bn%40googlegroups.com.


Re: [tw5] Tiddlywiki functionality from within javascript macro

2021-08-12 Thread Louis Davout
Thanks Jeremy. I didn't know that existed.

On Thursday, August 12, 2021 at 10:52:35 AM UTC-4 jeremy...@gmail.com wrote:

> Hi Louis,
>
> I'm glad you found the answer. Just to say that GitHub Discussions can be 
> more suited for developer/JS discussions because it has better support for 
> code blocks and linking to code etc
>
> https://github.com/Jermolene/TiddlyWiki5/discussions
>
> Best wishes
>
> Jeremy.
>
> --
> Jeremy Ruston
> jer...@jermolene.com
> https://jermolene.com
>
> On 12 Aug 2021, at 10:46, Louis Davout  wrote:
>
> Is Tiddlywiki functionality, such as running filters, available from 
> within a javascript macro? I've found the code for $tw.utils and how you 
> can get access to a tiddler object via this.wiki.getTiddler(title). But I 
> haven't come across anything for using filters. Thanks.
>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "TiddlyWiki" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to tiddlywiki+...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/tiddlywiki/6c55e3b8-2648-4abf-b210-f7de7ed00c93n%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/tiddlywiki/6c55e3b8-2648-4abf-b210-f7de7ed00c93n%40googlegroups.com?utm_medium=email_source=footer>
> .
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/e4e2d734-b89c-4780-b064-827c0eaf0547n%40googlegroups.com.


[tw5] Re: Tiddlywiki functionality from within javascript macro

2021-08-12 Thread Louis Davout
Never mind, I found it. this.wiki.filterTiddlers(filter)

On Thursday, August 12, 2021 at 5:46:38 AM UTC-4 Louis Davout wrote:

> Is Tiddlywiki functionality, such as running filters, available from 
> within a javascript macro? I've found the code for $tw.utils and how you 
> can get access to a tiddler object via this.wiki.getTiddler(title). But I 
> haven't come across anything for using filters. Thanks.
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/c9cb59a8-79b5-4ff7-bae0-9623185f10c3n%40googlegroups.com.


[tw5] Tiddlywiki functionality from within javascript macro

2021-08-12 Thread Louis Davout
Is Tiddlywiki functionality, such as running filters, available from within 
a javascript macro? I've found the code for $tw.utils and how you can get 
access to a tiddler object via this.wiki.getTiddler(title). But I haven't 
come across anything for using filters. Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/6c55e3b8-2648-4abf-b210-f7de7ed00c93n%40googlegroups.com.


[tw5] Re: TW the finite state machine

2021-08-09 Thread Louis Davout

Tones,

I think we're looking at the state of different things. Let me see if I can 
articulate. If I'm understanding what you're saying, you're talking about 
the entire application including all the tiddlers as the state machine. I 
create a new tiddler in my wiki instance, the state of that wiki has 
changed. Yea that would not be finite. Sorry if I wasn't clear. 

I was referring more to the engine - the parser (and maybe other things) - 
as it process a tiddler to convert it into html. For example, a tiddler has 
a text field the parser reads that field. The TW parser is initially in 
"General wiki text" (as you describe it). The parser encounters the string 
\define, the parser recognizes this as macro definition therefore TW state 
has changed to "Macro definition" and therefore rules of what valid text 
should follow is different than if TW was still in "General wiki text.

Hopefully that clarifies things.

Thanks.
On Monday, August 9, 2021 at 5:29:51 PM UTC-4 TW Tones wrote:

> Davou,
>
> I just refreshed the concept of finite state machine 
>  and I would be 
> confident in saying tiddlywiki is not one. You may see elsewhere and 
> reasonable claim tiddlywiki is a "non-trivial quine", it can change itself 
> and save its state.
>
> This is because an  finite state machine 
> 's memory is limited 
> by the number of states it has, tiddlywiki is not, and its memory 
> limitations are in undetermined.
>
> However I suspect the reason you think this may be the case is reasonable, 
> but would argue that this mostly stems from tiddlywiki being used in the 
> browser. Along with other websites and even much earlier Mainframe 
> terminals the client server model a need to limit the effort required by 
> the server html tends to respond to a client when needed and not until 
> then. Think of a html form, it sits on your screen and the server may be 
> able to forget you exist until you hit the submit button, at which point 
> the server/host responds. Tiddlywiki however exists wholy within the 
> browser and only on saving do we need to communicate with the server/host.
>
> Tiddlywiki's update process that reflects any change throughout the whole 
> wiki, makes use of a thing call widget trees, examples such as 
> transclusions need to be resolved based on any relevant change. However 
> such could result in infinite loops but tiddlywiki is designed to avoid 
> this. Basically it works to ensure each change is processed in a finite way 
> so it returns quickly to allow the user to interact or provide more data to 
> it. 
>
> I feel that tiddlywiki is better thought of as an approximation of a 
> Turing machine that handles most freeze, fails and infinite regress 
> (although not all).
>
> Part of the complexity comes on one hand from the feature rich code and 
> services available to software in the modern browser and on the other hand 
> it can be hosted such that changes can't be saved. It could be argued a 
> read only tiddlywiki has finite states, however there are so many states it 
> can be in, it may as well be infinite.
>
> Thanks for posting such ideas.
> Tones
> On Tuesday, 10 August 2021 at 03:01:42 UTC+10 davou...@gmail.com wrote:
>
>>
>> Hello all,
>>
>> I've been casually using TW for a few months now. In the past couple 
>> weeks I have started working with the slightly more advanced features. 
>> https://groktiddlywiki.com/read/ has been very helpful, thanks Soren. 
>> One of the obstacles for me to grok TW is there appears to be a lot of 
>> conditional rules based on the current context of the parser - ex: in 
>> tiddler text vs macro call vs macro definition. This makes me visualize TW 
>> as a finite state machine. Maybe it's actually designed as such, I haven't 
>> looked at the code. Anyway, the nice explanation by PMario here 
>> just 
>> bolstered my visualization.
>>
>> I don't suppose there is documentation of TW as finite state machine. 
>> Probably not, but thought I would ask. What I mean is documentation broken 
>> down as:
>>
>>1. Here are all the possible states TW can be in
>>2. Here are the rules for when TW is in a given state
>>3. And here are the triggers that will change TW from one state to 
>>another
>>
>> Maybe there are too many states, or may different levels/granularities of 
>> states.
>>
>> The closest I found is Tones' https://anthonymuscio.github.io/It has 
>> many of the rules for a given "state".
>>
>> Thank you.
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 

[tw5] Re: Using <$list> widget to generate table rows

2021-08-09 Thread Louis Davout
Well this works:

\define davout-list(levels: "1,3,5")

LevelBlah
<$list filter="[[$levels$]split[,]]" variable="level">
<> Blah


\end
On Monday, August 9, 2021 at 9:53:34 AM UTC-4 Louis Davout wrote:

> \define davout-list(levels: "1,3,5")
> | ! Level | ! Blah |
> <$list filter="[[$levels$]split[,]]" variable="level">
>
> | <> | Blah |
>
> 
> \end 
>
> Removes the  tags but makes each row into its own table.
>
> On Monday, August 9, 2021 at 9:46:15 AM UTC-4 Louis Davout wrote:
>
>>
>> I'm trying to use the <$list> widget generate table rows. One is this 
>> even possible. Two How? Here is simplified version of code I've tried. 
>>
>> \define davout-list(levels: "1,3,5")
>> | ! Level | ! Blah |
>> <$list filter="[[$levels$]split[,]]" variable="level">
>> | <> | Blah |
>> 
>> \end
>>
>> \define davout-list2(levels: "1,3,5")
>> | ! Level | ! Blah |
>> <$list filter="[[$levels$]split[,]]" variable="level">
>> | <> | Blah |
>> <$wikify name=wikifiedRow text=| <> | Blah |>
>> <>
>> 
>> 
>> \end
>>
>> <>
>>
>> <>
>>
>> The html it generates:
>>  Level> align="center"> Blah
>> | 1 | Blah |
>>
>> | 3 | Blah |
>>
>> | 5 | Blah |
>>  Level> align="center"> Blah
>> | 1 | Blah |
>>  | Blah |
>> |
>>
>>
>> | 3 | Blah |
>>  | Blah |
>> |
>>
>>
>> | 5 | Blah |
>>  | Blah |
>> |
>>
>> 
>>
>> It's closing the table and generating  tags.
>> -
>> A more general question. It's been stated that macros are text 
>> substitution not functions that return a value. And they don't "evaluate". 
>> I've seen first hand they don't return a value, but they do seem to at 
>> least execute some code. For example they do call other macros:
>>
>> \define a()
>> <>
>> \end
>>
>> \define b(where)
>> $where$
>> \end
>>
>> <>
>>
>> produces:
>> here
>>
>> So what are the rules for what macros will and will not "execute"?
>>
>> Thanks.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/c17202a8-3ee6-47b5-a9e1-d5f4b2f04563n%40googlegroups.com.


[tw5] TW the finite state machine

2021-08-09 Thread Louis Davout

Hello all,

I've been casually using TW for a few months now. In the past couple weeks 
I have started working with the slightly more advanced features. 
https://groktiddlywiki.com/read/ has been very helpful, thanks Soren. One 
of the obstacles for me to grok TW is there appears to be a lot of 
conditional rules based on the current context of the parser - ex: in 
tiddler text vs macro call vs macro definition. This makes me visualize TW 
as a finite state machine. Maybe it's actually designed as such, I haven't 
looked at the code. Anyway, the nice explanation by PMario here 
just 
bolstered my visualization.

I don't suppose there is documentation of TW as finite state machine. 
Probably not, but thought I would ask. What I mean is documentation broken 
down as:

   1. Here are all the possible states TW can be in
   2. Here are the rules for when TW is in a given state
   3. And here are the triggers that will change TW from one state to 
   another
   
Maybe there are too many states, or may different levels/granularities of 
states.

The closest I found is Tones' https://anthonymuscio.github.io/It has many 
of the rules for a given "state".

Thank you.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/c9f59c64-c126-4a0b-9ced-7ea7c4fe6fcfn%40googlegroups.com.


[tw5] Re: Inconsistency is so frustrating

2021-08-09 Thread Louis Davout
PMario,

Thanks for this explanation. It was very helpful.

On Sunday, July 11, 2021 at 10:06:08 AM UTC-4 PMario wrote:

> Hi David, 
>
> I hope you feel better now ;)
>
> So the only thing I can do here is : Try to explain how the parser 
> algorithm works, so that you can see, why it behaves the way as it does. 
>
> ===
>
> The tiddlywiki parser knows 2 types of rules
>
>  - block rules   and
>  - inline rules
>
> For the whole tiddler content it always starts with "block mode" and 
> starts to "scan" for "block rules". If a block is found it switches to 
> "inline mode" and starts to look for "inline rules". ... I call this the 
> "context" here in the post.
>
> Here comes some ''bold'' text.  
>
> It detects the whole text as a paragraph "block" ... which will be 
> rendered like this: ->   Here comes some *bold* text 
>
> As HTML code it looks like this:  Here comes some 
> bold text. 
>
> The P element defines the "block"
> The ''bold'' wikitext is an *inline-rule* per definition.
>
> That make sense. right?
>
> --
>
> So the question now is, how does the parser detect different blocks of 
> text,  to create paragraph tags around them. ... We all know this rule: 2 
> NewLines .. will split 2 text elements into separated paragraphs. 
>
> eg: 
>
> paragraph 1
>
> paragraph 2
>
> That makes sense. right?
> -
>
> text 1
> text 2
>
> Doesn't contain 2 new-lines but 1 ... It's inline mode and it will be 
> translated to the following HTML code
>
> text 1
> text 2
>
> You can see the new-line is still there BUT HTML ignores whitespace per 
> specification. ... So the browser shows the text like this
>
> text 1text 2
>
> So it's not a TW problem, it's the browser that follows the rules. ... 
> TiddlyWiki has a wikitext rule to compensate this problem 
> . 
> Hard-Linebreaks
>
> """
> text 1
> text 2 
> """
>
> Which creates this: text 1text 2 which tells the browser 
> to add line-breaks.  
>
> A second method to achieve a similar result is Hard linebreaks with CSS 
> .
>   
> Which works well for wikitext. It may cause problems with macros and 
> widgets.
>
> 
>
> You may say: BUT the following macros only have 1 new-line between them. 
>
> <>
> <>
>
> I say: Yes, you are right. ... But *macros *and *transclusions *have to 
> be able to inherit the mode from their context. ... eg: 
>
> \define bold(text) ''$text$''
>
> Here comes some <> text. 
>
> The parser starts at line 1 character 1 and detects some text. The "end 
> marker" for text blocks is  2 new-lines
> After the block of text is detected, it switches to *inline-mode*. 
>
> It detects the macro within this context, so the macro is rendered in 
> inline mode.
>
> The text is translated to the following HTML code: Here comes some 
> bold text. 
>
> That's what we expect. Right?  
>
> --
>
> As written above macros and transclusions do inherit the mode from their 
> context. 
>
> Back to your example: Let's have a look at the "context" here. ... 
>
> \define macrocall() aaa
> \define macrocall2() bbb
>
> <>
> <>
>
> The context is the whole tiddler body, which starts as block mode. 
> Then the parser detects the start << and the end >> of a macro in line 1. 
> ... There is no other info
> The mode is still block mode, that's why the macro is rendered in block 
> mode like this: aaa
> The parser detects macro start / end in line 2, which will be rendered 
> like this: bbb   
>
> That may not be, what you expected, but the behaviour is consistent. 
> Humans may see the 2 macros as 1 block. ... The wiki parser does not. 
>
> Try this a)
>
>  - <>
> <>
>
> and this b)
>
>  - <>
>
> <>
>
> 
>
> add a) You can see that it detects some text in front of macro 1. So macro 
> 1 and macro 2 will be part of the text block and will be rendered in 
> inline-mode
> HTML output
>
>  - aaa
> bbb
>  
>
>
>
> add b) Now the  text and macro 1 belong together and macro 2 gets it's 
> own block. 
> HTML output
>
>  - aaabbb 
>
> 
>
> If you compare the HTML output with my descriptions, you will see the 
> algorithm is consistent. ... BUT it may not always be what we expect. 
>
> I hope my descriptions are good enough to show how the "block" and 
> "inline" detection works.  
>
> have fun!
> mario
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/905b7ed9-3998-4a35-bf22-5c4ea63fb0c9n%40googlegroups.com.


[tw5] Re: Shiraz Plugin: Lets use Tiddlywiki with More Ease

2021-08-09 Thread Louis Davout
If I order now, will you send me a second one absolutely free?

On Monday, August 9, 2021 at 9:14:37 AM UTC-4 ludwa6 wrote:

> W00t!  For a late-night infomercial junkie like me, this is like the 
> famous Ginsu knife offer  (as 
> you were wondering 
> , 
> @PMario :-)  -totally irresistible.  Can't wait to try it!
>
> /walt
>
> On Sunday, August 8, 2021 at 5:51:30 PM UTC+1 cj.v...@gmail.com wrote:
>
>> That is a pretty fantastic teaser !
>>
>> On Sunday, August 8, 2021 at 1:38:00 PM UTC-3 Mohammad wrote:
>>
>>>
>>>- Do you like to convert your old static/plain table in a tiddler 
>>>into a sortable table just by calling a macro  (no edit, no hassles,  
>>> ...)
>>>- Do you like to drop a CSV text file into tiddlywiki and in a 
>>>second generate a dynamic table?
>>>- Do you like to copy paste part of a worksheet from Excel, Google 
>>>Sheet, Libre Office Calc, ... into a tiddler and TW generate a nice 
>>>sortable table for you?
>>>- Do you like to create tables from plain texts just by calling a 
>>>simple macro?
>>>- Do you like to create task lists from plain text (just like 
>>>GitHub)?
>>>- Write you tasks/todo as you write on a piece of paper and then get 
>>>a task list! Do you like this?
>>>
>>>
>>> *Sit back, relax, and let Shiraz do all the work  ;-)*
>>>
>>>
>>> Stay tuned, Shiraz on *Tiddlywiki 5.0.2* is coming!
>>>
>>> Best wishes
>>> Mohammad
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/c48073ea-a70b-4963-be7e-0d75bcf3bd99n%40googlegroups.com.


[tw5] Re: Using <$list> widget to generate table rows

2021-08-09 Thread Louis Davout
 \define davout-list(levels: "1,3,5")
| ! Level | ! Blah |
<$list filter="[[$levels$]split[,]]" variable="level">

| <> | Blah |


\end 

Removes the  tags but makes each row into its own table.

On Monday, August 9, 2021 at 9:46:15 AM UTC-4 Louis Davout wrote:

>
> I'm trying to use the <$list> widget generate table rows. One is this even 
> possible. Two How? Here is simplified version of code I've tried. 
>
> \define davout-list(levels: "1,3,5")
> | ! Level | ! Blah |
> <$list filter="[[$levels$]split[,]]" variable="level">
> | <> | Blah |
> 
> \end
>
> \define davout-list2(levels: "1,3,5")
> | ! Level | ! Blah |
> <$list filter="[[$levels$]split[,]]" variable="level">
> | <> | Blah |
> <$wikify name=wikifiedRow text=| <> | Blah |>
> <>
> 
> 
> \end
>
> <>
>
> <>
>
> The html it generates:
>  Level align="center"> Blah
> | 1 | Blah |
>
> | 3 | Blah |
>
> | 5 | Blah |
>  Level align="center"> Blah
> | 1 | Blah |
>  | Blah |
> |
>
>
> | 3 | Blah |
>  | Blah |
> |
>
>
> | 5 | Blah |
>  | Blah |
> |
>
> 
>
> It's closing the table and generating  tags.
> -
> A more general question. It's been stated that macros are text 
> substitution not functions that return a value. And they don't "evaluate". 
> I've seen first hand they don't return a value, but they do seem to at 
> least execute some code. For example they do call other macros:
>
> \define a()
> <>
> \end
>
> \define b(where)
> $where$
> \end
>
> <>
>
> produces:
> here
>
> So what are the rules for what macros will and will not "execute"?
>
> Thanks.
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/c9984423-1291-43d6-80e7-d5c977ecf4d9n%40googlegroups.com.


[tw5] Using <$list> widget to generate table rows

2021-08-09 Thread Louis Davout

I'm trying to use the <$list> widget generate table rows. One is this even 
possible. Two How? Here is simplified version of code I've tried. 

\define davout-list(levels: "1,3,5")
| ! Level | ! Blah |
<$list filter="[[$levels$]split[,]]" variable="level">
| <> | Blah |

\end

\define davout-list2(levels: "1,3,5")
| ! Level | ! Blah |
<$list filter="[[$levels$]split[,]]" variable="level">
| <> | Blah |
<$wikify name=wikifiedRow text=| <> | Blah |>
<>


\end

<>

<>

The html it generates:
 Level Blah
| 1 | Blah |

| 3 | Blah |

| 5 | Blah |
 Level Blah
| 1 | Blah |
 | Blah |
|


| 3 | Blah |
 | Blah |
|


| 5 | Blah |
 | Blah |
|



It's closing the table and generating  tags.
-
A more general question. It's been stated that macros are text substitution 
not functions that return a value. And they don't "evaluate". I've seen 
first hand they don't return a value, but they do seem to at least execute 
some code. For example they do call other macros:

\define a()
<>
\end

\define b(where)
$where$
\end

<>

produces:
here

So what are the rules for what macros will and will not "execute"?

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/5d782dff-9120-4b5c-bd45-2b0353c9abafn%40googlegroups.com.


Re: [tw5] Export to html while excluding some transclusions

2021-07-20 Thread Louis Davout
 Jeremy offered a solution that works as advertised - thank you Jeremy. 
Unfortunately there a 2 pain points with this method and was wondering if 
there are solutions for those. 

1. Over time I want to make some private tiddlers public. Is there 
currently a means to easily move a tiddler from one wiki to another (in my 
case both run under node on same machine)? If not, could I create a plugin 
to do so? What is the basic algorithm or basic things to keep in mind? Is 
it simply a matter of moving the tiddler file from one directory to another?

2. In order to see any changes made in a tiddler in the public wiki it 
appears I need to restart the private wiki and refresh the browser if 
browser is viewing the private wiki. If this is the case, is there a way to 
at least remotely restart server? In my case, I interact via browser with 
my wikis from one machine while the wikis run on another machine. Both are 
behind a firewall and I don't expose either of my wikis to the public. So 
I'm not too concerned about someone externally restarting my wikis. I could 
remote desktop, but for reasons, if an alternative exists I'd like to know. 
I know first-world problems but if this ability already exists, I'd like to 
take advantage of it.

A completely different alternative solution occurred to me: create a custom 
command like render but one which doesn't transclude if tiddler to 
transclude is not public. But looking at the code, I'm not sure I want to 
go down that rabbit hole.

Thanks.
On Monday, May 3, 2021 at 12:55:10 PM UTC-4 jeremy...@gmail.com wrote:

> Hi Louis
>
> If you're running under Node.js, you could setup two separate wiki 
> folders, one "private" and one "public". Then the private wiki can use the 
> "includeWiki" property to include the tiddlers from the public wiki. When 
> exporting the public content, you'd reference the public wiki, thus 
> excluding all the private content.
>
> Best wishes
>
> Jeremy
> 
>
> Hi, 
>
> I'm wondering if the following is possible either in the base wiki or with 
> a plugin.
>
> Say I have a tag 'Public'. I want to export all tiddlers and only those 
> tiddlers with the tag 'Public'. Simple enough with filter [tag[Public]]. 
> But say some of the 'Public' tiddlers have 
> transclusions of tiddlers that do not have the 'Public' tag. In my html 
> output I don't want the content of the transclusions included unless 
> transclused tiddler also has the 'Public' tag.
>
> Thanks
>
> Example
> *topic1 with tag Public*
> start
>
> {{topic2}}
>
> {{topic3}}
>
> end
>
> *topic2 without tag Public*
> private
>
> *topic3 with tag Public*
> show me
>
> *the desired html output*
> start
>
> show me 
>
> end
>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "TiddlyWiki" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to tiddlywiki+...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/tiddlywiki/0ddc64cc-58f3-497c-a514-d4d39292b1b9n%40googlegroups.com
>  
> 
> .
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/baa41e5c-32b4-4e2c-a25c-f695586b6180n%40googlegroups.com.


[tw5] How to install plugins on TW node?

2021-07-13 Thread Louis Davout

I'm running TW 5.1.23 on node js and I want to install JD's Plain Revisions 
(http://j.d.revisions.tiddlyspot.com/). I've installed plugins that provide 
complete source like 
kookma's commander. Unfortunately JD only provides the drag and drop 
version. How do I properly install it on node for all my TW instances?

Thanks.


-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/c9c38c2f-0928-4a6a-a6c1-1a59a7081597n%40googlegroups.com.


[tw5] Re: RenderCommand: internal links incorrect

2021-05-30 Thread Louis Davout
Should anyone in the future come across this. Apparently you can use the 
RenderCommand to generate static html which have working internal links 
using using render-type of text/plain and 
$:/core/templates/static.tiddler.html (I don't know if it works with any 
other template.)

tiddlywiki --render [!is[system]] 
"[encodeuricomponent[]addprefix[tiddlers/]addsuffix[.html]]" text/plain 
"$:/core/templates/static.tiddler.html"

On Sunday, May 30, 2021 at 9:23:37 AM UTC-4 Louis Davout wrote:

> OK I got the links to work by following 
> https://www.didaxy.com/exporting-static-sites-from-tiddlywiki-part-1 and 
> using the deprecated RenderTiddlersCommand not sure yet if it's because 
> of the parameters or the command itself. Looking further into it.
>
>
> On Saturday, May 29, 2021 at 10:25:36 AM UTC-4 Louis Davout wrote:
>
>>
>> I have TW 5.1.23 running on node. I'm exporting to static html using the 
>> RenderCommand:
>>
>> tiddlywiki --render [!is[system]] "[encodeuricomponent[]addsuffix[.html]]"
>>
>> The internal links generated still have the # like an achor tag. Ex:
>>
>> In topicA I have a link to topicB ([[topicB]] the html generated for 
>> topicA has 
>>
>> topicB
>>
>> How can I get the links to point to the files?
>>
>> > href="#topicB.html">topicB
>>
>> Thanks.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/3dcbe94a-d523-4a0c-b24c-01588b24c1b4n%40googlegroups.com.


[tw5] Re: RenderCommand: internal links incorrect

2021-05-30 Thread Louis Davout
OK I got the links to work by following 
https://www.didaxy.com/exporting-static-sites-from-tiddlywiki-part-1 and 
using the deprecated RenderTiddlersCommand not sure yet if it's because of 
the parameters or the command itself. Looking further into it.


On Saturday, May 29, 2021 at 10:25:36 AM UTC-4 Louis Davout wrote:

>
> I have TW 5.1.23 running on node. I'm exporting to static html using the 
> RenderCommand:
>
> tiddlywiki --render [!is[system]] "[encodeuricomponent[]addsuffix[.html]]"
>
> The internal links generated still have the # like an achor tag. Ex:
>
> In topicA I have a link to topicB ([[topicB]] the html generated for 
> topicA has 
>
> topicB
>
> How can I get the links to point to the files?
>
>  href="#topicB.html">topicB
>
> Thanks.
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/250da767-4eab-4396-85d4-ccd315dadfdcn%40googlegroups.com.


[tw5] Re: RenderCommand: internal links incorrect

2021-05-30 Thread Louis Davout
OK I got the links to work by following 
https://www.didaxy.com/exporting-static-sites-from-tiddlywiki-part-1 and 
using the deprecated RenderTiddlerCommand not sure yet if it's because of 
the parameters or the command itself. Looking further into it.

On Saturday, May 29, 2021 at 10:25:36 AM UTC-4 Louis Davout wrote:

>
> I have TW 5.1.23 running on node. I'm exporting to static html using the 
> RenderCommand:
>
> tiddlywiki --render [!is[system]] "[encodeuricomponent[]addsuffix[.html]]"
>
> The internal links generated still have the # like an achor tag. Ex:
>
> In topicA I have a link to topicB ([[topicB]] the html generated for 
> topicA has 
>
> topicB
>
> How can I get the links to point to the files?
>
>  href="#topicB.html">topicB
>
> Thanks.
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/4b93f514-1563-4492-b98c-3e0b6175c089n%40googlegroups.com.


[tw5] RenderCommand: internal links incorrect

2021-05-29 Thread Louis Davout

I have TW 5.1.23 running on node. I'm exporting to static html using the 
RenderCommand:

tiddlywiki --render [!is[system]] "[encodeuricomponent[]addsuffix[.html]]"

The internal links generated still have the # like an achor tag. Ex:

In topicA I have a link to topicB ([[topicB]] the html generated for topicA 
has 

topicB

How can I get the links to point to the files?

topicB

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/d94cedda-9672-4db5-b523-2547ad2b5872n%40googlegroups.com.


Re: [tw5] Re: Formatting link alias

2021-05-16 Thread Louis Davout
Thanks!

On Sat, May 15, 2021 at 11:39 PM Eric Shulman  wrote:

> On Saturday, May 15, 2021 at 8:02:20 PM UTC-7 davou...@gmail.com wrote:
>
>> [[Alias^^1^^|Topic]] will format the 1 to superscript... Is there a way
>> to format a link alias in TW5?
>>
>
> Use the <$link> widget, like this:
> <$link to="Topic">Alias^^1^^
>
> enjoy,
> -e
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "TiddlyWiki" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/tiddlywiki/VRo55yyUkC0/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> tiddlywiki+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/tiddlywiki/f311988b-1426-44a1-8a55-eedd27fbc18an%40googlegroups.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/CAFnuQtRCqjFUSf1QbZGbZGwMmXR52G1-HQFkDhqe_U%2BMbAok1Q%40mail.gmail.com.


[tw5] Formatting link alias

2021-05-15 Thread Louis Davout

I'm looking to migrate my ConnectedText wikis to TW5. With CT I can have at 
least some formatting in a link alias. So [[Alias^^1^^|Topic]] will format 
the 1 to superscript. TW5 displays the literal ^^1^^. Workaround is 
[[Alias|Topic]]^^1^^.

Is there a way to format a link alias in TW5? Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/6eac6809-8fff-4425-bf1c-dd18883c2760n%40googlegroups.com.


[tw5] Export to html while excluding some transclusions

2021-05-03 Thread Louis Davout

Hi, 

I'm wondering if the following is possible either in the base wiki or with 
a plugin.

Say I have a tag 'Public'. I want to export all tiddlers and only those 
tiddlers with the tag 'Public'. Simple enough with filter [tag[Public]]. 
But say some of the 'Public' tiddlers have 
transclusions of tiddlers that do not have the 'Public' tag. In my html 
output I don't want the content of the transclusions included unless 
transclused tiddler also has the 'Public' tag.

Thanks

Example
*topic1 with tag Public*
start

{{topic2}}

{{topic3}}

end

*topic2 without tag Public*
private

*topic3 with tag Public*
show me

*the desired html output*
start

show me 

end

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/0ddc64cc-58f3-497c-a514-d4d39292b1b9n%40googlegroups.com.