阳光飞狐

ycng 发表于 2019-8-11 15:56:32

如何在Linux 执行飞狐 (foxtrader)

以win10下载 linuxmint 19.2 cinnamon (本年7月发布), 烧录成安装光碟
Installinglinux mint Cinnamon 19.2 (选简体中文)
Boot光碟后,开始安装前先连结网路
== = = = = = =
SetupDialer :
$sudo pppoeconf
deleteusername and key-in xx电信帐号
key-inpass : *********

== = = = = = =
安装好第一次重新开机载入mintCinnamon 19.2后,先连结网路 (第一次载入只做一次)
SetupDialer :
$sudo pppoeconf
deleteusername and key-inxx电信帐号
key-inpass : *********

== = = = = = =更新
DoUpdate and upgrade :
$sudo apt update
$sudo apt upgrade
== = = =

installchinese language:安装中文语言输入法
install输入法 -- > 选单 -- > 输入法 -- > 安装 (通常用ibus输入法)
-- - - - - - - - - - - - -
设定下列环境配置:
显示器(二台lcd上下合并)
莹幕保护程式(neverturn on screensaver, never lock)
字型选择A(choose 11 for all fonts or use “ctrl + -” to change font size )
面板设定(changepanel size)
系统设定-- - > 面板小程式 -- - > 视窗列表 -- - > ‘+’ key 加入    /   ‘restore’ key 恢复/   ‘-’ key 移除

== = = = = = = =
安装设定中文字形
$sudo mkdir /usr/share/fonts/fireflysung
下载并复制字形档至/usr/share/fonts/fireflysung
Copy/Sp30_A/font/bkai00mp.ttf to //usr/share/fonts/fireflysung
Copy/Sp30_A/font/fireflysung.ttf to //usr/share/fonts/fireflysung
Copy/Sp30_A/font/uming.ttf to //usr/share/fonts/fireflysung
Copy/Sp30_A/font/ukai.ttf to //usr/share/fonts/fireflysung
($nemo)
($sudo nemo) (复制时用sudonemo 升级权限)
档案总管- - >用mouseright click 任一目录 -- > 以根帐号开启,再浏览你所要的目录

-- -打开linuxterminal or ctrl + T
$cd /usr/share/fonts/fireflysung
$sudo chmod 644 bkai00mp.ttf
$sudo chmod 644 fireflysung.ttf
$sudo chmod 644 uming.ttf
$sudo chmod 644 ukai.ttf
$sudo mkfontscale
$sudo mkfontdir
$sudo fc-cache /usr/share/fonts/fireflysung


安装wine4.1 (执行 windows程式)

$ sudo dpkg --add-architecture i386$ wget -nc https://dl.winehq.org/wine-builds/winehq.key && sudo apt-key add winehq.key$ sudo apt-add-repository 'deb https://dl.winehq.org/wine-builds/ubuntu/ bionic main' $ sudo apt-get update$ sudo apt-get install --install-recommends winehq-stable == = = = = = = = =

(安装64bit wine执行容器)

$ export WINEARCH=win64 && export WINEPREFIX="/home/cheng888/.wine464"$ winecfg
$wine64 uninstaller
(解除安装,必要时才做)

安装一些必要的dll,例如在台股要看元大的yeswin盘中看盘软体就须用到windows的framework环境
$winetricks corefontsmfc42 riched20 riched30 dotnet4.0 msxml3 msxml4 vb6run


$winetricks
先选安装应用程式,取消,再选安装dll
打勾corefontsmfc42 riched20 riched30 dotnet4.0 msxml3 msxml4 vb6run 等dll

安装riched20riched30后,飞狐才能正常编辑指标公式
(注意安装
mfc42.dll使安装
64bits mfc42.dll + mfc42u.dll
               到/home/user/.wine464/drive_c/windows\syswow64或/~/.wine464/drive_c/windows\syswow64 )




winecfg会产生 /home/user/.wine464 目录每次电脑开机后, 要执行飞狐(foxtrader)前, 先执行下列命令$ export WINEARCH=win64 && export WINEPREFIX="/home/cheng888/.wine464"因为 wine的default目录是 /home/user/.wine,user= 你的安装用户名

复制/foxtrader目录到/home/user/.wine464/drive_c/foxtrader

执行飞狐前

修改system.reg,user.reg及wine.inf(看后面说明)


执行飞狐
$wine64 explorer /desktop=name,3840x2100 "C:\Foxtrader\FoxTrader.exe"

$wine64 explorer /desktop=name,7500x2100 "C:\Foxtrader\FoxTrader.exe" (两台lcd左右并排)

Linuxwine 是执行 飞狐最好的作业系统,执行时飞狐从不当机,两台43寸 lcd可以完美合并成一台86寸lcd,移动飞狐绘图画面时,速度快速无碍,使用 linux至今还未遇过网路病毒



其中c:\
=   /home/user/.wine464/drive_c


== = = = = = = = =


(安装32bit wine执行容器)

$ export WINEARCH=win32 && export WINEPREFIX="/home/cheng888/.wine432"$ winecfg$winetricks corefontsmfc42 riched20 riched30 dotnet4.0 msxml3 msxml4 vb6run

(注意安装
mfc42.dll是安装
32bits mfc42.dll + mfc42u.dll
               到/home/user/.wine432/drive_c/windows\system32或/~/.wine432/drive_c/windows\system32)


winecfg会产生 /home/user/.wine432 目录每次电脑开机后, 要执行飞狐(foxtrader)前, 先执行下列命令$ export WINEARCH=win32 && export WINEPREFIX="/home/cheng888/.wine432"执行 飞狐前

修改system.reg,user.reg及wine.inf(看后面说明)


执行飞狐

$wine explorer /desktop=name,3840x2100 "C:\Foxtrader\FoxTrader.exe"

其中c:\
=   /home/user/.wine432/drive_c




== = = = = = = = =

修改/home/user/.wine464/drive_c/system.regor /home/user/.wine432/drive_c/system.reg

system.reg

1550447192
#time=1d4c71b02e9fdc6
"Arial"="AR PL KaitiM Big5"
"ArialBaltic,186"="AR PL KaitiM Big5,186"
"ArialCE,238"="AR PL KaitiM Big5,238"
"ArialCYR,204"="AR PL KaitiM Big5,204"
"ArialGreek,161"="AR PL KaitiM Big5,161"
"ArialTUR,162"="AR PL KaitiM Big5,162"
"ArialUnicode MS"="Arial"
"Batang"="NanumMyeongjo"
"CourierNew"="AR PL KaitiM Big5 "
"CourierNew Baltic,186"="AR PL KaitiM Big5,186"
"CourierNew CE,238"="AR PL KaitiM Big5,238"
"CourierNew CYR,204"="AR PL KaitiM Big5,204"
"CourierNew Greek,161"="AR PL KaitiM Big5,161"
"CourierNew TUR,162"="AR PL KaitiM Big5,162"
"Dotum"="NanumGothic"
"FixedSys"="ARPL KaitiM Big5"
"Gulim"="NanumGothic"
"Helv"="ARPL KaitiM Big5"
"Helvetica"="ARPL KaitiM Big5"
"MingLiU"="AR PL KaitiM Big5"
"MSGothic"="VL Gothic Regular"
"MSMincho"="IPAMincho"
"MSPGothic"="VL Gothic Regular"
"MSPMincho"="IPAPMincho"
"MSSans Serif"="AR PL KaitiM Big5"
"MSShell Dlg"="PMingLiU"
"MSShell Dlg 2"="AR PL KaitiM Big5"
"MSUI Gothic"="VL Gothic Regular"
"PMingLiU"="ARPL KaitiM Big5"
"SimSun"="ARPL KaitiM Big5"
"System"="ARPL KaitiM Big5"
"Tahoma"="ARPL KaitiM Big5"
"Times"="ARPL KaitiM Big5"
"TimesNew Roman"="AR PL KaitiM Big5 "
"TimesNew Roman Baltic,186"="Times New Roman,186"
"TimesNew Roman CE,238"="Times New Roman,238"
"TimesNew Roman CYR,204"="Times New Roman,204"
"TimesNew Roman Greek,161"="Times New Roman,161"
"TimesNew Roman TUR,162"="Times New Roman,162"
"TmsRmn"="MingLiU"

其中把 "AR PL KaitiM Big5 " 改成你自己的简体字型



以根帐号开启档案总管
/opt/wine-stable/share/wine/wine.inf
属性改为你的帐号名所拥有

以文字编辑器编辑
/opt/wine-stable/share/wine/wine.inf
加入


HKLM,%FontSubStr%,"ArialBaltic,186",,"AR PL KaitiM Big5,186"
HKLM,%FontSubStr%,"ArialCE,238",,"AR PL KaitiM Big5,238"
HKLM,%FontSubStr%,"ArialCYR,204",,"AR PL KaitiM Big5,204"
HKLM,%FontSubStr%,"ArialGreek,161",,"AR PL KaitiM Big5,161"
HKLM,%FontSubStr%,"ArialTUR,162",,"AR PL KaitiM Big5,162"
HKLM,%FontSubStr%,"CourierNew Baltic,186",,"AR PL KaitiM Big5,186"
HKLM,%FontSubStr%,"CourierNew CE,238",,"AR PL KaitiM Big5,238"
HKLM,%FontSubStr%,"CourierNew CYR,204",,"AR PL KaitiM Big5,204"
HKLM,%FontSubStr%,"CourierNew Greek,161",,"AR PL KaitiM Big5,161"
HKLM,%FontSubStr%,"CourierNew TUR,162",,"AR PL KaitiM Big5,162"
HKLM,%FontSubStr%,"Helv",,"ARPL KaitiM Big5"
HKLM,%FontSubStr%,"Helvetica",,"ARPL KaitiM Big5"
HKLM,%FontSubStr%,"MSShell Dlg 2",,"AR PL KaitiM Big5"
HKLM,%FontSubStr%,"Times",,"ARPL KaitiM Big5"
HKLM,%FontSubStr%,"TimesNew Roman Baltic,186",,"Times New Roman,186"
HKLM,%FontSubStr%,"TimesNew Roman CE,238",,"Times New Roman,238"
HKLM,%FontSubStr%,"TimesNew Roman CYR,204",,"Times New Roman,204"
HKLM,%FontSubStr%,"TimesNew Roman Greek,161",,"Times New Roman,161"
HKLM,%FontSubStr%,"TimesNew Roman TUR,162",,"Times New Roman,162"
HKLM,System\CurrentControlSet\HardwareProfiles\Current\Software\Fonts,"LogPixels",0x10003,0x00000075
HKCU,Software\Wine\Fonts\Replacements,"SimSun",,"ARPL KaitiM Big5"
HKCU,Software\Wine\Fonts\Replacements,"PMingLiU",,"ARPL KaitiM Big5"
HKCU,Software\Wine\Fonts\Replacements,"MSGothic",,"VL Gothic Regular"
HKCU,Software\Wine\Fonts\Replacements,"MSPGothic",,"VL Gothic Regular"
HKCU,Software\Wine\Fonts\Replacements,"MSUI Gothic",,"VL Gothic Regular"
HKCU,Software\Wine\Fonts\Replacements,"MSMincho",,"IPAMincho"
HKCU,Software\Wine\Fonts\Replacements,"MSPMincho",,"IPAPMincho"
HKCU,Software\Wine\Fonts\Replacements,"Batang",,"NanumMyeongjo"
HKCU,Software\Wine\Fonts\Replacements,"Dotum",,"NanumGothic"
HKCU,Software\Wine\Fonts\Replacements,"Gulim",,"NanumGothic"
HKCU,Software\Wine\Fonts\Replacements,"ArialUnicode MS",,"Arial"

其中把 "AR PL KaitiM Big5 " 改成你自己的简体字型


修改/home/user/.wine464/drive_c/user.regor /home/user/.wine432/drive_c/user.reg


1525328915
#time=1d3e2a7f72a82ce
"Codepages"="950,950"
"LogPixels"=dword:00000075

("LogPixels"=dword:00000060- - - > "LogPixels"=dword:00000075)


注意:!!!!!!!!!!!!!!!!!!!!!

修改system.reg,user.reg及wine.inf后,重新开机才生效


另外,飞狐最强的地方是他的参数表,比较一些国外软件如amibroker,metastock等, 没发现有软件能像飞狐参数表那强,我只要改变波浪数字参数位就可以改变画图位置,图例若用国外软件便做不到














[ 本帖最后由 ycng 于 2019-8-11 15:58 编辑 ]
页: [1]
查看完整版本: 如何在Linux 执行飞狐 (foxtrader)