启用"linestyle"八度中Gnuplot的功能? [英] Enable "linestyle" functionality for Gnuplot in Octave?

查看:159
本文介绍了启用"linestyle"八度中Gnuplot的功能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Octave中,存在一个问题,即仅使用gnuplot作为graphics_toolkit时,不会打印出fltk和qt的希腊字母.但是,使用gnuplot时,所有行都是实线,没有虚线. 我找到了一个页面,上面写着可以启用其他线型:

In Octave there is the problem that with fltk and qt greek letters in figures are not printed, only with gnuplot as graphics_toolkit. But then with gnuplot all lines are solid, no dashed lines. I found a page which says that other linestyles can be enabled:

http://wiki.octave.org/Enable_%22linestyle%22_functionality_for_Gnuplot%27s_x11_terminal

我在那行添加到我的〜/.Xdefaults中,并按照这里所说的那样 xrdb -merge .Xdefaults , 但没有成功.

I added the lines there to my ~/.Xdefaults and did xrdb -merge .Xdefaults as said there, but no success.

我正在Ubuntu 16.04上运行octave 4.0.2.

I am running octave 4.0.2 on Ubuntu 16.04.

有任何提示吗?

谢谢

卡尔

推荐答案

看来您暂时无法做到.但是,如果您对解决方法感到满意,那么最好的选择似乎是创建希腊文字的图像并将其用作标题等.

It seems you cannot do it for the time being. But if you're happy for workarounds, your best choice seems to be to create an image of greek text and use that as your title etc.

这是一种方法.转到 codecogs在线乳胶编辑器,并使用其工具在乏味的数学中编写希腊文标题模式:p如果将链接复制到生成的图像,则如果要保存文件,则可以将其直接用于imread(这也使您的代码自动运行,因此可以在脚本中使用,前提是您拥有一个互联网连接.

Here's a way. Go to the codecogs online latex editor and write your greek title using their tool in tedious math mode :p If you copy the link to the resulting image, you can use that straight into imread if you prefer to saving a file (this also makes your code automatic such that it can be used in a script, assuming you have an internet connection.

例如我使用以下数学纹理来生成希腊标题:

e.g. I used the following math tex to generate the greek title:

\Pi\acute\alpha\lambda\iota~\sigma\kappa\alpha\tau\acute\alpha~\tau\alpha~\kappa\acute\alpha\nu\alpha\mu\epsilon~\mu\epsilon~\tau\alpha~E\lambda\lambda\eta\nu\iota\kappa\acute\alpha~\rho\epsilon~\mu\alpha\lambda\acute\alpha\kappa\epsilon\varsigma

,然后使用指向所生成图像的链接(或本地保存)

and then using the link to the resulting image (or saving locally)

>> image  % draw octave logo
>> greektitle = imread('http://latex.codecogs.com/png.latex?%5Cdpi%7B300%7D%20%5Chuge%20%5CPi%5Cacute%5Calpha%5Clambda%5Ciota%7E%5Csigma%5Ckappa%5Calpha%5Ctau%5Cacute%5Calpha%7E%5Ctau%5Calpha%7E%5Ckappa%5Cacute%5Calpha%5Cnu%5Calpha%5Cmu%5Cepsilon%7E%5Cmu%5Cepsilon%7E%5Ctau%5Calpha%7EE%5Clambda%5Clambda%5Ceta%5Cnu%5Ciota%5Ckappa%5Cacute%5Calpha%7E%5Crho%5Cepsilon%7E%5Cmu%5Calpha%5Clambda%5Cacute%5Calpha%5Ckappa%5Cepsilon%5Cvarsigma');
>> greektitle = repmat(greektitle,[1,1,3]); % make rgb so unaffected by colormap
>> axes; imagesc(greektitle); axis equal off; 
>> P=get(gca,'position'); set(gca,'position',[P(1),0.9,P(3),0.1]); % place on top
>> saveas(gcf,'out.png','png')

这篇关于启用"linestyle"八度中Gnuplot的功能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆