Oh man THANK YOU! Out of all the digging I didn't spot anything that looked 
like this. Works great. However, now I need to make the foreground work in 
contrast to that. I know there's a way to do it as I've seen it in 
TiddlyWiki here and there. It seems to be aware when the background is too 
dark to create white text versus dark text. 

What magic is that?


On Thursday, February 20, 2020 at 4:27:45 PM UTC-6, Mark S. wrote:
>
> Not sure what the "set" was supposed to be doing. If I understand what you 
> want, this seems to work:
>
> \whitespace trim
>     <span style={{{ [{!!color}addprefix[background-color: ]] }}} >
>     <<currentTiddler>>
>     </span>
>
>
>
> On Thursday, February 20, 2020 at 2:06:44 PM UTC-8, T. E. Sanders wrote:
>>
>> Hey all, I'm trying to write a template. It works as a template in that 
>> it renders the currentTiddler, but if I try to use the color from the 
>> tiddler on the background, it doesn't evaluate and simply renders the text 
>> as-is.
>>
>> For example
>> \whitespace trim
>> \define col() {{!!color}}
>> <$set name="transclusion" value=<<currentTiddler>>>
>>     <span style="background-color:<<col>>" >
>>     <<currentTiddler>>
>>     </span>
>> </$set>
>>
>> doesn't work. Neither did style="background-color:{{!!color}}" and it 
>> doesn't matter if I use quotes or not. Clearly I'm missing some syntax or 
>> something.
>> The goal is just to make the background the color set in the color field. 
>> Ideas?
>>
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/9c61d1a0-4642-436d-8ce4-6452f5803da4%40googlegroups.com.

Reply via email to