Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

auto-sidebar.lua does not respect fountain any more #5

Closed
ralf3u opened this issue Jun 13, 2022 · 12 comments
Closed

auto-sidebar.lua does not respect fountain any more #5

ralf3u opened this issue Jun 13, 2022 · 12 comments

Comments

@ralf3u
Copy link

ralf3u commented Jun 13, 2022

steps to reproduce
just down below the Mardown-line I added this line in auto-sidebar.lua

 ["Fountain"] = show_sidebar,

I saved the document
I restarted Geany

result
there is no sidebar when a fountain-document is in the editor;
to see the Preview I have to press the shortcut "Toggle Sidebar"

expectation
there should be a sidebar when a fountain-document is in the editor

alternative
I tried also this line

 ["FOUNTAIN"] = show_sidebar,

and I tried also to put it just before the HTML-line

remark
last year it was working, I think so

remark that does not belong to this issue
last year the font-color was all in white in the Preview, I think so; but now it is black and white; the black part is too hard to read; I tried to change the color in fountain.css; but it didn't work

@ralf3u
Copy link
Author

ralf3u commented Jun 14, 2022

this does also not work for "Big Fish"

  ["fountain"] = show_sidebar,

@xiota
Copy link
Owner

xiota commented Jun 14, 2022

So this worked before because I used to have a patch in the PPA that added fountain document type. I submitted a PR upstream to include it, but it was ignored. Geany code changed too much, and the patch no longer works without modification. Since there wasn't any interest in adding support for fountain and I don't really feel like maintaining a patch no one cares about, I dropped the patch.

I'll take a look at the Lua script to see if there's a workaround to work with fountain documents.

@ralf3u
Copy link
Author

ralf3u commented Jun 14, 2022

I see some fountain-documents maybe 5 times a year. For this I can use the shortcut to let appear the sidebar. When reporting, I thought that is was just a small issue that could be fixed easily.

@ralf3u
Copy link
Author

ralf3u commented Jun 16, 2022

remark that does not belong to this issue
last year the font-color was all in white in the Preview, I think so; but now it is black and white; the black part is too hard to read; I tried to change the color in fountain.css; but it didn't work

Is there a solution that I could do that the whole text is white again?

@xiota
Copy link
Owner

xiota commented Feb 27, 2023

There is a file with instructions at ~/.config/geany/filedefs/filetypes.README.

Create ~/.config/geany/filedefs/filetype_extensions.conf with contents:

[Extensions]
Fountain=*.ftn;*.fountain;

Then copy /usr/share/geany/filedefs/filetypes.markdown to ~/.config/geany/filedefs/filetypes.Fountain.conf.

@xiota
Copy link
Owner

xiota commented Feb 28, 2023

I tried to change the color in fountain.css; but it didn't work

Is there a solution that I could do that the whole text is white again?

I think that is the correct file to edit. Have you already opened an issue for this at geany-preview?

@ralf3u
Copy link
Author

ralf3u commented Mar 2, 2023

Then copy /usr/share/geany/filedefs/filetypes.markdown to ~/.config/geany/filedefs/filetypes.Fountain.conf.

Are you sure about this line? I ask because there are different formats in the same line.

@xiota
Copy link
Owner

xiota commented Mar 2, 2023

Then copy /usr/share/geany/filedefs/filetypes.markdown to ~/.config/geany/filedefs/filetypes.Fountain.conf.

Are you sure about this line? I ask because there are different formats in the same line.

Using filetypes.markdown as a template for filetypes.Fountain.conf. Otherwise, you would need to create the new file from scratch.

For changes to take effect, close any open fountain files. Then close and restart Geany. Reopen the fountain files.

If you see fountain files with different extensions, you can rename them or add the new extensions to filetype_extensions.conf.

@ralf3u
Copy link
Author

ralf3u commented Mar 2, 2023

I did #5 (comment).
At the moment in my geanylua-file there is only the old version of auto-sidebar. But auto-sidebar still does not respect fountain.

@ralf3u
Copy link
Author

ralf3u commented Mar 2, 2023

Sorry for my last comment. I forgot to do this:
In auto-sidebar.lua I just added this line in the section local action_tbl, like it is mentioned in the report, on top of this webpage:

 ["Fountain"] = show_sidebar,

Now it works.

@ralf3u ralf3u closed this as completed Mar 2, 2023
@xiota
Copy link
Owner

xiota commented Mar 2, 2023

When you get a chance, try the new auto-sidebar. It respects the sidebar state (issue #3) when used with the toggle-sidebar script. It shares some files with switch-views and uses sidebar_restore in action_tbl.

@ralf3u
Copy link
Author

ralf3u commented Mar 2, 2023

When you get a chance, try the new auto-sidebar. ...

Yes, this is what I wanted to do the next days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants