**What a crummy email interface GitHub has!!!!!!**
I couldn't understand your questions but this (*&)(*&)(*& strips out images 
from email. I use images so we don't end up going down a terminology rabbit 
hole. Kind of like you asking for a "Geany filetype" without explaining what 
you mean. I've been in IT over 30 years writing software on many platforms and 
given the pictures I provided I had no clue what you were asking. Now I realize 
you never saw the pictures. GitHub really is barbaric.

I'm dealing with relative in hospital. Can check email, but cannot always get 
to GitHub and even if I could would need screen shots from this machine in 
office.

So, from the beginning:  System

![f77-bug-001](https://user-images.githubusercontent.com/1883220/223739389-eeafc24e-cc94-4b80-ba58-4a3d409aaf49.png)

Configured file types
![f77-bug-030](https://user-images.githubusercontent.com/1883220/223740022-77398f02-cbbc-4fd1-8d26-e668be61f799.png)

That was only uncommented with .F77 added __after__ Geany failed to recognize 
.F77 as a Fortran 77 file extension.

.F90 file extension worked out of the box
![f77-bug-003](https://user-images.githubusercontent.com/1883220/223740561-f12f5cf2-f8dd-4c00-ae73-1dc12faa9f56.png)
![f77-bug-032](https://user-images.githubusercontent.com/1883220/223741006-9c50df92-8b84-43a0-9e09-18d4d4df751b.png)

.F77 file extension does not, even with the addition in 
~/.config/geany/filetype_extensions.conf and a restart of Geany
![f77-bug-004](https://user-images.githubusercontent.com/1883220/223741416-c4c3bd22-305c-47c1-83c4-82ef2c952753.png)
![f77-bug-010](https://user-images.githubusercontent.com/1883220/223741456-75e27167-3dca-421b-971a-f785d4a8684d.png)

If I save that exact file with a .f77 file extension Geany likes it.
![f77-bug-033](https://user-images.githubusercontent.com/1883220/223741983-f0368376-7390-49c6-a49c-72d8aaf568cb.png)
![f77-bug-034](https://user-images.githubusercontent.com/1883220/223742015-203e402c-bcd6-42c9-a52b-20eba50ca675.png)

Even if I change the system level file and restart Geany, it does not like 
files with .F77 extension.
![f77-bug-035](https://user-images.githubusercontent.com/1883220/223744938-a1d33f2f-d885-40f7-b037-0075cb323359.png)
![f77-bug-036](https://user-images.githubusercontent.com/1883220/223744971-c6e3d20d-eb5c-4755-83a4-1e23d5ab966f.png)

When I went back in for grins and giggles to my local .conf and added *.F78; 
after the *.F77; then saved, Geany now started liking .F77 files. Didn't have 
to exit at all.

Here is a short .F77 file if you wish to test.

FTN_FILL_IN_LOGICALS.F77
```
        SUBROUTINE FTN_FILL_IN_LOGICALS
        IMPLICIT NONE
C
C       Subroutine to fill in all of the logicals needed by the 
C       Mega_Zillionare application when written in fortran
C

        INCLUDE 'SYS$LIBRARY:FORSYSDEF(LIB$ROUTINES)'

C;;;;;
C       Fill in default file names
C;;;;;
        CHARACTER*12    DRAWING_DATA
        DATA DRAWING_DATA/'MY_MEGA_FILE'/

        CHARACTER*13    DRAWING_STATS
        DATA DRAWING_STATS/'DRAWING_STATS'/

        CHARACTER*10    MEGA_STATS
        DATA MEGA_STATS/'MEGA_STATS'/ 



        CHARACTER*255   TRANSLATED_NAME_STR, WORK_STR
        CHARACTER*1     FIRST_CHAR
        INTEGER*4       L_X
        INTEGER*2       W_X
        LOGICAL         IS_BLANK_LG


C;;;;;
C       Make certain the drawing_data logical exists
C       if not, give it a value in the local directory
C;;;;;
        TRANSLATED_NAME_STR = ' '
        L_X = LIB$GET_LOGICAL( DRAWING_DATA, TRANSLATED_NAME_STR, 
     1          W_X,,,,)


        FIRST_CHAR = TRANSLATED_NAME_STR
        IS_BLANK_LG = FIRST_CHAR .EQ. ' '

        IF (IS_BLANK_LG) THEN
            TRANSLATED_NAME_STR = DRAWING_DATA // '.IDX'
            L_X = LIB$SET_LOGICAL( DRAWING_DATA, 
     1              TRANSLATED_NAME_STR,,,)
        END IF


        TRANSLATED_NAME_STR = ' '
        L_X = LIB$GET_LOGICAL( DRAWING_STATS, TRANSLATED_NAME_STR, 
     1          W_X,,,,)


        IF (TRANSLATED_NAME_STR(1:1) .EQ. ' ') THEN
            TRANSLATED_NAME_STR = DRAWING_STATS // '.IDX'
            L_X = LIB$SET_LOGICAL( DRAWING_STATS, 
     1              TRANSLATED_NAME_STR,,,)
        END IF



        TRANSLATED_NAME_STR = ' '
        L_X = LIB$GET_LOGICAL( MEGA_STATS, TRANSLATED_NAME_STR, 
     1          W_X,,,,)


        FIRST_CHAR = TRANSLATED_NAME_STR

        IF (FIRST_CHAR .EQ. ' ') THEN
            TRANSLATED_NAME_STR = MEGA_STATS // '.IDX'
            L_X = LIB$SET_LOGICAL( MEGA_STATS, 
     1              TRANSLATED_NAME_STR,,,)
        END IF


        RETURN
        END

```

This acts like multiple things are going on.

1. Geany stores whatever syntax it was using and never checks again until a 
"new" .conf requires a reload. Stopping and starting Geany will not "fix" an 
existing opened file. 
2. There is some kind of parsing error for the F77 geany type that doesn't like 
*.F77; if it is the last thing in the line. I mean I tried opening many 
different files after changing both local .conf and system without Geany 
recognizing .F77 as an F77 file.
3. Something else I haven't tracked down.

On the big systems 
*.F is common for Fortran IV or earlier (Yes, lots of that still in production.)
*.FIV for shops that were straddling the change between Fortran IV and Fortran 
77
*.F77 for Fortran 77.
We always used upper case because that is all the early terminals had.

I hope this answers all of the questions.

As a workaround, if these file extensions could just be "functional" in the 
base package the other issues wouldn't surface.





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

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

Reply via email to