On Wednesday, April 8, 2015 at 2:57:32 PM UTC-4, Eric Shulman wrote:
>
> On Wednesday, April 8, 2015 at 11:03:38 AM UTC-7, AlexHough wrote:
>>
>> in other words, dragging a pdf into TW inserts the text of the pdf into 
>> the tiddler.... as plain text?
>>
>
> Nope.  It inserts the PDF as a binary file, stored using base64-text 
> encoding.  When you view the PDF tiddler directly (or embed it via 
> transclusion), it renders the PDF inline within your browser... but it's 
> still a binary.  It's not plain text.
>
> -e
>

Also, I have found that if the PDF is large enough or complex enough, your 
TiddlyWiki document will crash and burn. Small simple PDFs embed quite 
nicely.

A work-around that is a safer bet is to make a tiddler that is an external 
link to the document. It can be a relative file:// type link so you can 
keep everything in one directory tree. Then you can do all the 
transcluding/tagging/etc. that you can do if it was embedded without the 
crashiness.

I Frankensteined together a little helper tiddler from tips and tricks from 
people here to make these external links that I include as a tool in each 
document I create ... cut and paste the following into a tiddler and start 
linking.

/Mike

************

\define theTiddler() $(the_tiddler)$!!title


\define myconcat() $(t1)$$(t2)$


|!Filename |<$edit-text tiddler="$:/temp/ExternalLink" 
placeholder="filename" tag="input" type="text"/> |
|!Directory |<$edit-text tiddler="$:/temp/ExternalLink" field="directory" 
placeholder="directory" tag="input" type="text"/> |


''Filetype:'' <$select tiddler='$:/temp/ExternalLink' field='type' 
default='image/gif'>
<$list 
filter='[all[shadows+tiddlers]prefix[$:/language/Docs/Types/]each[group]sort[group]]'>
<optgroup label={{!!group}}>
<$list 
filter='[all[shadows+tiddlers]prefix[$:/language/Docs/Types/]group{!!group}] 
+[sort[description]]'>
<option value={{!!name}}><$view field='description'><$view 
field='title'/></$view> (<$view field='name'/>)</option>
</$list>
</optgroup>
</$list>
</$select>


<$set name="t1" value={{$:/temp/ExternalLink!!directory}}>
<$set name="t2" value={{$:/temp/ExternalLink!!text}}>


_canonical_uri field = <<myconcat>>


<$reveal type="nomatch" text="" state="$:/temp/ExternalLink">
  <$reveal type="match" text={{$:/temp/ExternalLink}} 
state={{$:/temp/ExternalLink}}>
    <$button set="$:/temp/ExternalLink!!title" 
setTo={{$:/temp/ExternalLink}}>
<$action-setfield $tiddler="$:/temp/ExternalLink" $field="_canonical_uri" 
$value=<<myconcat>>/>
      Modify
    </$button>
    <$set name="the_tiddler" value={{$:/temp/ExternalLink}}>
    <$button setTo="$:/temp/ExternalLink" set=<<theTiddler>>>
      Fetch
    </$button>
    </$set>
  </$reveal>
  <$reveal type="match" text="" state={{$:/temp/ExternalLink}}>
    <$button set="$:/temp/ExternalLink!!title" 
setTo={{$:/temp/ExternalLink}}>
<$action-setfield $tiddler="$:/temp/ExternalLink" $field="_canonical_uri" 
$value=<<myconcat>>/>
      Create
    </$button>
  </$reveal>
</$reveal>
</$set>
</$set> 

****************

-- 
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 post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/740a9ce9-7b5f-4ff7-9795-2d88b309025a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to