Sublime Forum

ST3: BracketHighlighter 2

#81

Thank you very much for the quick reply; saved me from going bonkers!

0 Likes

#82

Thanks for looking into this @r-stein. Since this resolves the issue, I can push this fix in the next BH version.

0 Likes

#83

I’ll go on to mention if you run into issues like this in the future, you can use a tool like ScopeHunter to analyze the scopes to help you isolate a scope to ignore. There are times when you just can’t do it with scopes though, and then you have to get creative with regex adjustments, and sometimes even python hooks (but those are a little more rare).

0 Likes

#84

So I broke BH on the last tag. It’s been fixed, so if you don’t have 2.23.3, you should probably uprade when available.

0 Likes

#85

Hey, I love BH! Two questions:

  • content_highlight_bar is great but can we get a styling option for it? I am using a dark theme and it’s almost white, which is way to aggressive for me. Maybe I missed the setting…

  • Is there a way to highlight pipes? Here is an example. Focus on the %>% operator. Something like the content_highlight_bar would be great for this.

samples <- d %>%
    ungroup() %>%
    transmute(
        test1  = TRUE,
        test2  = 1,
        test4  = 3,
        test4  = "dfgsf") %>%
    filter(test2 ==1)
0 Likes

#86

content_highlight_bar is great but can we get a styling option for it? I am using a dark theme and it’s almost white, which is way to aggressive for me. Maybe I missed the setting…

I think it follows the color of the gutter icons, so if the icons are white, the bar is white. I can see the desire to have it a different color, If you create an issue over at the repo, I can look into it moving forward. It’s always been kind of a novelty feature to me that I don’t really use, but I do no there are people who really like it. It’s a bit limited, but it gets the job done :slight_smile:.

Is there a way to highlight pipes? Here is an example. Focus on the %>% operator. Something like the content_highlight_bar would be great for this.

Not really sure what you mean by “highlight piples”, can you elaborate?

0 Likes

#87

As far as I can see, “pipes” are just a sort of binary operator and do not have a begin and end token, so I don’t really see how this could be relevant to BH, now what should be done. Maybe you can elaborate?

1 Like

#88

Yes, they are binary operators without a begin and end token. But they connect a series of calls that can go over many lines. Below is another example from javascript. Having someone like the content_highlight_bar that indicate from where to where the pipe goes could be useful. But I can see that it doesn’t fit into BH

queue()
    .defer(d3.json, "/geo/nyc-small.json")
    .defer(d3.json, "/geo/nyc-ct.json")
    .defer(d3.json, "/geo/nyc-991.json")
    .await(function(error, nyc, ctData, calls)
0 Likes

#89

When start and end blocks don’t difference and are not contained within a complete scope and the end caps can be checked (thing string scoping), it is hard for BH to pull off.

0 Likes