Enabling IntelliJ's fancy ≠ (not equal to) operator

放肆的年华 提交于 2019-12-20 09:09:04

问题


I witnessed this in the GOTO 2016 • Kotlin - Ready for Production conference by Hadi Hariri.

In some of his code, what would normally look like:

if (x != y) { /* do some stuff */ }

Is being displayed in an elegant style:

if (x ≠ y) { /* do some stuff */ }

Here's a screen-shot from the live coding session:

He's using the regular != operator, the IDEA is taking care of the rest.

I've been playing with my IntelliJ's configuration but couldn't enable this new fancy feature. Any help?

PS. I'm using the latest Ultimate version (2016.3.3).


回答1:


To enable ligatures, go to the Settings → Editor → Colors & Fonts → Font, choose a font that supports ligatures, e.g. FiraCode, Hasklig, Monoid or PragmataPro (the font has to be installed) and select the Enable font ligatures option.

Source: link.

To preview some fonts, including several with ligatures: https://app.programmingfonts.org/



来源:https://stackoverflow.com/questions/41774046/enabling-intellijs-fancy-%e2%89%a0-not-equal-to-operator

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!