selected icon indicating copy to clipboard operation
selected copied to clipboard

PHP variable selection

Open Leo252525 opened this issue 5 years ago • 7 comments

Hey there, I'm having troubles with the variable selection in PHP. I want the plugin to ignore the $ in PHP. So it should only select the "variable" in "$variable".

I excluded the $ in the settings but it still doesn't work for me.

"highlight-selected": allowedCharactersToSelect: "@%-"

Do you have any tips?

Thanks a lot!

Leo252525 avatar Sep 03 '20 07:09 Leo252525

I have the opposite problem. For me I want to include the $, but it's not being selected. The $ is included in the settings.

Also, it is not highlighting other instances in the same file like it used to do.

Note, I am talking about highlighting by double clicking. It works if I highlight by dragging.

jordan-webdev avatar Jan 21 '21 22:01 jordan-webdev

I have the opposite problem. For me I want to include the $, but it's not being selected. The $ is included in the settings.

Also, it is not highlighting other instances in the same file like it used to do.

Note, I am talking about highlighting by double clicking. It works if I highlight by dragging.

Same thing Any solutions?

andriy063 avatar Jan 22 '21 16:01 andriy063

For me I want to include the $, but it's not being selected. The $ is included in the settings.

Same, but only since updating Atom to 1.54.0, prior to that I'd not experienced this issue. Status bar count is still working correctly.

Seems there's two workarounds for this by modifying the non word characters:

  • Remove $ from Settings > Editor > Non Word Characters Or
  • Add $ to Settings > Packages > Language PHP > Non Word Characters

michaelvickersuk avatar Jan 24 '21 09:01 michaelvickersuk

Seems there's two workarounds for this by modifying the non word characters

This still doesn't seem to add the same function as before (i.e.: double click to select+highlight word). Would love to get a solution it's driving me up the wall

hellodaniel avatar Jan 28 '21 08:01 hellodaniel

This still doesn't seem to add the same function as before (i.e.: double click to select+highlight word).

Strange, the workaround fixed the problem for me and the double click now works exactly like it did before.

  editor:
    nonWordCharacters: "/\\()\"':,;<>~!@#%^&*|+=[]{}`?-…"

michaelvickersuk avatar Jan 28 '21 09:01 michaelvickersuk

I don't know what I did wrong but thanks - yes that worked 🙄 idiot me

hellodaniel avatar Jan 28 '21 10:01 hellodaniel

For me I want to include the $, but it's not being selected. The $ is included in the settings.

Same, but only since updating Atom to 1.54.0, prior to that I'd not experienced this issue. Status bar count is still working correctly.

Seems there's two workarounds for this by modifying the non word characters:

  • Remove $ from Settings > Editor > Non Word Characters Or
  • Add $ to Settings > Packages > Language PHP > Non Word Characters

That worked for me as well. Thanks a lot!

Leo252525 avatar Jan 28 '21 11:01 Leo252525