luckakrausova created an issue (geany/geany#4629)

```
geany 2.0 (built on 2024-03-31 with GTK 3.24.41, GLib 2.80.0)
```

I've been trying to customize filedefs for languages that I use and stumbled 
upon an issue with Python. Long story short, `filedefs/filetypes.python` by 
default contains these keywords:
```
[keywords]
primary=False None True _ and as assert async await break case class continue 
def del elif else except finally for from global if import in is lambda match 
nonlocal not or pass raise return try while with yield
identifiers=...
```

Syntax highlighting works as expected (`primary` keywords are purple, 
`identifiers` are blue, classes are cyan, functions are yellow):
<img width="244" height="151" alt="Image" 
src="https://github.com/user-attachments/assets/baa92de6-06bb-4801-a0e4-74922b61e82b";
 />

But if I remove the `class` or `def` keywords from `primary` (and put them into 
`identifiers`), the syntax highlighter stops highlighting any class (or 
function) names at all:
<img width="244" height="151" alt="Image" 
src="https://github.com/user-attachments/assets/063cda6a-b1e1-434e-9985-d6504273f010";
 />
<img width="244" height="151" alt="Image" 
src="https://github.com/user-attachments/assets/537d71c7-84a2-4fe5-84d0-f43af57d92dd";
 />

So far this appears to be only an issue with Python, on C++ this does not occur.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/4629
You are receiving this because you are subscribed to this thread.

Message ID: <geany/geany/issues/[email protected]>

Reply via email to