Re: [Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread elextr
@etkaar also just noticed you made the changes in master, not in a branch, when 
you update can you please make the changes in a branch, that way committers can 
switch back from your changes to master or another set of changes easily.

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

Re: [Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread elextr
Seems there may have been a misunderstanding, I was saying that there needs to 
be an option if the search is automatically updated on selection, not if it 
requires user action like pressing ctrl-f.

The name of the option `always_set_from_selected` suggested it was automatic, 
but having had a chance to look at the PR code it appears to only happen on 
ctrl-f (or whatever the search shortcut is set to).  

If @etkaar confirms thats the case then I agree with @codebrainz it doesn't 
need an option, just mentioning in the manual.

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

Re: [Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread elextr
> IMO, leave it to the person willing to make the PR, it can always be moved 
> later if it turns out people are using it a lot for some reason or having 
> trouble finding it.

Sure, but if we don't ask we don't know if the OP is happy to do it.

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

Re: [Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread Matthew Brush
> We are very much trying to not dump things in various...

For what it's worth, this is not shared by _all_ core developers; personally I 
feel that the Preferences dialog already has loads of options and that it's 
better for preferences that are obscure or rarely used to be dumped into the 
`Various` preferences tab. In any case, I don't feel strongly, I just mention 
so it's clear this is not some kind of agreed upon policy. IMO, leave it to the 
person willing to make the PR, it can always be moved later if it turns out 
people are using it a lot for some reason or having trouble finding it.


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

Re: [Github-comments] [geany/geany] Confusing meaning of the Auto-indent modes (#2696)

2020-12-20 Thread elextr
Totally agree the names are not great, but so far nobody has a better 
suggestion that they PR.  I don't apologise for requiring the users to lookup 
the manual, its not realistic to expect a name short enough to fit on dialogs 
to do that.

I don't personally think `Block` and `Block with brace alignment` actually do 
any better, and "brace alignment" is misleading since it aligns to the indent 
of the line not of the brace, and in fact its "Block" that actually aligns 
braces if its used as intended (but that alignment is not enforced).

Maybe we should call them `Mode 1`, `Mode 2`, and `Mode 3` with a note to look 
at the manual for what they mean, at least nobody can then try to glean 
functionality from the name :grin:



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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread elextr
As I said above `The order is that of an internal filetype list` which is not 
in `filetype.extensions` order.

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread abdulbadii
it's bit buggy
even after move Sh line to precede *rc then it'd resist to work unless clear 
that *rc

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

[Github-comments] [geany/geany] Confusing meaning of the Auto-indent modes (#2696)

2020-12-20 Thread nomadbyte
I was trying to make sense of the Geany's Auto-indent modes {Basic, Current 
chars, Match braces}, as listed in Preferences>Indentation:Auto-indent mode.

It's absolutely not clear [to me] from the names what these modes do and how 
they differ. Trying them out in practice still shows little difference between 
the "Current chars" and "Match braces" modes.

Geany's doc on 
[auto-indentation](../blob/d2740f21feb84b6f951398c6f683674b2b56bfed/doc/geany.txt#auto-indentation)
 spell out the distinction more clearly. But that's a stretch to expect users 
to look this up in the docs.
> **Basic**
>Adds the same amount of whitespace on a new line as on the previous line. 
> For the Tabs and the Spaces indent types the indentation will use the same 
> combination of characters as the previous line. The Tabs and Spaces 
> indentation type converts as explained above.
> **Current chars**
>Does the same as Basic but also indents a new line after an opening brace 
> '{', and de-indents when typing a closing brace '}'.  For Python, a new line 
> will be indented after typing ':' at the end of the previous line.
> **Match braces**
>Similar to Current chars but the closing brace will be aligned to match 
> the indentation of the line with the opening brace. This requires the 
> filetype to be one where Geany knows that the Scintilla lexer understands 
> matching braces (C, C++, D, HTML, Pascal, Bash, Perl, TCL).

I wonder if these auto-indent modes could be renamed to something more 
forthcoming about the actual mode of the operation?

My suggestion for the choices of Auto-indent mode:
- Current chars => **Block**
- Match braces => **Block with brace alignment**

Perhaps there are better alternatives for these which would communicate this 
more clearly to the user. 

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

Re: [Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread elextr
We are very much trying to not dump things in `various`, so if its a preference 
it should be in a normal part of the preferences, probably `editor->features` 
which has plenty of room.

Don't make a new PR, just push changes to this one.

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread elextr
Yup `.bashrc` matches conf's `*rc` pattern and that happens to be found before 
shell. (The order is that of an internal filetype list)

If more than one pattern matches its undetermined which will be found.

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread abdulbadii
after reset bar; filetype: conf
![Screen 
bashrc](https://user-images.githubusercontent.com/25836673/102726260-d3cf7d00-434f-11eb-9fbf-ae633a15a3a2.png)


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

Re: [Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread Edgar
> Where is the preference set? It should be on the find dialog not just read 
> from the config file.

Since I don't think there is a need to often turn on/off this preference, I 
don't think we should extend the search/replace dialog with this setting, so I 
choosed the way of making it a hidden preference. It can be found and easily 
toggled at _Edit > Preferences > Various_, so there is no need to manually edit 
any config files.

> There has been no discussion about it applying to replace.

I don't think users which want to use this preference want a different 
behaviour between search/replace, so the setting applies to both of them. 
However, it would be no problem to make two hidden preferences if needed.

> Needs to be documented in the manual (no it can't be left, it will be 
> forgotten, answering your question from #2693).

Okay, then I will create a new PL with the second commit which updates the 
manual.

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread Matthew Brush
Add code block around above paste and removed `\` from in front of the comment 
lines. Probably better to paste your exact file in between the `ini` code block 
I added.

To me it looks like it's detecting as shell script (though can't be sure, as 
@elextr said, your screenshots don't show the statusbar where it tells the file 
type). I suspect that probably your complex Bash script is tripping up the 
simplistic shell script lexer, though will need to see the status bar to be 
sure.

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread abdulbadii
NOT ME
MARKDOWN MAKE IT MISSING

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

Re: [Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread elextr
Where is the preference set? It should be on the `find` dialog not just read 
from the config file.  

There has been no discussion about it applying to replace.

Needs to be documented in the manual (no it can't be left, it will be 
forgotten, answering your question from #2693).

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

Re: [Github-comments] [geany/geany] Search for selected text when pressing [Ctrl]+[F] (#2693)

2020-12-20 Thread Edgar
I created a pull request now, see #2695. Is it okay if I do another PL for the 
manual later?

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

[Github-comments] [geany/geany] Adds hidden preference 'always_set_from_selected' (default: FALSE) [...] (#2695)

2020-12-20 Thread Edgar
See issue #2693.

Adds hidden preference always_set_from_selected (default: FALSE) 
which updates search phrase with selected text when search/replace dialog is 
reopened. Default behaviour is not changed.
You can view, comment on, or merge this pull request online at:

  https://github.com/geany/geany/pull/2695

-- Commit Summary --

  * Adds hidden preference always_set_from_selected (default: FALSE) 
which updates search phrase with selected text when search/replace dialog is 
reopened.

-- File Changes --

M src/keyfile.c (2)
M src/search.c (9)
M src/search.h (1)

-- Patch Links --

https://github.com/geany/geany/pull/2695.patch
https://github.com/geany/geany/pull/2695.diff

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


Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread elextr
Your `filetype_extensions.conf` is missing all the `*`s.



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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread abdulbadii
![Screen 
bashrc](https://user-images.githubusercontent.com/25836673/102716242-318ea580-430d-11eb-8d62-57d4abb5fc82.png)
![Screen 
sh](https://user-images.githubusercontent.com/25836673/102716256-4703cf80-430d-11eb-9240-a5012ed7623e.png)

On **MX debian**
`filetype_extensions.conf`
# Filetype extension configuration file for Geany
# Insert as many items as you want, separate them with a ";".
# See Geany's main documentation for details.
[Extensions]
Abaqus=*.inp;
Abc=*.abc;*.abp;
ActionScript=*.as;
Ada=*.adb;*.ads;
Arduino=*.ino;*.pde;
Asciidoc=*.asciidoc;*.adoc;
ASM=*.asm;*.asm51;*.a51;*.s;*.S;*.sx;
Batch=*.bat;*.cmd;*.nt;
CAML=*.ml;*.mli;
C=*.c;*.xpm;
C++=*.cpp;*.cxx;*.c++;*.cc;*.h;*.hpp;*.hxx;*.h++;*.hh;*.C;*.H;
Clojure=*.clj;*.cljs;*.cljc;
CUDA=*.cu;*.cuh;*.h;
C#=*.cs;
CMake=CMakeLists.txt;*.cmake;*.ctest;
COBOL=*.cob;*.cpy;*.cbl;*.cobol;
CoffeeScript=*.coffee;Cakefile;*.Cakefile;*.coffee.erb;*.iced;*.iced.erb;
Conf=*.conf;*.ini;config;*rc;*.cfg;*.desktop;*.properties;control;
CSS=*.css;
Cython=*.pyx;*.pxd;*.pxi;
D=*.d;*.di;
Diff=*.diff;*.patch;*.rej;*.debdiff;*.dpatch;
Docbook=*.docbook;
Erlang=*.erl;*.hrl;
F77=*.f;*.for;*.ftn;*.f77;*.F;*.FOR;*.FTN;*.fpp;*.FPP;
Ferite=*.fe;
Forth=*.fs;*.fth;
Fortran=*.f90;*.f95;*.f03;*.f08;*.F90;*.F95;*.F03;*.F08;
FreeBasic=*.bas;*.bi;*.vbs;
Genie=*.gs;
GLSL=*.glsl;*.frag;*.vert;
Go=*.go;
Graphviz=*.gv;*.dot;
Haskell=*.hs;*.lhs;*.hs-boot;*.lhs-boot;
Haxe=*.hx;
HTML=*.htm;*.html;*.shtml;*.hta;*.htd;*.htt;*.cfm;*.tpl;
Java=*.java;*.jsp;
Javascript=*.js;
JSON=*.json;
LaTeX=*.tex;*.sty;*.idx;*.ltx;*.latex;*.aux;*.bib;
Lisp=*.lisp;
Lua=*.lua;
Make=*.mak;*.mk;GNUmakefile;makefile;Makefile;makefile.*;Makefile.*;
Markdown=*.mdml;*.markdown;*.md;*.mkd;*.mkdn;*.mdwn;*.mdown;*.mdtxt;*.mdtext;
Matlab/Octave=*.m;
NSIS=*.nsi;*.nsh;
Objective-C=*.m;*.mm;*.h;
Pascal=*.pas;*.pp;*.inc;*.dpr;*.dpk;
Perl=*.pl;*.perl;*.pm;*.agi;*.pod;
PHP=*.php;*.php3;*.php4;*.php5;*.phtml;
Po=*.po;*.pot;
Python=*.py;*.pyw;SConstruct;SConscript;wscript;
PowerShell=*.ps1;*.psm1;
reStructuredText=*.rest;*.reST;*.rst;
R=*.R;*.r;
Rust=*.rs;
Ruby=*.rb;*.rhtml;*.ruby;*.gemspec;Gemfile;rakefile;Rakefile;
Scala=*.scala;*.scl;
Sh=*.sh;configure;configure.in;configure.in.in;configure.ac;*.ksh;*.mksh;*.zsh;*.ash;*.bash;.bashrc;bash.bashrc;.bash_*;bash_*;*.m4;PKGBUILD;*profile;
SQL=*.sql;
Tcl=*.tcl;*.tk;*.wish;*.exp;
Txt2tags=*.t2t;
Vala=*.vala;*.vapi;
Verilog=*.v;
VHDL=*.vhd;*.vhdl;
XML=*.xml;*.sgml;*.xsl;*.xslt;*.xsd;*.xhtml;*.xul;*.dtd;*.xtpl;*.mml;*.mathml;
YAML=*.yaml;*.yml;
Zephir=*.zep;
None=*;

# Note: restarting is required after editing groups
[Groups]
Programming=Arduino;Clojure;CUDA;Cython;Genie;Scala;
Script=Graphviz;
Markup=
Misc=JSON;
None=

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread Frank Lanitz
Not sure whether your distri did patch that file or some local configuration is 
conflicting... .bashrc should already be recognized as Sh -- 
https://github.com/geany/geany/blob/master/data/filetype_extensions.conf#L67 -- 
and this is working at least here. Would you mind double checking?


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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread abdulbadii
not work, even after make it up one in `~/.config/geany` (previously nothing 
there a `filetype_extensions.conf`)

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread elextr
`Menu->tools->Configuration Files->filetype_extensions.conf`

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread abdulbadii
Apologize, I've been using it of debian mainstream so won't work as there's no 
such file from debian
Any idea how to a simplest solution?

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

Re: [Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread Matthew Brush
This is the default behaviour so it should work automatically, [see 
here](https://github.com/geany/geany/blob/d2740f21feb84b6f951398c6f683674b2b56bfed/data/filetype_extensions.conf#L67).
 Documentation [is 
here](https://www.geany.org/manual/current/index.html#filetype-extensions)

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

[Github-comments] [geany/geany] How to have a filename extension recognized as another (#2694)

2020-12-20 Thread abdulbadii
How to have a filename extension recognized as another, real case requires: 
.bashrc must be recognized/treated as .sh filename extension
thanks before

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