Re: [tw5] Is there a way to create a tiddler using text that is stored in the clipboard?

2020-12-11 Thread Mohammad
Hi Saq,
 Great tip. I will submit a ticket.

Cheers
Mohammad

On Saturday, December 12, 2020 at 10:44:10 AM UTC+3:30 saq.i...@gmail.com 
wrote:

> @springer So the dropzone widget which handles the import/paste/drag 
> actually lets you specify how to interpret the incoming text.
>
> So theoretically something like this should work:
>
> <$dropzone deserializer="application/x-bibtex">
>
> paste/drag bibtex here
>
>
> 
>
> However, it turns out that the deserializer attribute is only honoured for 
> files that are imported and not for text. This is worth creating an issue 
> for on github, I think we can do better.
>
> Saq
> On Saturday, December 12, 2020 at 1:45:33 AM UTC+1 springer wrote:
>
>> I just discovered this thread, while trying to understand related issues.
>>
>> My workflow includes, for example, coming a cross a citation in google 
>> scholar, which I can display in bibtex format like so: 
>>
>> @book{crary2016inside, 
>> title={Inside ethics}, 
>> author={Crary, Alice}, 
>> year={2016}, 
>>publisher={Harvard University Press} 
>> }
>>
>> I was hoping that dragging that text into Tiddlywiki would auto-populate 
>> the fields. Instead, I get an ordinary tiddler with a text field that looks 
>> exactly like the above block.
>>
>> What works: issuing a terminal command like pbpaste > crary.bib
>>  ... which yields a .bib file ... which I can then drag into tw5 (for 
>> import and recognition via bibtex plugin), but this is terribly roundabout.
>>
>> Why not be able to drag and drop the contents of a field-parsable string 
>> (onto a special bibtex or json drop area if need be) and have tiddlywiki 
>> parse directly, populating fields if field patterns are present?
>>
>> (Sorry that this question is framed with bibtex records in mind; but 
>> presumably the issues are similar for any json-formatted strings on the 
>> clipboard?)
>>
>> -Springer
>> On Tuesday, November 10, 2020 at 7:58:27 PM UTC-5 TW Tones wrote:
>>
>>> David,
>>>
>>> In a similar vein for creating tiddlers from found text the OT and your 
>>> desire for "loaded" new tiddlers, One idea I had was to create a tab in the 
>>> side bar with a drop zone. Text dropped there would be imported silently 
>>> and create a tiddler according to a set of standards and fields etc. A 
>>> Second tab dropzone, could import the text another way. This method would 
>>> do well to have the below templates idea.
>>>
>>>- David's point 1. Use the viewTemplate for untitled tiddlers and 
>>>add this feature there (as in my last post)
>>>
>>> Templates idea
>>>
>>> TiddlyWiki is repeat with the concept of templates, as a result, I think 
>>> perhaps we have somewhat neglected the use of tiddler templates for 
>>> creating tiddlers. This should have a core representation so extra bespoke 
>>> work is not required for such a fundamental function. 
>>>
>>> I have developed a number of methods that can help meet the ideas in 
>>> your other points, The key is however having defined some template tiddlers 
>>> that are used to create different kinds of tiddlers. Such templates can 
>>> have what ever fields and values you want and one trick is to also include 
>>> fields for example with an underscore name eg: _tags value" "tagname1 
>>> tagname2", underscore fields are used to populate the no underscore field 
>>> of the same name eg: tags value" "tagname1 tagname2" when creating the new 
>>> tiddler from the template.
>>>
>>> Fields can only contain lowercase letters, digits and the characters 
>>> underscore (_), hyphen (-) and period (.) this this are the three 
>>> punctuation prefixes available.
>>> So I suggest;
>>>
>>>- _fieldname results a in fieldname being created with the value in 
>>>_fieldname used (if any).
>>>   - One special case would be _source-template which is recorded in 
>>>   the new tiddler
>>>   - another _object-name eg "task" when the template is used to 
>>>   create a task
>>>- .fieldname If the current tiddler has fieldname use the "current 
>>>tiddlers fieldname" to set the value "a context field"
>>>- -fieldname could potentially use a macro or transclusion of a 
>>>similar name as fieldname to populate the new field.
>>>- All other fields are cloned into the new tiddler.
>>>
>>>
>>>
>>>
>>>
>>> On Wednesday, 11 November 2020 00:19:54 UTC+11, David Gifford wrote:

 I decided to delete and rewrite my post since it was somewhat 
 incomprehensible:

 I have an idea that if implemented in TiddlyWiki, would solve si's 
 problem, and would also solve a problem of my own: my problem is that 
 sometimes I want any tiddler generated by creating a wikilink then 
 clicking 
 on the link, to have certain fields and data.

 My idea is this:

 1. Have a separate tab in the control panel with the "Title for new 
 tiddlers" and "Tags for new tiddlers"from the basics tab, but with a new 
 element: "Fields for new tiddler

Re: [tw5] Is there a way to create a tiddler using text that is stored in the clipboard?

2020-12-11 Thread Mohammad
Hi Springer,
 I use the multiple citation export from Google Scholar see:
   https://uri.libguides.com/google/gscholexport
  After I finished I download the text file and save as .bib and then drag 
and drop into my Tiddlywiki with BibtexImporter plugin installed.

--Mohammad


On Saturday, December 12, 2020 at 4:15:33 AM UTC+3:30 springer wrote:

> I just discovered this thread, while trying to understand related issues.
>
> My workflow includes, for example, coming a cross a citation in google 
> scholar, which I can display in bibtex format like so: 
>
> @book{crary2016inside, 
> title={Inside ethics}, 
> author={Crary, Alice}, 
> year={2016}, 
>publisher={Harvard University Press} 
> }
>
> I was hoping that dragging that text into Tiddlywiki would auto-populate 
> the fields. Instead, I get an ordinary tiddler with a text field that looks 
> exactly like the above block.
>
> What works: issuing a terminal command like pbpaste > crary.bib
>  ... which yields a .bib file ... which I can then drag into tw5 (for 
> import and recognition via bibtex plugin), but this is terribly roundabout.
>
> Why not be able to drag and drop the contents of a field-parsable string 
> (onto a special bibtex or json drop area if need be) and have tiddlywiki 
> parse directly, populating fields if field patterns are present?
>
> (Sorry that this question is framed with bibtex records in mind; but 
> presumably the issues are similar for any json-formatted strings on the 
> clipboard?)
>
> -Springer
> On Tuesday, November 10, 2020 at 7:58:27 PM UTC-5 TW Tones wrote:
>
>> David,
>>
>> In a similar vein for creating tiddlers from found text the OT and your 
>> desire for "loaded" new tiddlers, One idea I had was to create a tab in the 
>> side bar with a drop zone. Text dropped there would be imported silently 
>> and create a tiddler according to a set of standards and fields etc. A 
>> Second tab dropzone, could import the text another way. This method would 
>> do well to have the below templates idea.
>>
>>- David's point 1. Use the viewTemplate for untitled tiddlers and add 
>>this feature there (as in my last post)
>>
>> Templates idea
>>
>> TiddlyWiki is repeat with the concept of templates, as a result, I think 
>> perhaps we have somewhat neglected the use of tiddler templates for 
>> creating tiddlers. This should have a core representation so extra bespoke 
>> work is not required for such a fundamental function. 
>>
>> I have developed a number of methods that can help meet the ideas in your 
>> other points, The key is however having defined some template tiddlers that 
>> are used to create different kinds of tiddlers. Such templates can have 
>> what ever fields and values you want and one trick is to also include 
>> fields for example with an underscore name eg: _tags value" "tagname1 
>> tagname2", underscore fields are used to populate the no underscore field 
>> of the same name eg: tags value" "tagname1 tagname2" when creating the new 
>> tiddler from the template.
>>
>> Fields can only contain lowercase letters, digits and the characters 
>> underscore (_), hyphen (-) and period (.) this this are the three 
>> punctuation prefixes available.
>> So I suggest;
>>
>>- _fieldname results a in fieldname being created with the value in 
>>_fieldname used (if any).
>>   - One special case would be _source-template which is recorded in 
>>   the new tiddler
>>   - another _object-name eg "task" when the template is used to 
>>   create a task
>>- .fieldname If the current tiddler has fieldname use the "current 
>>tiddlers fieldname" to set the value "a context field"
>>- -fieldname could potentially use a macro or transclusion of a 
>>similar name as fieldname to populate the new field.
>>- All other fields are cloned into the new tiddler.
>>
>>
>>
>>
>>
>> On Wednesday, 11 November 2020 00:19:54 UTC+11, David Gifford wrote:
>>>
>>> I decided to delete and rewrite my post since it was somewhat 
>>> incomprehensible:
>>>
>>> I have an idea that if implemented in TiddlyWiki, would solve si's 
>>> problem, and would also solve a problem of my own: my problem is that 
>>> sometimes I want any tiddler generated by creating a wikilink then clicking 
>>> on the link, to have certain fields and data.
>>>
>>> My idea is this:
>>>
>>> 1. Have a separate tab in the control panel with the "Title for new 
>>> tiddlers" and "Tags for new tiddlers"from the basics tab, but with a new 
>>> element: "Fields for new tiddlers", which could look just like it does at 
>>> the bottom of edit mode in all tiddlers. That way, si could set the fields 
>>> (and add text to them if desired) so that when he pastes the text, the 
>>> tiddler generated would have the fields and data added. Let's call this tab 
>>> $:/core/ui/ControlPanel/NewTiddlerConfig 
>>>
>>> 2. The other aspect of my idea is that 
>>> $:/core/ui/ControlPanel/NewTiddlerConfig could be tagged, say, 
>>> $:/ta

Re: [tw5] Is there a way to create a tiddler using text that is stored in the clipboard?

2020-12-11 Thread Saq Imtiaz
@springer So the dropzone widget which handles the import/paste/drag 
actually lets you specify how to interpret the incoming text.

So theoretically something like this should work:

<$dropzone deserializer="application/x-bibtex">

paste/drag bibtex here




However, it turns out that the deserializer attribute is only honoured for 
files that are imported and not for text. This is worth creating an issue 
for on github, I think we can do better.

Saq
On Saturday, December 12, 2020 at 1:45:33 AM UTC+1 springer wrote:

> I just discovered this thread, while trying to understand related issues.
>
> My workflow includes, for example, coming a cross a citation in google 
> scholar, which I can display in bibtex format like so: 
>
> @book{crary2016inside, 
> title={Inside ethics}, 
> author={Crary, Alice}, 
> year={2016}, 
>publisher={Harvard University Press} 
> }
>
> I was hoping that dragging that text into Tiddlywiki would auto-populate 
> the fields. Instead, I get an ordinary tiddler with a text field that looks 
> exactly like the above block.
>
> What works: issuing a terminal command like pbpaste > crary.bib
>  ... which yields a .bib file ... which I can then drag into tw5 (for 
> import and recognition via bibtex plugin), but this is terribly roundabout.
>
> Why not be able to drag and drop the contents of a field-parsable string 
> (onto a special bibtex or json drop area if need be) and have tiddlywiki 
> parse directly, populating fields if field patterns are present?
>
> (Sorry that this question is framed with bibtex records in mind; but 
> presumably the issues are similar for any json-formatted strings on the 
> clipboard?)
>
> -Springer
> On Tuesday, November 10, 2020 at 7:58:27 PM UTC-5 TW Tones wrote:
>
>> David,
>>
>> In a similar vein for creating tiddlers from found text the OT and your 
>> desire for "loaded" new tiddlers, One idea I had was to create a tab in the 
>> side bar with a drop zone. Text dropped there would be imported silently 
>> and create a tiddler according to a set of standards and fields etc. A 
>> Second tab dropzone, could import the text another way. This method would 
>> do well to have the below templates idea.
>>
>>- David's point 1. Use the viewTemplate for untitled tiddlers and add 
>>this feature there (as in my last post)
>>
>> Templates idea
>>
>> TiddlyWiki is repeat with the concept of templates, as a result, I think 
>> perhaps we have somewhat neglected the use of tiddler templates for 
>> creating tiddlers. This should have a core representation so extra bespoke 
>> work is not required for such a fundamental function. 
>>
>> I have developed a number of methods that can help meet the ideas in your 
>> other points, The key is however having defined some template tiddlers that 
>> are used to create different kinds of tiddlers. Such templates can have 
>> what ever fields and values you want and one trick is to also include 
>> fields for example with an underscore name eg: _tags value" "tagname1 
>> tagname2", underscore fields are used to populate the no underscore field 
>> of the same name eg: tags value" "tagname1 tagname2" when creating the new 
>> tiddler from the template.
>>
>> Fields can only contain lowercase letters, digits and the characters 
>> underscore (_), hyphen (-) and period (.) this this are the three 
>> punctuation prefixes available.
>> So I suggest;
>>
>>- _fieldname results a in fieldname being created with the value in 
>>_fieldname used (if any).
>>   - One special case would be _source-template which is recorded in 
>>   the new tiddler
>>   - another _object-name eg "task" when the template is used to 
>>   create a task
>>- .fieldname If the current tiddler has fieldname use the "current 
>>tiddlers fieldname" to set the value "a context field"
>>- -fieldname could potentially use a macro or transclusion of a 
>>similar name as fieldname to populate the new field.
>>- All other fields are cloned into the new tiddler.
>>
>>
>>
>>
>>
>> On Wednesday, 11 November 2020 00:19:54 UTC+11, David Gifford wrote:
>>>
>>> I decided to delete and rewrite my post since it was somewhat 
>>> incomprehensible:
>>>
>>> I have an idea that if implemented in TiddlyWiki, would solve si's 
>>> problem, and would also solve a problem of my own: my problem is that 
>>> sometimes I want any tiddler generated by creating a wikilink then clicking 
>>> on the link, to have certain fields and data.
>>>
>>> My idea is this:
>>>
>>> 1. Have a separate tab in the control panel with the "Title for new 
>>> tiddlers" and "Tags for new tiddlers"from the basics tab, but with a new 
>>> element: "Fields for new tiddlers", which could look just like it does at 
>>> the bottom of edit mode in all tiddlers. That way, si could set the fields 
>>> (and add text to them if desired) so that when he pastes the text, the 
>>> tiddler generated would have the fields and data added. Let's call this t

[tw5] Re: Horizontal arrangement?

2020-12-11 Thread strikke...@gmail.com
I have only tried out Beaker browser with tiddlywiki for a couple of days 
now. Normally I am using Firefox. That lead to me dragging the plugin from 
a tab in firefox to the Beaker tab with my new tiddlywiki. It seem to work 
okay. I think it should be possible to export the plugin from the 
tiddlywiki and then import into your wiki.
I have been wondering how many in this group is using Beaker with 
tiddlywiki now, it sure is interesting.

Birthe

On Saturday, December 12, 2020 at 6:23:22 AM UTC+1 Krish wrote:

> Yay...thank you! This is what I was looking for.  Funny, I got triggered 
> by Andy's notes too :-) I am using beaker browser to do Tiddly.  What is 
> the best way to install this plugin in that case?  Same as explained in the 
> link you mentioned?
>
> On Friday, December 11, 2020 at 6:24:27 PM UTC-8 strikke...@gmail.com 
> wrote:
>
>>
>> Welcome Krish.
>>
>> Maybe something like https://crazko.github.io/krystal/
>> On Saturday, December 12, 2020 at 1:01:49 AM UTC+1 Krish wrote:
>>
>>> Newbie here.  Sorry if this question has been asked. Can Tiddlers be 
>>> arranged not only vertically but also horizontally?  As you click on a 
>>> particular tiddler, it opens a child tiddler on a side horizontal pane.  If 
>>> that can be done, this would be an amazing structure.
>>
>>

-- 
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/f1a821a9-e71d-4815-9262-01f0b1afb73cn%40googlegroups.com.


Re: [tw5] Is there a way to create a tiddler using text that is stored in the clipboard?

2020-12-11 Thread 'Mark S.' via TiddlyWiki
If you edit the import tiddler, you'll see it's actually a JSON structure.

So you could possibly use the JsonMangler 
 plugin in conjunction with your 
own "import" button that would fetch all the values, add your own fields, 
and create the tiddler. This way you could perform a batch process after 
you've done a series of import pastes.


On Tuesday, November 10, 2020 at 3:08:24 AM UTC-8 si wrote:

> Hi Jeremy thanks for the response. I was specifically hoping to be able to 
> do it with something like $action-createtiddler so that I could 
> auto-populate the new tiddler with whatever fields and tags I need.
>
> My specific use case is that when I'm reading a PDF I usually create a 
> tiddler to represent the book. All my book tiddlers have a button for 
> creating a tiddler to store quotes from the book, tagged with the book + 
> metadata fields. Currently I just copy the text in manually, which is fine, 
> I just wondered if there was a way I could speed up this process and have 
> it all happen with one button press.
>
> On Tuesday, 10 November 2020 07:33:51 UTC, Jeremy Ruston wrote:
>
>> On a device with a keyboard you can click on TiddlyWiki's page background 
>> and then use the keyboard shortcut for "paste". The $:/Import dialogue 
>> should open with the pasted item as a tiddler.
>>
>> Best wishes
>>
>> Jeremy.
>>
>> --
>> Jeremy Ruston
>> jer...@jermolene.com
>> https://jermolene.com
>>
>> On 9 Nov 2020, at 21:17, si  wrote:
>>
>> 
>> Say you have copied a paragraph of text and it is stored in your 
>> clipboard.
>>
>> Is there a way to create a button in TiddlyWiki that will create a new 
>> tiddler whose "text" field is populated with whatever was stored in your 
>> clipboard?
>>
>> I'm not expecting the answer to be yes but I thought I'd ask just in 
>> case. Thanks in advance for your help.
>>
>> -- 
>> 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 tiddl...@googlegroups.com.
>>
>>
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/tiddlywiki/faf491ec-7c6c-45cb-9fe1-3c926f412c6do%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/f778fdd4-6217-4d12-a0e6-8a77dd3e0011n%40googlegroups.com.


[tw5] Re: Horizontal arrangement?

2020-12-11 Thread Krish
Yay...thank you! This is what I was looking for.  Funny, I got triggered by 
Andy's notes too :-) I am using beaker browser to do Tiddly.  What is the 
best way to install this plugin in that case?  Same as explained in the 
link you mentioned?

On Friday, December 11, 2020 at 6:24:27 PM UTC-8 strikke...@gmail.com wrote:

>
> Welcome Krish.
>
> Maybe something like https://crazko.github.io/krystal/
> On Saturday, December 12, 2020 at 1:01:49 AM UTC+1 Krish wrote:
>
>> Newbie here.  Sorry if this question has been asked. Can Tiddlers be 
>> arranged not only vertically but also horizontally?  As you click on a 
>> particular tiddler, it opens a child tiddler on a side horizontal pane.  If 
>> that can be done, this would be an amazing structure.
>
>

-- 
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/d1fc9249-d839-4123-a33d-99d3ec9d349an%40googlegroups.com.


[tw5] Re: Horizontal arrangement?

2020-12-11 Thread strikke...@gmail.com

Welcome Krish.

Maybe something like https://crazko.github.io/krystal/
On Saturday, December 12, 2020 at 1:01:49 AM UTC+1 Krish wrote:

> Newbie here.  Sorry if this question has been asked. Can Tiddlers be 
> arranged not only vertically but also horizontally?  As you click on a 
> particular tiddler, it opens a child tiddler on a side horizontal pane.  If 
> that can be done, this would be an amazing structure.

-- 
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/85c5a224-65a1-4cbc-ad25-87f568f169e3n%40googlegroups.com.


[tw5] Newbie with few distinct questions

2020-12-11 Thread Alex DP
Hello to you all.

TiddlyWiki is fun to work with. However, the documentation is like a 
fishing expedition. Someday you catch something and the next you are 
frustrated. It is hard to understand how come a product as mature as 
TiddlyWiki does not have a comprehensive and well organised documentation 
system.

Okay, here are my questions:
---
I finally found an easy way to insert computer language codes using:
```sql
-- Retourne toutes les fiches dont le champ prenom commence par J (Jacques, 
John):
SELECT nom,
   prenom
FROM client
WHERE prenom LIKE 'J%'
```
at first I used:
<$codeblock code="SELECT * FROM users WHERE deleted = false" language="sql" 
/>

My question is, what is the difference between these two approaches?
--
I would like to implement the "Icon - copy to clipboard" function that will 
facilitate the grabbing of code snippets. I could not find anything about 
it.

My question is, how can I implement the copy to clipboard feature?
---
I copied my TiddlyWiki in a sub-directory of a shared hosting I have. I 
implemented a php saving approach. The TW is hard to find and this is good. 
I do not mind if people have a look at the content (after all, sharing is 
and should be the primary purpose of Internet). However, I would not 
appreciate if some hooligan came and vandalised my site.

My question is, how can I implement a password system so the editing of 
tiddlers and access to the backend (control panel) is protected? I do not 
want to use a static site generator since I use three different computes to 
edit the site.
---
I wrote a minimalistic surface converter (i.e. acre to square miles or 
hectare ...) using a very small javascript and some html (table). I copied 
the whole thing in a tiddler and it did not work. I got the infamous:
Blocked script execution in '' because the document's frame is 
sandboxed and the 'allow-scripts' permission is not set. For sure, 
TiddlyWiki put the data of a tiddler in a sandbox iframe for security 
reason. I do not want to change javascript and form permission for the 
iframe.

My question is, I can I implement this small but useful calculator?
-
Thank you to all of you

Regards, 



-- 
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/54ac2070-8306-4d59-a8f1-f3a67ca759e3n%40googlegroups.com.


Re: [tw5] Is there a way to create a tiddler using text that is stored in the clipboard?

2020-12-11 Thread TW Tones
Springer,

Some thoughts for you;

   - When you paste text onto tiddlywiki the import mechaisium will create 
   an "untitled n" tiddler. Go ahead and import it.
   - You can create a view template on tiddlers beginning untitled that 
   tests the content of the text field for various conditions. 
  - I have one that tests if text begins with http:// or https:// 
  meaning its a link, and a button appears to name and create a link 
tiddler. 
  It uses my own designed logic.
   - You can do similar and detect say @ as the first character and offer 
   to create a citation tiddler.
  - The detail is in parsing and reformatting the citation into fields 
  etc... which I / we can help you with.
   - Yes this could be automated further with the ideas expressed in this 
   thread, but this approach would be a good start.
   - Ideally one day it will be easy to import and transform and common 
   text formats of any type into a tiddler. 

Regards
Tone

On Saturday, 12 December 2020 at 11:45:33 UTC+11 springer wrote:

> I just discovered this thread, while trying to understand related issues.
>
> My workflow includes, for example, coming a cross a citation in google 
> scholar, which I can display in bibtex format like so: 
>
> @book{crary2016inside, 
> title={Inside ethics}, 
> author={Crary, Alice}, 
> year={2016}, 
>publisher={Harvard University Press} 
> }
>
> I was hoping that dragging that text into Tiddlywiki would auto-populate 
> the fields. Instead, I get an ordinary tiddler with a text field that looks 
> exactly like the above block.
>
> What works: issuing a terminal command like pbpaste > crary.bib
>  ... which yields a .bib file ... which I can then drag into tw5 (for 
> import and recognition via bibtex plugin), but this is terribly roundabout.
>
> Why not be able to drag and drop the contents of a field-parsable string 
> (onto a special bibtex or json drop area if need be) and have tiddlywiki 
> parse directly, populating fields if field patterns are present?
>
> (Sorry that this question is framed with bibtex records in mind; but 
> presumably the issues are similar for any json-formatted strings on the 
> clipboard?)
>
> -Springer
> On Tuesday, November 10, 2020 at 7:58:27 PM UTC-5 TW Tones wrote:
>
>> David,
>>
>> In a similar vein for creating tiddlers from found text the OT and your 
>> desire for "loaded" new tiddlers, One idea I had was to create a tab in the 
>> side bar with a drop zone. Text dropped there would be imported silently 
>> and create a tiddler according to a set of standards and fields etc. A 
>> Second tab dropzone, could import the text another way. This method would 
>> do well to have the below templates idea.
>>
>>- David's point 1. Use the viewTemplate for untitled tiddlers and add 
>>this feature there (as in my last post)
>>
>> Templates idea
>>
>> TiddlyWiki is repeat with the concept of templates, as a result, I think 
>> perhaps we have somewhat neglected the use of tiddler templates for 
>> creating tiddlers. This should have a core representation so extra bespoke 
>> work is not required for such a fundamental function. 
>>
>> I have developed a number of methods that can help meet the ideas in your 
>> other points, The key is however having defined some template tiddlers that 
>> are used to create different kinds of tiddlers. Such templates can have 
>> what ever fields and values you want and one trick is to also include 
>> fields for example with an underscore name eg: _tags value" "tagname1 
>> tagname2", underscore fields are used to populate the no underscore field 
>> of the same name eg: tags value" "tagname1 tagname2" when creating the new 
>> tiddler from the template.
>>
>> Fields can only contain lowercase letters, digits and the characters 
>> underscore (_), hyphen (-) and period (.) this this are the three 
>> punctuation prefixes available.
>> So I suggest;
>>
>>- _fieldname results a in fieldname being created with the value in 
>>_fieldname used (if any).
>>   - One special case would be _source-template which is recorded in 
>>   the new tiddler
>>   - another _object-name eg "task" when the template is used to 
>>   create a task
>>- .fieldname If the current tiddler has fieldname use the "current 
>>tiddlers fieldname" to set the value "a context field"
>>- -fieldname could potentially use a macro or transclusion of a 
>>similar name as fieldname to populate the new field.
>>- All other fields are cloned into the new tiddler.
>>
>>
>>
>>
>>
>> On Wednesday, 11 November 2020 00:19:54 UTC+11, David Gifford wrote:
>>>
>>> I decided to delete and rewrite my post since it was somewhat 
>>> incomprehensible:
>>>
>>> I have an idea that if implemented in TiddlyWiki, would solve si's 
>>> problem, and would also solve a problem of my own: my problem is that 
>>> sometimes I want any tiddler generated by creating a wikilink then clicking 
>>> on the link, to 

Re: [tw5] Is there a way to create a tiddler using text that is stored in the clipboard?

2020-12-11 Thread springer
I just discovered this thread, while trying to understand related issues.

My workflow includes, for example, coming a cross a citation in google 
scholar, which I can display in bibtex format like so: 

@book{crary2016inside, 
title={Inside ethics}, 
author={Crary, Alice}, 
year={2016}, 
   publisher={Harvard University Press} 
}

I was hoping that dragging that text into Tiddlywiki would auto-populate 
the fields. Instead, I get an ordinary tiddler with a text field that looks 
exactly like the above block.

What works: issuing a terminal command like pbpaste > crary.bib
 ... which yields a .bib file ... which I can then drag into tw5 (for 
import and recognition via bibtex plugin), but this is terribly roundabout.

Why not be able to drag and drop the contents of a field-parsable string 
(onto a special bibtex or json drop area if need be) and have tiddlywiki 
parse directly, populating fields if field patterns are present?

(Sorry that this question is framed with bibtex records in mind; but 
presumably the issues are similar for any json-formatted strings on the 
clipboard?)

-Springer
On Tuesday, November 10, 2020 at 7:58:27 PM UTC-5 TW Tones wrote:

> David,
>
> In a similar vein for creating tiddlers from found text the OT and your 
> desire for "loaded" new tiddlers, One idea I had was to create a tab in the 
> side bar with a drop zone. Text dropped there would be imported silently 
> and create a tiddler according to a set of standards and fields etc. A 
> Second tab dropzone, could import the text another way. This method would 
> do well to have the below templates idea.
>
>- David's point 1. Use the viewTemplate for untitled tiddlers and add 
>this feature there (as in my last post)
>
> Templates idea
>
> TiddlyWiki is repeat with the concept of templates, as a result, I think 
> perhaps we have somewhat neglected the use of tiddler templates for 
> creating tiddlers. This should have a core representation so extra bespoke 
> work is not required for such a fundamental function. 
>
> I have developed a number of methods that can help meet the ideas in your 
> other points, The key is however having defined some template tiddlers that 
> are used to create different kinds of tiddlers. Such templates can have 
> what ever fields and values you want and one trick is to also include 
> fields for example with an underscore name eg: _tags value" "tagname1 
> tagname2", underscore fields are used to populate the no underscore field 
> of the same name eg: tags value" "tagname1 tagname2" when creating the new 
> tiddler from the template.
>
> Fields can only contain lowercase letters, digits and the characters 
> underscore (_), hyphen (-) and period (.) this this are the three 
> punctuation prefixes available.
> So I suggest;
>
>- _fieldname results a in fieldname being created with the value in 
>_fieldname used (if any).
>   - One special case would be _source-template which is recorded in 
>   the new tiddler
>   - another _object-name eg "task" when the template is used to 
>   create a task
>- .fieldname If the current tiddler has fieldname use the "current 
>tiddlers fieldname" to set the value "a context field"
>- -fieldname could potentially use a macro or transclusion of a 
>similar name as fieldname to populate the new field.
>- All other fields are cloned into the new tiddler.
>
>
>
>
>
> On Wednesday, 11 November 2020 00:19:54 UTC+11, David Gifford wrote:
>>
>> I decided to delete and rewrite my post since it was somewhat 
>> incomprehensible:
>>
>> I have an idea that if implemented in TiddlyWiki, would solve si's 
>> problem, and would also solve a problem of my own: my problem is that 
>> sometimes I want any tiddler generated by creating a wikilink then clicking 
>> on the link, to have certain fields and data.
>>
>> My idea is this:
>>
>> 1. Have a separate tab in the control panel with the "Title for new 
>> tiddlers" and "Tags for new tiddlers"from the basics tab, but with a new 
>> element: "Fields for new tiddlers", which could look just like it does at 
>> the bottom of edit mode in all tiddlers. That way, si could set the fields 
>> (and add text to them if desired) so that when he pastes the text, the 
>> tiddler generated would have the fields and data added. Let's call this tab 
>> $:/core/ui/ControlPanel/NewTiddlerConfig 
>>
>> 2. The other aspect of my idea is that 
>> $:/core/ui/ControlPanel/NewTiddlerConfig could be tagged, say, 
>> $:/tags/NewTiddlerConfig. And only the tiddler that has this tag will 
>> modify the creation of new tiddlers. So users could clone this tiddler and 
>> have a number of custom "new tiddler config" tabs - one for images, one for 
>> reading notes, one for contacts, etc, and use a switcher to tag the one 
>> they want to work on at a given time.
>>
>> 3. Why is this helpful? Currently the only way to create tiddlers with 
>> preset fields is to create a custom new tiddler butto

[tw5] Horizontal arrangement?

2020-12-11 Thread Krish
Newbie here.  Sorry if this question has been asked. Can Tiddlers be 
arranged not only vertically but also horizontally?  As you click on a 
particular tiddler, it opens a child tiddler on a side horizontal pane.  If 
that can be done, this would be an amazing structure.

-- 
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/b842b28a-a92c-469e-aaf0-10940d5eaa16n%40googlegroups.com.


[tw5] Re: Recording audio and video directly into TiddlyWiki?

2020-12-11 Thread TW Tones
Also,

If we can more readily use audio more in tiddlywiki it would be nice to 
have an action widget that could play such audio according to a desired 
trigger. Thus buttons and tiddlers could have small audio prompts. It would 
wise to also have a toggle that can mute all audio for the wiki.

Tones

On Saturday, 12 December 2020 at 10:40:12 UTC+11 TW Tones wrote:

> Some thoughts on this;
>
>- Recording to tiddler, then exporting it to an audio file, such that 
>it can be externalised would be wise, because audio files can grow too big 
>to be included in a single file wiki.
>- Server implementations may do this differently but we should always 
>design such that a solution is also effective in standalone wikis.
>- Subsequent tools to allow tiddlers to be "annotated" with audio 
>recordings similar to the comments solution would be good.
>
> Regards
> Tones
>
>
>
> On Saturday, 12 December 2020 at 09:16:41 UTC+11 altugozc...@gmail.com 
> wrote:
>
>> Hi Si, 
>>
>> I am not aware of any current solution but just wanted to chime in and 
>> say I would be interested in having something like that too.
>>
>> My impression from the existing TW plugins is that if there is a 
>> standalone js library for achieving something, there is generally a good 
>> chance that it can be integrated with TW. 
>>
>> ... and I just checked and there are actually at least a few js libraries 
>> that can record audio. Here is a library that seems somewhat current and 
>> lightweight...
>>
>> https://github.com/Kagami/vmsg
>>
>> Now, I don't have enough js knowledge to do this wizardry myself (yet... 
>> getting there...) but there may be someone in the forum who is interested 
>> in working on this.
>>
>> I didn't touch the video recording part. However, that would be cool as 
>> well.
>>
>> Another direction that I find interesting is whether the audio could be 
>> transcribed and converted to a tiddler automatically. I realize this is a 
>> higher hanging fruit, but could be very useful for notetaking.
>>
>> Anyway, these are my two cents.
>>
>> Take care,
>> -Altug
>>
>>
>>
>> On Thursday, December 10, 2020 at 4:37:08 PM UTC+3 si wrote:
>>
>>> Just wondered if there are any tools out there that I am not aware of?
>>>
>>> Currently I record audio in Audacity and then import it in or create a 
>>> canonical_uri, but it would be nice to find an approach that has fewer 
>>> steps.
>>>
>>

-- 
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/1f81eab2-1078-48d1-81c5-197c2d812ca2n%40googlegroups.com.


[tw5] Re: Recording audio and video directly into TiddlyWiki?

2020-12-11 Thread TW Tones
Some thoughts on this;

   - Recording to tiddler, then exporting it to an audio file, such that it 
   can be externalised would be wise, because audio files can grow too big to 
   be included in a single file wiki.
   - Server implementations may do this differently but we should always 
   design such that a solution is also effective in standalone wikis.
   - Subsequent tools to allow tiddlers to be "annotated" with audio 
   recordings similar to the comments solution would be good.

Regards
Tones



On Saturday, 12 December 2020 at 09:16:41 UTC+11 altugozc...@gmail.com 
wrote:

> Hi Si, 
>
> I am not aware of any current solution but just wanted to chime in and say 
> I would be interested in having something like that too.
>
> My impression from the existing TW plugins is that if there is a 
> standalone js library for achieving something, there is generally a good 
> chance that it can be integrated with TW. 
>
> ... and I just checked and there are actually at least a few js libraries 
> that can record audio. Here is a library that seems somewhat current and 
> lightweight...
>
> https://github.com/Kagami/vmsg
>
> Now, I don't have enough js knowledge to do this wizardry myself (yet... 
> getting there...) but there may be someone in the forum who is interested 
> in working on this.
>
> I didn't touch the video recording part. However, that would be cool as 
> well.
>
> Another direction that I find interesting is whether the audio could be 
> transcribed and converted to a tiddler automatically. I realize this is a 
> higher hanging fruit, but could be very useful for notetaking.
>
> Anyway, these are my two cents.
>
> Take care,
> -Altug
>
>
>
> On Thursday, December 10, 2020 at 4:37:08 PM UTC+3 si wrote:
>
>> Just wondered if there are any tools out there that I am not aware of?
>>
>> Currently I record audio in Audacity and then import it in or create a 
>> canonical_uri, but it would be nice to find an approach that has fewer 
>> steps.
>>
>

-- 
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/ff41b91b-ac02-4915-96fb-fd48af8ca7a8n%40googlegroups.com.


Re: [tw5] Could we have a zip download saver mechanism?

2020-12-11 Thread TW Tones
Folks,

With or without the zip features in the core I am keen to see it's use 
mainstreamed for the following; I am keen to keep the functionality in 
single file wikis

   - When wishing to export content to more than one file
  - This is one of the key values of the zip process, because multiple 
  files can be exported in one somewhat automated action.
  - Allow solutions in tiddlywiki to generate files such that will be 
  "ingested" by other systems.
   - Static websites
  - Including when the static site pages link back to the "index.html 
  full wiki" SEO optimise and interactive solution. (this should be an out 
of 
  the box core solution to help production tiddlywikis)
  - Generation of other types of HTML pages (not just tiddlywiki static 
  tiddlers)
 - Eg allowing HTML in  tiddler interact with the underlying server 
 to login etc..
  - Bundling filtered tiddlers for 
  - export or backup
 - Whole or delta
  - emailing a zip or file directly as a submission from read only wikis
   - Compressing and saving the whole or selectively generated tiddlywiki 
   eg; edition
  - With additional files on occasion eg an edition that includes the 
  PHP files for installing tw-receiver. Can include interactive dialogue 
  etc... to generate keys and other security incorporated into the 
additional 
  files.
   - Generating additional files to be used in conjunction with 
   TiddlyDesktop for local machine interaction.


Can we unzip within tiddlywiki to tiddlers?

Regards
Tones
On Friday, 11 December 2020 at 22:00:01 UTC+11 jeremy...@gmail.com wrote:

> Hi Mark
>
> I was thinking that the saver would be in the core along with the other 
> savers, but only displayed as an option if it detected the JSZip plugin. Or 
> would display with the message "Install JSZip to activate."
>
>
> Yes indeed. In fact, I am interested in the idea of integrating JSZip into 
> the core so that we can add support for compressed plugins. JSZip weighs 
> about 80KB, while compressing the core plugin reduces it from 1.9MB to 
> 330KB. Once we’ve got JSZip we can add core support for things like your 
> saver suggestion, or exporting static HTML with shared CSS as a ZIP file.
>
> Best wishes
>
> Jeremy
>
>
> Thanks!
>
> On Thursday, December 10, 2020 at 9:37:01 AM UTC-8 jeremy...@gmail.com 
> wrote:
>
>> Hi Mark
>>
>> That’s a great idea. Right now the JSZip plugin isn’t a part of the core, 
>> so such a saver would have to reside in the plugin.
>>
>> In the meantime, one could make a custom button for the sidebar that 
>> performed the zip and save operation. The example given with the JSZip 
>> plugin should get you started,
>>
>> Best wishes
>>
>> Jeremy.
>>
>> On 8 Dec 2020, at 22:09, 'Mark S.' via TiddlyWiki <
>> tiddl...@googlegroups.com> wrote:
>>
>> Now that we have (or will have in 5.1.23) a means to zip up tiddlers, 
>> could we have a download saver that zips up the current TW?
>>
>> Motivation: Chrome on Android doesn't allow extensions, and now mangles 
>> the original file name, adding it's own prefix text. If the saver could 
>> save a zipped copy, then the version with the real file name could be 
>> stored in the zip file. When you need to start a new session, you can just 
>> unzip the file with the right name.
>>
>> Plus, the zip files would take less space and be easier to manage.
>>
>> 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/25000ac6-bd15-407a-b5d5-1f116807f976n%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+...@googlegroups.com.
>
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/tiddlywiki/f51db090-eb5e-4694-af4a-aaa616343a1cn%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/2327bd55-4d73-4f0c-bbc7-74e678037baan%40googlegroups.com.


[tw5] Re: Recording audio and video directly into TiddlyWiki?

2020-12-11 Thread Altug Ozcelikkale
Hi Si, 

I am not aware of any current solution but just wanted to chime in and say 
I would be interested in having something like that too.

My impression from the existing TW plugins is that if there is a standalone 
js library for achieving something, there is generally a good chance that 
it can be integrated with TW. 

... and I just checked and there are actually at least a few js libraries 
that can record audio. Here is a library that seems somewhat current and 
lightweight...

https://github.com/Kagami/vmsg

Now, I don't have enough js knowledge to do this wizardry myself (yet... 
getting there...) but there may be someone in the forum who is interested 
in working on this.

I didn't touch the video recording part. However, that would be cool as 
well.

Another direction that I find interesting is whether the audio could be 
transcribed and converted to a tiddler automatically. I realize this is a 
higher hanging fruit, but could be very useful for notetaking.

Anyway, these are my two cents.

Take care,
-Altug



On Thursday, December 10, 2020 at 4:37:08 PM UTC+3 si wrote:

> Just wondered if there are any tools out there that I am not aware of?
>
> Currently I record audio in Audacity and then import it in or create a 
> canonical_uri, but it would be nice to find an approach that has fewer 
> steps.
>

-- 
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/d6e3edf4-1b52-463a-9ef7-f1b3729fb501n%40googlegroups.com.


[tw5] Re: How to create a new field and translate multiple values with a dictionary?

2020-12-11 Thread Eric Shulman
On Friday, December 11, 2020 at 7:05:32 AM UTC-8 Harry wrote:

> when I click the button, nothing changes. I wonder if this is because my 
> birth_year field also has "na" as a value, I changed all na to 0, but the 
> button still does not work.
> <$button> assign retired
> <$list filter="[has[birth_year]]">
><$list 
> filter="[get[birth_year]compare:integer:lt[1948]then!c_status[dead]!c_status[purged]]">
>   <$action-setfield c_status="retired" />
>
> 
> 
>

A field value of "na" is equivalent to "0".  I tried the above code on 
TiddlyWiki.com, providing it with a tiddler named "test", containing a 
"birth_year" field containing "na".  After pressing the button, the "test" 
tiddler had a new "c_status" field added, containing a value of "retired".  
Note that to see this field and value, you have to edit the "test" tiddler.
 

> I then tried the following code to create a list, but the tiddler still 
> shows nothing. I wonder if you have any idea about what might be wrong with 
> my dataset? Many thanks!
> <$list filter="[has[birth_year]]">
>  <$list 
> filter="[get[birth_year]compare:number:gteq[1]compare:number:lteq[1948]]">
>   <>
>
> 
>

You left off the "then" syntax that follows the compare.  
Without this, the result of the filter is the value that you get[...] from 
the birth_year field, rather than the title of the matching tiddler.  Also, 
your first compare is "gteq[1]", so this would not match tiddlers where the 
"birth_year" field contains "0" (or "na").  If you change the filter to:
 <$list 
filter="[get[birth_year]compare:number:gteq[0]compare:number:lteq[1948]then]">
it will show tiddler titles for all tiddlers with a non-blank "birth_year" 
field, even those with a value of "0" or "na".

enjoy,
-e 

-- 
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/a457d3e7-952f-4109-aef1-5d9b8802a43en%40googlegroups.com.


[tw5] Re: How to create a new field and translate multiple values with a dictionary?

2020-12-11 Thread Harry
Thanks Eric! may I ask you to also look into the question in my first post? 
( create a new field using a dictionary tiddler)

Also I tried the code you provided, really learned a lot on the compare 
operator.But when I click the button, nothing changes. I wonder if this is 
because my birth_year field also has "na" as a value, I changed all na to 
0, but the button still does not work.
<$button> assign retired
<$list filter="[has[birth_year]]">
   <$list 
filter="[get[birth_year]compare:integer:lt[1948]then!c_status[dead]!c_status[purged]]">
  <$action-setfield c_status="retired" />
   



I then tried the following code to create a list, but the tiddler still 
shows nothing. I wonder if you have any idea about what might be wrong with 
my dataset? Many thanks!

<$list filter="[has[birth_year]]">
 <$list 
filter="[get[birth_year]compare:number:gteq[1]compare:number:lteq[1948]]">
  <>
   


在2020年12月11日星期五 UTC-5 上午5:54:48 写道:

> Here's some sample filter logic for each of the conditions you want:
>
> On Thursday, December 10, 2020 at 8:52:42 PM UTC-8 Harry wrote:
>
>> I want to filter all entries born before 1948 (in the birth_year field) 
>> who has not died or been purged (in the c_status field), and assign them 
>> value "retired".
>>
>
> *birth_date < 1948 and not c_status=dead and not c_status=purged*
> <$button> assign retired
> <$list filter="[has[birth_year]]">
><$list 
> filter="[get[birth_year]compare:integer:lt[1948]then!c_status[dead]!c_status[purged]]">
>   <$action-setfield c_status="retired" />
>
> 
> 
>
> I would also appreciate general guidance on filtering field value of a 
>> certain numeric range (say greater than 1952, or between 1936 and 1978)
>>
>
> *birth_date > 1952*
> <$list filter="[has[birth_year]]">
><$list 
> filter="[get[birth_year]compare:integer:gt[1952]then]">
>   <>
>
> 
>
> *birth_date between 1936 and 1978 (inclusive)*
> <$list filter="[has[birth_year]]">
><$list 
> filter="[get[birth_year]compare:integer:gteq[1936]compare:integer:lteq[1978]then]">
>   <>
>
> 
>  
>
>> or value of a particular vector (say contains either 
>> 1,3,8,16,33,47,287,1345, etc, 
>>
>
> *somefield contains any of 1,3,8,16,33,47,287,1345,*
> <$list filter="[has[somefield]]">
><$list filter="[enlist[1 3 8 16 33 47 287 1345 
> ]match{!!somefield}then]">
>   <>
>
> 
>
> enjoy,
> -e
>

-- 
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/699d3dbd-9db0-491b-8f79-59ca51a8e006n%40googlegroups.com.


[tw5] Re: How to create a new field and translate multiple values with a dictionary?

2020-12-11 Thread Ste

Mohammed's tiddly commander thing also allows batch operations. 
I'll try and dig out the link when I get chance of no one beats me to it. 
On Friday, 11 December 2020 at 10:54:48 UTC Eric Shulman wrote:

> Here's some sample filter logic for each of the conditions you want:
>
> On Thursday, December 10, 2020 at 8:52:42 PM UTC-8 Harry wrote:
>
>> I want to filter all entries born before 1948 (in the birth_year field) 
>> who has not died or been purged (in the c_status field), and assign them 
>> value "retired".
>>
>
> *birth_date < 1948 and not c_status=dead and not c_status=purged*
> <$button> assign retired
> <$list filter="[has[birth_year]]">
><$list 
> filter="[get[birth_year]compare:integer:lt[1948]then!c_status[dead]!c_status[purged]]">
>   <$action-setfield c_status="retired" />
>
> 
> 
>
> I would also appreciate general guidance on filtering field value of a 
>> certain numeric range (say greater than 1952, or between 1936 and 1978)
>>
>
> *birth_date > 1952*
> <$list filter="[has[birth_year]]">
><$list 
> filter="[get[birth_year]compare:integer:gt[1952]then]">
>   <>
>
> 
>
> *birth_date between 1936 and 1978 (inclusive)*
> <$list filter="[has[birth_year]]">
><$list 
> filter="[get[birth_year]compare:integer:gteq[1936]compare:integer:lteq[1978]then]">
>   <>
>
> 
>  
>
>> or value of a particular vector (say contains either 
>> 1,3,8,16,33,47,287,1345, etc, 
>>
>
> *somefield contains any of 1,3,8,16,33,47,287,1345,*
> <$list filter="[has[somefield]]">
><$list filter="[enlist[1 3 8 16 33 47 287 1345 
> ]match{!!somefield}then]">
>   <>
>
> 
>
> enjoy,
> -e
>

-- 
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/eca48727-c77e-4668-8490-3a60f2807cd3n%40googlegroups.com.


Re: [tw5] Could we have a zip download saver mechanism?

2020-12-11 Thread Jeremy Ruston
Hi Mark

> I was thinking that the saver would be in the core along with the other 
> savers, but only displayed as an option if it detected the JSZip plugin. Or 
> would display with the message "Install JSZip to activate."

Yes indeed. In fact, I am interested in the idea of integrating JSZip into the 
core so that we can add support for compressed plugins. JSZip weighs about 
80KB, while compressing the core plugin reduces it from 1.9MB to 330KB. Once 
we’ve got JSZip we can add core support for things like your saver suggestion, 
or exporting static HTML with shared CSS as a ZIP file.

Best wishes

Jeremy

> 
> Thanks!
> 
> On Thursday, December 10, 2020 at 9:37:01 AM UTC-8 jeremy...@gmail.com wrote:
> Hi Mark
> 
> That’s a great idea. Right now the JSZip plugin isn’t a part of the core, so 
> such a saver would have to reside in the plugin.
> 
> In the meantime, one could make a custom button for the sidebar that 
> performed the zip and save operation. The example given with the JSZip plugin 
> should get you started,
> 
> Best wishes
> 
> Jeremy.
> 
> 
>> On 8 Dec 2020, at 22:09, 'Mark S.' via TiddlyWiki > > wrote:
>> 
> 
>> Now that we have (or will have in 5.1.23) a means to zip up tiddlers, could 
>> we have a download saver that zips up the current TW?
>> 
>> Motivation: Chrome on Android doesn't allow extensions, and now mangles the 
>> original file name, adding it's own prefix text. If the saver could save a 
>> zipped copy, then the version with the real file name could be stored in the 
>> zip file. When you need to start a new session, you can just unzip the file 
>> with the right name.
>> 
>> Plus, the zip files would take less space and be easier to manage.
>> 
>> 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/25000ac6-bd15-407a-b5d5-1f116807f976n%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/f51db090-eb5e-4694-af4a-aaa616343a1cn%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/CB2AF94C-A37B-4371-A38A-E1C0191FF705%40gmail.com.


[tw5] Re: How to create a new field and translate multiple values with a dictionary?

2020-12-11 Thread Eric Shulman
Here's some sample filter logic for each of the conditions you want:

On Thursday, December 10, 2020 at 8:52:42 PM UTC-8 Harry wrote:

> I want to filter all entries born before 1948 (in the birth_year field) 
> who has not died or been purged (in the c_status field), and assign them 
> value "retired".
>

*birth_date < 1948 and not c_status=dead and not c_status=purged*
<$button> assign retired
<$list filter="[has[birth_year]]">
   <$list 
filter="[get[birth_year]compare:integer:lt[1948]then!c_status[dead]!c_status[purged]]">
  <$action-setfield c_status="retired" />
   



I would also appreciate general guidance on filtering field value of a 
> certain numeric range (say greater than 1952, or between 1936 and 1978)
>

*birth_date > 1952*
<$list filter="[has[birth_year]]">
   <$list 
filter="[get[birth_year]compare:integer:gt[1952]then]">
  <>
   


*birth_date between 1936 and 1978 (inclusive)*
<$list filter="[has[birth_year]]">
   <$list 
filter="[get[birth_year]compare:integer:gteq[1936]compare:integer:lteq[1978]then]">
  <>
   

 

> or value of a particular vector (say contains either 
> 1,3,8,16,33,47,287,1345, etc, 
>

*somefield contains any of 1,3,8,16,33,47,287,1345,*
<$list filter="[has[somefield]]">
   <$list filter="[enlist[1 3 8 16 33 47 287 1345 
]match{!!somefield}then]">
  <>
   


enjoy,
-e

-- 
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/ceb8ca50-9ca2-4024-adaa-3d028cc8d0f6n%40googlegroups.com.