我想在编辑时更改Markdown单元格中的字体类型。 我怎么能这样做?
我可以编辑文件.jupyter/custom/custom.css
并在字体运行时更改字体":
div.text_cell_render {
font-family: 'Linux Libertine O';
font-size: 12pt;
}
答案 0 :(得分:2)
一个简单的可能性是
import java.util.Scanner;
public class word1
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);
System.out.print("enter a line: ");
String p =in.next();
int q= p.length();
int i;
int count=0;
for( i=0; i<q; i++)
{
if( p.charAt(i)==' ')
{
count++;
}
}
System.out.print(count);
}
}
但要注意上面的代码也会改变用于
的字体另请注意,我的简单提案适用于笔记本电脑的笔记本电脑,您必须将线条添加到您要修改的每个笔记本中。相反,如果您有一个from IPython.display import HTML, display
display(HTML('<style>.CodeMirror{font-family:whatever}</style>')
文件,可以在启动期间custom.css
访问它,您可以向其添加jupiter
,以便为您的每个笔记本进行自定义保留使用
有关永久定制的示例,请查看this question中的Joel Ostblom - 简而言之,修改font-family:whatever
并输入
~/.jupyter/custom/custom.css