Toolbar filtering and FAYT (Find-As-You-Type) can specify matches for a specified column, including columns that are added to the script.
I used a script to add a column, save the Chinese phonetic initials of the filename, sorted by this example (check in the sorted field when the Quick Search is selected), and not search for what I entered.
If the Filter could filter the content of column created by script, the PinYin filter and any other languages' filter style will come ture more easy.
This need developers' support.
Turn on Preferences / File Display Modes / Details / Sort-field specific key scrolling. FAYT will then search the current sort column, instead of always searching the Name column.
(This only applies to Find-As-You-Type. The separate Filter Bar always filters by name.)
option explicit
' PY_Find
' (c) 2017 qiuqiu
' This is a script for Directory Opus.
' See http://www.gpsoft.com.au/DScripts/redirect.asp?page=scripts for development information.
' Called by Directory Opus to initialize the script
Function OnInit(initData)
initData.name = "PY_Find"
initData.version = "1.0"
initData.copyright = "(c) 2017 qiuqiu"
' initData.url = "https://resource.dopus.com/viewforum.php?f=35"
initData.desc = "汉字首字母查询"
initData.default_enable = true
initData.min_version = "12.0"
Dim col
Set col = initData.AddColumn
col.name = "PY"
col.method = "OnPY"
col.label = "PY"
col.justify = "left"
col.autogroup = false
End Function
' Implement the PY column
Function OnPY(scriptColData)
scriptColData.Value = getpy(scriptColData.Item.name_stem)
End Function
function getpy(str)
Dim i
for i=1 to len(str)
getpy = getpy & getpychar(mid(str,i,1))
next
end function
Function getpychar(char)
Dim tmp
tmp = 65536 + Asc(char)
If(tmp >= 45217 And tmp <= 45252) Then
getpychar = "a"
ElseIf(tmp >= 45253 And tmp <= 45760) Then
getpychar = "b"
ElseIf(tmp >= 45761 And tmp <= 46317) Then
getpychar = "c"
ElseIf(tmp >= 46318 And tmp <= 46825) Then
getpychar = "d"
ElseIf(tmp >= 46826 And tmp <= 47009) Then
getpychar = "e"
ElseIf(tmp >= 47010 And tmp <= 47296) Then
getpychar = "f"
ElseIf(tmp >= 47297 And tmp <= 47613) Then
getpychar = "g"
ElseIf(tmp >= 47614 And tmp <= 48118) Then
getpychar = "h"
ElseIf(tmp >= 48119 And tmp <= 49061) Then
getpychar = "j"
ElseIf(tmp >= 49062 And tmp <= 49323) Then
getpychar = "k"
ElseIf(tmp >= 49324 And tmp <= 49895) Then
getpychar = "l"
ElseIf(tmp >= 49896 And tmp <= 50370) Then
getpychar = "m"
ElseIf(tmp >= 50371 And tmp <= 50613) Then
getpychar = "n"
ElseIf(tmp >= 50614 And tmp <= 50621) Then
getpychar = "o"
ElseIf(tmp >= 50622 And tmp <= 50905) Then
getpychar = "p"
ElseIf(tmp >= 50906 And tmp <= 51386) Then
getpychar = "q"
ElseIf(tmp >= 51387 And tmp <= 51445) Then
getpychar = "r"
ElseIf(tmp >= 51446 And tmp <= 52217) Then
getpychar = "s"
ElseIf(tmp >= 52218 And tmp <= 52697) Then
getpychar = "t"
ElseIf(tmp >= 52698 And tmp <= 52979) Then
getpychar = "w"
ElseIf(tmp >= 52980 And tmp <= 53640) Then
getpychar = "x"
ElseIf(tmp >= 53689 And tmp <= 54480) Then
getpychar = "y"
ElseIf(tmp >= 54481 And tmp <= 62289) Then
getpychar = "z"
Else '/ / 如果不是中文,则不处理
getpychar = char
End If
End Function
I have already established contact with qiuqiu, he improved the script regulation of change Chinese characters to letters. 拼音首字母.zip (16.5 KB)
After install this script, there will be a column named “拼音首字母”, it change every Chinese character to a letter, and do nothing to the others.
I'm very sorry that my english is pretty bad, but the features below is very very important to Chinese users, if these implemented completely, it's the best answer to this thread: Is there any plugin for Chinese PinYin quick search?
The features we need is:
The Filter could filtering by this new column "拼音首字母";
It could applied to the other mode (Tiles,Thumbnails and so on), not only in details mode.
Of course, if this function is integrated into DOpus itself, and no need to add a additional column is much more better.