syntax highlighting - In emacs, how to colorize a row in a CSV based on value in a column? -


i have created major-mode emacs use data analysis. mode works great me it's drab , don't take advantage of color way should. data being analyzed in csv format , i'd colorize rows within based on values in columns.

let's have following file in csv format:

one,1,2,3 two,4,5,6 three,7,8,9 

the rows in csv should colored red based on value in 4th column , intensity of red should increase same value. in case last column should intense red , first should least red.

i've read on search based fontification , i'm bit confused how write (matcher . facespec) sets facespec properly. facespec expression evaluates to

(face face prop1 val1 prop2 val2…) 

but how make depend on values in fourth column of csv? guess value in fourth column gets matched how tie face used magnitude of value matched? suppose need generate face on fly based on value matched not sure how so.

any ideas? simple example best.


Comments

Popular posts from this blog

amazon web services - S3 Pre-signed POST validate file type? -

c# - Check Keyboard Input Winforms -