mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-23 10:07:19 +00:00
Optimise ordering of filter expressions
We get a significant speed improvement of >10% by rearranging filter operators to bring to the front the operators likely to reduce the size working list.
This commit is contained in:
parent
4d91a7762e
commit
c7b4febae3
@ -1,5 +1,5 @@
|
||||
title: $:/AdvancedSearch
|
||||
|
||||
<div class="tw-advanced-search">
|
||||
<<tabs "[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/AdvancedSearch]]" "$:/core/ui/AdvancedSearch/System">>
|
||||
<<tabs "[all[tiddlers+shadows]tag[$:/tags/AdvancedSearch]!has[draft.of]]" "$:/core/ui/AdvancedSearch/System">>
|
||||
</div>
|
||||
|
@ -1,5 +1,5 @@
|
||||
title: $:/ControlPanel
|
||||
|
||||
<div class="tw-control-panel">
|
||||
<<tabs "[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/ControlPanel]]" "$:/core/ui/ControlPanel/Basics">>
|
||||
<<tabs "[all[tiddlers+shadows]tag[$:/tags/ControlPanel]!has[draft.of]]" "$:/core/ui/ControlPanel/Basics">>
|
||||
</div>
|
||||
|
@ -5,5 +5,5 @@ caption: {{$:/language/ControlPanel/Advanced/Caption}}
|
||||
{{$:/language/ControlPanel/Advanced/Hint}}
|
||||
|
||||
<div class="tw-control-panel">
|
||||
<<tabs "[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/ControlPanel/Advanced]]" "$:/core/ui/ControlPanel/Advanced/TiddlerFields">>
|
||||
<<tabs "[all[tiddlers+shadows]tag[$:/tags/ControlPanel/Advanced]!has[draft.of]]" "$:/core/ui/ControlPanel/Advanced/TiddlerFields">>
|
||||
</div>
|
||||
|
@ -5,5 +5,5 @@ caption: {{$:/language/ControlPanel/Appearance/Caption}}
|
||||
{{$:/language/ControlPanel/Appearance/Hint}}
|
||||
|
||||
<div class="tw-control-panel">
|
||||
<<tabs "[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/ControlPanel/Appearance]]" "$:/core/ui/ControlPanel/Appearance/Theme">>
|
||||
<<tabs "[all[tiddlers+shadows]tag[$:/tags/ControlPanel/Appearance]!has[draft.of]]" "$:/core/ui/ControlPanel/Appearance/Theme">>
|
||||
</div>
|
||||
|
@ -6,7 +6,7 @@ tw-tiddler-frame tw-tiddler-edit-frame $(missingTiddlerClass)$ $(shadowTiddlerCl
|
||||
<div class=<<frame-classes>>>
|
||||
<$set name="storyTiddler" value=<<currentTiddler>>>
|
||||
<$keyboard key="ctrl+enter" message="tw-save-tiddler">
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/EditTemplate]]" variable="listItem">
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/EditTemplate]!has[draft.of]]" variable="listItem">
|
||||
<$transclude tiddler=<<listItem>>/>
|
||||
</$list>
|
||||
</$keyboard>
|
||||
|
@ -1,4 +1,4 @@
|
||||
title: $:/core/ui/EditTemplate/controls
|
||||
tags: $:/tags/EditTemplate
|
||||
|
||||
<span class="tw-tiddler-controls titlebar"> <$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/EditToolbar]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list> </span>
|
||||
<span class="tw-tiddler-controls titlebar"> <$list filter="[all[tiddlers+shadows]tag[$:/tags/EditToolbar]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list> </span>
|
||||
|
@ -4,7 +4,7 @@ title: $:/core/ui/PageTemplate
|
||||
|
||||
<$dropzone>
|
||||
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/PageTemplate]]" variable="listItem">
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/PageTemplate]!has[draft.of]]" variable="listItem">
|
||||
|
||||
<$transclude tiddler=<<listItem>>/>
|
||||
|
||||
|
@ -3,6 +3,6 @@ tags: $:/tags/PageTemplate
|
||||
|
||||
<div class="tw-alerts">
|
||||
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/Alert]]" template="$:/core/ui/AlertTemplate" storyview="pop"/>
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/Alert]!has[draft.of]]" template="$:/core/ui/AlertTemplate" storyview="pop"/>
|
||||
|
||||
</div>
|
||||
|
@ -12,7 +12,7 @@ tags: $:/tags/PageTemplate
|
||||
|
||||
<div class="tw-page-controls">
|
||||
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/PageControls]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/PageControls]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -2,5 +2,5 @@ title: $:/core/ui/PageTemplate/topleftbar
|
||||
tags: $:/tags/PageTemplate
|
||||
|
||||
<span class="tw-topbar tw-topbar-left">
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/TopLeftBar]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/TopLeftBar]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
</span>
|
||||
|
@ -2,5 +2,5 @@ title: $:/core/ui/PageTemplate/toprightbar
|
||||
tags: $:/tags/PageTemplate
|
||||
|
||||
<span class="tw-topbar tw-topbar-right">
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/TopRightBar]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/TopRightBar]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
</span>
|
||||
|
@ -3,5 +3,5 @@ tags: $:/tags/SideBar
|
||||
caption: {{$:/language/SideBar/More/Caption}}
|
||||
|
||||
<div class="tw-more-sidebar">
|
||||
<<tabs "[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/MoreSideBar]]" "$:/core/ui/MoreSideBar/Tags" "$:/state/tab/moresidebar">>
|
||||
<<tabs "[all[tiddlers+shadows]tag[$:/tags/MoreSideBar]!has[draft.of]]" "$:/core/ui/MoreSideBar/Tags" "$:/state/tab/moresidebar">>
|
||||
</div>
|
||||
|
@ -26,7 +26,7 @@ title: $:/core/ui/SideBarLists
|
||||
|
||||
<$reveal state="$:/temp/search" type="match" text="">
|
||||
|
||||
<<tabs "[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/SideBar]]" "$:/core/ui/SideBar/Open" "$:/state/tab/sidebar">>
|
||||
<<tabs "[all[tiddlers+shadows]tag[$:/tags/SideBar]!has[draft.of]]" "$:/core/ui/SideBar/Open" "$:/state/tab/sidebar">>
|
||||
|
||||
</$reveal>
|
||||
</div>
|
||||
|
@ -1,3 +1,3 @@
|
||||
title: $:/core/ui/TiddlerInfo
|
||||
|
||||
<<tabs "[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/TiddlerInfo]]" "$:/core/ui/TiddlerInfo/References">>
|
||||
<<tabs "[all[tiddlers+shadows]tag[$:/tags/TiddlerInfo]!has[draft.of]]" "$:/core/ui/TiddlerInfo/References">>
|
||||
|
@ -2,7 +2,7 @@ title: $:/core/ui/TiddlerInfo/Advanced
|
||||
tags: $:/tags/TiddlerInfo
|
||||
caption: {{$:/language/TiddlerInfo/Advanced/Caption}}
|
||||
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/TiddlerInfo/Advanced]]" variable="listItem">
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/TiddlerInfo/Advanced]!has[draft.of]]" variable="listItem">
|
||||
<$transclude tiddler=<<listItem>>/>
|
||||
|
||||
</$list>
|
||||
|
@ -3,6 +3,6 @@ title: $:/core/ui/ViewTemplate
|
||||
\define frame-classes()
|
||||
tw-tiddler-frame tw-tiddler-view-frame $(missingTiddlerClass)$ $(shadowTiddlerClass)$ $(systemTiddlerClass)$
|
||||
\end
|
||||
<$set name="storyTiddler" value=<<currentTiddler>>><$set name="tiddlerInfoState" value=<<qualify "$:/state/tiddlerInfo">>><$tiddler tiddler=<<currentTiddler>>><div class=<<frame-classes>>><$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/ViewTemplate]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
<$set name="storyTiddler" value=<<currentTiddler>>><$set name="tiddlerInfoState" value=<<qualify "$:/state/tiddlerInfo">>><$tiddler tiddler=<<currentTiddler>>><div class=<<frame-classes>>><$list filter="[all[tiddlers+shadows]tag[$:/tags/ViewTemplate]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
</div>
|
||||
</$tiddler></$set></$set>
|
||||
|
@ -7,7 +7,7 @@ fill:$(foregroundColor)$;
|
||||
<div class="tw-tiddler-title">
|
||||
<div class="titlebar">
|
||||
<span class="tw-tiddler-controls">
|
||||
<$list filter="[all[tiddlers+shadows]!has[draft.of]tag[$:/tags/ViewToolbar]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
<$list filter="[all[tiddlers+shadows]tag[$:/tags/ViewToolbar]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
|
||||
</span>
|
||||
<$set name="foregroundColor" value={{!!color}}>
|
||||
<span style=<<title-styles>>>
|
||||
|
Loading…
Reference in New Issue
Block a user