Can you please help me to set the function list for a user defined language? I am using fortran for my assignments(economics!) and I defined the fortran 90 format since notepad++ only works with f77. But I really liked the function list! I tried work with the example in the help but it did not work. How would you set the values to define functions and subroutines in fortran. They are quite simple, say:
subroutine ex_sub(x,y)
...
end subroutine ex_sub
cheers,
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
If I pressed the "Try!" button after a rule is added/modified, the Function List function does not honour the rules changes even if they are correct. I had to restart NPP so the rules can take affect.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I have been trying to create parsing rules for my language but without any success. I wonder if anyone can help.
In its simplest form, the language syntax looks like the next 2 lines
keyword_begin function_name ;
keyword_end ;
So I defined the following in the Function List Parsing Rules dialog box via Plugins ->Function List -> User Rules and select my language.
Function Begin: <\keyword_begin\>
Function List Name: [a-zA-Z_]+
Function End: <\;\>
Body End: <\keyword_end ;\>
All other fields are left blank.
When I press the Try! button nothing happens. Please help.
Thanks in advance.
Ok, there are several reasons, but why you don't do some experiments? Try to find with "Find" dialog the first line! However here the correct rules:
Function Begin: \<keyword_begin\>[ \t]+
Function List Name: [a-zA-Z_]+
Function End: [ \t]*;
Body End: \<keyword_end\>[ \t]*;
Regards
Jens
Hi,
Can you please help me to set the function list for a user defined language? I am using fortran for my assignments(economics!) and I defined the fortran 90 format since notepad++ only works with f77. But I really liked the function list! I tried work with the example in the help but it did not work. How would you set the values to define functions and subroutines in fortran. They are quite simple, say:
subroutine ex_sub(x,y)
...
end subroutine ex_sub
cheers,
Hi Jens,
The problem is actually in the "Try!" button.
If I pressed the "Try!" button after a rule is added/modified, the Function List function does not honour the rules changes even if they are correct. I had to restart NPP so the rules can take affect.
Hello,
the parser need the positions of white spaces too. This you should change:
Function Begin: <\keyword_begin\>[ \t]+
Function List Name: [a-zA-Z_]+
Function End: [ \t]*<\;\>
Body End: <\keyword_end\>[ \t];
Best Regards
Jens
Thanks for the tips regarding the "Find" dialog box. Why did I not think of that - lol?
Now I have a working example, I should be ok now.
Thanks again.
Thanks Jens.
Unfortunately, it still does not work. In the Function List panel, it says "No Functions" after I clicked the Try! button.
I forgot to mention, I m using v4.1.2.
Below is the content of InsertExt.ini
[Function List]
Show all functions=1
Sort by names=0
showCmd=0
[User Languages]
Count User Languages=1
Name 1=test
KeyWBodyBeg 1=
KeyWBodyEnd 1=
MatchCase 1=0
Count Comment 1=1
Comment P1.1.1=
Comment P2.1.1=
Count Syntax 1=3
Syntax P1.1.1=<\keyword_begin\>[ \t]+
Syntax P2.1.1=[ \t]*<\;\>
Syntax P3.1.1=[a-zA-Z_]+
Syntax P4.1.1=
Syntax P5.1.1=<\keyword_end\>[ \t];
Syntax P6.1.1=
Syntax P1.2.1=
Syntax P2.2.1=
Syntax P3.2.1=
Syntax P4.2.1=
Syntax P5.2.1=
Syntax P6.2.1=
Syntax P1.3.1=
Syntax P2.3.1=
Syntax P3.3.1=
Syntax P4.3.1=
Syntax P5.3.1=
Syntax P6.3.1=
[HEX-Editor]
Columns=16
Bits=1
Binary=0
Little=0
Capitel=1
Extensions=
Jens,
May be you missed my last post. Your original suggestion did not work. Any idea.
This is a known bug.
Hi,
I don't understand the syntax for the functionlist.
I use a special language for develop funtions in a CAD-system.
It's a procedural language.
Functions an procedures start and end with
#function <any_name>
...
#end
#procedure <any_name>
...
#end
How is the correct syntax for the rule in the functionlist.
Thanks in advance.
Andreas
Germany