Re: Keep Editor Open When Closing Last Open File

2018-03-12 Thread Edward K. Ream
On Mon, Mar 12, 2018 at 8:56 PM, Chris George  wrote:

> Is there a setting for this?
>

​No, not yet.  What do you propose should happen?

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Windows defender is flagging LeoApp.exe as carrying a trojan

2018-03-12 Thread ne1uno
red-lang is having some of the same false positives as python exe packagers
not every AV program is tripped up. 
something as simple as calling up the commandline using the win32 api can do 
it. 

it's likely some huristic as Terry says 
so companies are loathe to change scan results even when presented with 
evidence.

this is something that the language foundation and developers have to respond 
to.
users and random people complaining won't change anything.
changing hosting obviously won't change anything

need a button to press to get details on the OS, the version of AV and Leo 
package
to simplify making a bug report and don't forget, 
most people just move on to the next editor they wanted to try on the list
or revert to an earlier version


via Matt Wilkie
 """I've read that downloads from SourceForge often have this problem, any SF 
project not just Leo. It's got something to do with a feature that SF has for 
creating easy installers automatically, """

the company at the time that bought out sourceforge offered an opt in program 
so it was mostly the developers themselves
or their lack of attention to detail that got them repackaged

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Windows defender is flagging LeoApp.exe as carrying a trojan

2018-03-12 Thread ne1uno
I think the included adware problem is an old one. if so, little unfair to 
bring it up again
anything more recent?
sourceforge is under new management

a simple way to verify is publish a hash for any executable
it's extremely unlikely they are repackaging your exe or tampering with Leo in 
any way
it could hardly be kept a secret very long these days though websites are 
hacked all the time
so even a hash published is not 100% foolproof


from the link, QQQ
Update: Since the writing of this article, SourceForge has been sold to a new 
company that stopped the DevShare program discussed in this article. We’re 
leaving this article here for historical reference, but it has since stopped 
these shady practices.
QQQ


*none the less, I have heard others who will never use soureforge since then.
it might be a good idea to distribute alternatively on github in a distribution 
branch or repo

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Keep Editor Open When Closing Last Open File

2018-03-12 Thread Chris George
Is there a setting for this?

Chris

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: LaTex to PDF workflow using Leo

2018-03-12 Thread Edward K. Ream
On Mon, Mar 12, 2018 at 5:44 PM, Arjan  wrote:

> Thanks, Edward!
>

​You're welcome.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: LaTex to PDF workflow using Leo

2018-03-12 Thread Arjan
Thanks, Edward!

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: 75b9c9: New Themes menu

2018-03-12 Thread Edward K. Ream
On Mon, Mar 12, 2018 at 3:12 PM, Terry Brown  wrote:


> > This top-level menu has two items: Apply Theme and Open Theme File.
>
> Just tried this in 134975148a78.  Very nice work.


​Thanks
​


> Only nit was that it
> ​ ​
> didn't start in leo\themes, I had to navigate there, and had to
> navigate back again even after loading a theme from there.
> ​
>

​Strange. Not what I intended.  I'll fix it next.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Windows defender is flagging LeoApp.exe as carrying a trojan

2018-03-12 Thread Edward K. Ream
On Mon, Mar 12, 2018 at 3:26 PM, Matt Wilkie  wrote:

> I tried again on a brand new machine and install of windows and still
>> LeoApp.exe gets flagged by WIndows Defender (Windows 10). The 5.7final
>> archive was downloaded from SourceForge and i think I will stay away from
>> SourceForge
>>
>
> I've read that downloads from SourceForge often have this problem, any SF
> project not just Leo. It's got something to do with a feature that SF has
> for creating easy installers automatically, and bundling in advertising
> that shows during the installation process. The project is supposed to to
> have to specifically take advantage of the feature, but some shady
> behaviour in the past indicates maybe that's not always the case:
>

​This is reason enough to drop SourceForge.  We could call it good timing
;-)

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Python 2?

2018-03-12 Thread David Szent-Györgyi


On Sunday, March 11, 2018 at 7:19:24 PM UTC-4, Edward K. Ream wrote:
>
> I have just created #800: Replace pickle with json everywhere in Leo 
> . 
>
> Imo, this is a high priority item.  It should have been done long ago.  
> Terry, do you agree?
>
> I switch frequently, and see this a lot.
>
>
> ​Interesting.  I never see this.  It's fallen off my radar.
>

There may be a better option than JSON. I recall a blog posting about the 
limitations of JSON that are overcome by AXON 
. The 
posting states that unlike JSON, AXON supports comments, provides syntax 
for decimal and date/time values, and supports streams of values. 

The Pypi package pyaxon  runs on 
Python 2.7, 3.3, 3.4, 3.5. Source code is available on GitHub 
. 

In case the original blog posting is not available, it is quoted 
extensively in a tuicool posting . 

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Windows defender is flagging LeoApp.exe as carrying a trojan

2018-03-12 Thread Terry Brown
On Mon, 12 Mar 2018 13:40:06 -0700 (PDT)
Matt Wilkie  wrote:

> > I've read that downloads from SourceForge often have this problem,
> > any SF project not just Leo. It's got something to do with a
> > feature that SF has for creating easy installers automatically, and
> > bundling in advertising that shows during the installation process.
> > The project is supposed to to have to specifically take advantage
> > of the feature, but some shady behaviour in the past indicates
> > maybe that's not always the case:
> >
> > https://www.howtogeek.com/218764/warning-don%E2%80%99t-download-software-from-sourceforge-if-you-can-help-it/
> 
> Reading on, I see  that SF changed ownership in 2016 and immediately 
> stopped the shady DevShare program:
> https://sourceforge.net/blog/sourceforge-acquisition-and-future-plans/
> So maybe it's less a matter of the AV being pro-active and more of
> being slow to re-trust (understandably!).

False positives aren't uncommon with open source software either.  My
work anti-virus whines about things just because they're "not commonly
executed".  Some of the heuristics / finger prints the antivirus
software uses are I think too broad, but not a problem for 99% of users
who only use Word and Excel.

Cheers -Terry

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Windows defender is flagging LeoApp.exe as carrying a trojan

2018-03-12 Thread Matt Wilkie


> I've read that downloads from SourceForge often have this problem, any SF 
> project not just Leo. It's got something to do with a feature that SF has 
> for creating easy installers automatically, and bundling in advertising 
> that shows during the installation process. The project is supposed to to 
> have to specifically take advantage of the feature, but some shady 
> behaviour in the past indicates maybe that's not always the case:
>
>
> https://www.howtogeek.com/218764/warning-don%E2%80%99t-download-software-from-sourceforge-if-you-can-help-it/
>

Reading on, I see  that SF changed ownership in 2016 and immediately 
stopped the shady DevShare program:
https://sourceforge.net/blog/sourceforge-acquisition-and-future-plans/
So maybe it's less a matter of the AV being pro-active and more of being 
slow to re-trust (understandably!).

matt

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Windows defender is flagging LeoApp.exe as carrying a trojan

2018-03-12 Thread Matt Wilkie

>
> I tried again on a brand new machine and install of windows and still 
> LeoApp.exe gets flagged by WIndows Defender (Windows 10). The 5.7final 
> archive was downloaded from SourceForge and i think I will stay away from 
> SourceForge
>

I've read that downloads from SourceForge often have this problem, any SF 
project not just Leo. It's got something to do with a feature that SF has 
for creating easy installers automatically, and bundling in advertising 
that shows during the installation process. The project is supposed to to 
have to specifically take advantage of the feature, but some shady 
behaviour in the past indicates maybe that's not always the case:

https://www.howtogeek.com/218764/warning-don%E2%80%99t-download-software-from-sourceforge-if-you-can-help-it/

matt

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: 75b9c9: New Themes menu

2018-03-12 Thread Terry Brown
On Mon, 12 Mar 2018 04:00:37 -0700 (PDT)
"Edward K. Ream"  wrote:

> This top-level menu has two items: Apply Theme and Open Theme File.
> 
> Both commands prompt for a theme file, starting in leo\themes, then

Just tried this in 134975148a78.  Very nice work.  Only nit was that it
didn't start in leo\themes, I had to navigate there, and had to
navigate back again even after loading a theme from there.

Cheers -Terry

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: The design of Leo+Ipython+Jupyter+Lit-computing

2018-03-12 Thread Thomas Passin
Looks like it works pretty much as expected, if you know the right classes 
to use.  I inserted  a QML view into a regular PyQt container, no problem.  
The view was a QDeclarativeView imported from PyQt4.QtDeclarative.  I don't 
know if they have all the widgets we'd want to use as QDeclaratives ...

On Saturday, March 10, 2018 at 9:46:12 PM UTC-5, Thomas Passin wrote:
>
> Do you happen to know if it's feasible to use QML widgets in Leo?  
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Windows defender is flagging LeoApp.exe as carrying a trojan

2018-03-12 Thread Satish Goda
I tried again on a brand new machine and install of windows and still 
LeoApp.exe gets flagged by WIndows Defender (Windows 10). The 5.7final 
archive was downloaded from SourceForge and i think I will stay away from 
SourceForge

Will have to use an older version of Leo which does not have this issue.

On Friday, March 9, 2018 at 2:13:02 AM UTC-8, Edward K. Ream wrote:
>
>
>
> On Fri, Mar 9, 2018 at 1:52 AM, Satish Goda  > wrote:
>
>> I just downloaded 5.7 final from Source Forge
>>
>> https://sourceforge.net/projects/leo/files/Leo/5.7-final/Leo_5.7_final_Win.zip/download
>>  
>> 
>>
>>
>> After extracting and running LeoApp.exe, I see a warning from Window 
>> defender (I am using Windows 10 and I have virus scanning enables for 
>> ages). Did anybody else notice this? 
>>
>
> ​I haven't.​
>  
>
>>
>> 5.7b2 runs fine and I downloaded it from Source forge last month.
>>
>
> ​I wouldn't ignore this warning.  It may say something about your machine.
>
> Edward
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Gitlab

2018-03-12 Thread Kent Tenney
discussion of features and Github comparison starts at 11:45

Great feature set, seems like a good community. I've installed
locally for use with my code, so far so good.

Interesting stuff, not saying Leo wants to migrate.

On Sun, Mar 11, 2018 at 7:57 PM, Edward K. Ream  wrote:

>
>
> On Tue, Mar 6, 2018 at 4:25 PM, Kent Tenney  wrote:
>
>> I see references to gitlab, never knew it's story.
>>
>> Here is an interview with it's creator, it's quite compelling stuff
>> https://twit.tv/shows/floss-weekly/episodes/473
>>
>> As advertised, it's dead simple to install locally and play with.
>>
>
> ​Well, I gave up after 10 minutes of chat about sick people and pianos,
> and then the host starts to read from a web page.  You have more patience
> than I.
>
> Can you summarize why we would want to migrate from github?
>
> Edward
>
> --
> You received this message because you are subscribed to the Google Groups
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to leo-editor+unsubscr...@googlegroups.com.
> To post to this group, send email to leo-editor@googlegroups.com.
> Visit this group at https://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: ENB: Simple design principles for style sheets

2018-03-12 Thread Edward K. Ream
On Monday, March 12, 2018 at 11:52:05 AM UTC-5, Chris George wrote:
>
> That works, except the file test.leo loads the theme supplied by 
> myLeoSettings.leo instead of the theme contained in the file I am currently 
> working in. eg. Breeze Light Theme - KDE Plasma.leo.
>

Adding support for --theme= command-line would simplify 
your script without resorting to gymnastics.

It's on the list.  I'll push it up.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: First draft of a colorizing guide

2018-03-12 Thread Edward K. Ream

On Monday, March 12, 2018 at 11:59:44 AM UTC-5, Edward K. Ream wrote:

Paste the following in any node to see Python colorizing. It will look 
> different from the github colors below ;-)
>
> frobnicate() # Function calls are not specially colored.
>

To be clear, I have changed this as follows:

frobnicate()
# Function calls are not specially colored.
# The default is the text foreground color in the body pane.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


First draft of a colorizing guide

2018-03-12 Thread Edward K. Ream
Paste the following in any node to see Python colorizing. It will look 
different from the github colors below ;-)

@ A doc part.  *All* languages colorize doc parts as follows:

1. The '@' sign itself is colored with @color leokeyword constant.

2. The rest of the doc parts depends on the @bool color-doc-parts-as-rest 
setting:
   True:  Colorize the doc part as **markdown**.
   False: Colorize the doc part using @color docpart.
   
Leo colorizes constructs with two kinds of color constants.
- **Default colors** defined in the node "Colors: defaults".
  These constants correspond to jEdit names used in leo/modes/*.py.
  See the "Colors: defaults" node for more details.
- **Leo-specific colors**, defined in the node "Colors: Leo constructs".
  
Most languages use only a subset of these color names.
Here are all the colors used to color python:
@c # @color leo_keyword_color

# Comments: @color comment1

def spam():

# Reserved words...
pass # Python keywords: @color keyword1
abs(1)   # Standard functions: @color keyword2.
__file__ # double underscore names: @color keyword3
try:
frobnicate() # Function calls are not specially colored.
except IOError: # Exception names: @color keyword3
pass
a = 2# Operators (the = sign): @color operator_color

# Strings...
a = 'Regular string' # @color literal1
'''Triple single-quoted docstring''' # @color literal2
"""Triple double-quoted docstring""" # @color literal2

# All languages use the following names...

# Urls: http://leoeditor.com/  @color url_color
<< undefined section >>  # @color undefined_section_name_color
<< defined section >>
# The brackets:@color section_name_brackets_color
# The section name itself: @color section_name_color

@language python # @color leo_keyword_color

Please report any missing items.  Python is a good start, but other 
templates might be useful.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: ENB: Simple design principles for style sheets

2018-03-12 Thread Chris George
That works, except the file test.leo loads the theme supplied by 
myLeoSettings.leo instead of the theme contained in the file I am currently 
working in. eg. Breeze Light Theme - KDE Plasma.leo.

I started out developing *in* myLeoSettings.leo but the new standalone file 
makes far more sense than continuing to do that.

Ultimately I am looking for a way to close and open the current file.

Then the script could simply reload-style-sheets, close current file, open 
current file, and move on.

@language python
import os

c.saveAll()

os.system('konsole -e python3 ~/leo-editor/launchLeo.py 
/home/chris/.leo/test.leo')
# Open ~/test.leo in a separate console.
# t.bat ends with exit so the console closes when I close Leo.
leo_dir = g.os_path_finalize_join(g.app.loadDir, '..', '..')
os.chdir(leo_dir)
# print(g.os_path_abspath(os.curdir))

Chris
 

> On Linux, use something like this:
>
> os.system('x-terminal-emulator -e python launchLeo.py 
> test.leo')
>
> HTH.
>
> Edward
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: ENB: Simple design principles for style sheets

2018-03-12 Thread Thomas Passin
or, if your app settings on Windows are working right, just

  os.system(r"start C:\path_to_outline\test.leo")

This way, the starting console closes immediately.  True, you have to edit 
the @command ...@key contents if you want to open some other outline 
(workbook.leo might be a good place for this command), but then you don't 
have to find and edit the helper file t.cmd.  

On Monday, March 12, 2018 at 10:54:41 AM UTC-4, Edward K. Ream wrote:
>
>
> ​On Windows I use the following @command node to open a test file. Change 
> it to @button if you like:
>
> @command F5-open-test @key=F5
>
> @language python
> import os
> c.saveAll()
> os.system("start  cmd /c t")
> # Open ~/test.leo in a separate console.
> # t.bat ends with exit so the console closes when I close Leo.
> leo_dir = g.os_path_finalize_join(g.app.loadDir, '..', '..')
> os.chdir(leo_dir)
> # print(g.os_path_abspath(os.curdir))
>
> Imo this is even better than closing and opening your dev .leo file.
>
> F5 saves any work in your dev .leo file and opens the *small* test file 
> in a console.  The console closes automatically when you close the test 
> file.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: 75b9c9: New Themes menu

2018-03-12 Thread Edward K. Ream
On Mon, Mar 12, 2018 at 10:14 AM, k-hen  wrote:

> Excellent - thank you!
>

​You're welcome.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: 75b9c9: New Themes menu

2018-03-12 Thread k-hen
Excellent - thank you!

On Monday, March 12, 2018 at 10:57:25 AM UTC-4, Edward K. Ream wrote:
>
>
>
> On Monday, March 12, 2018 at 9:54:19 AM UTC-5, k-hen wrote:
>>
>> This is great :-D A really nice simple enhancement (I think) would be if 
>> we could just apply/reload the *current* file as well rather than having to 
>> save, re-select the file, etc. Or maybe there's a scripting trick that 
>> could do this?
>>
>
> There's *always* a scripting trick ;-)  See this reply 
>  in 
> another thread, about two minutes old. 
>
> Edward
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Tip: How to see your @command commands

2018-03-12 Thread Edward K. Ream
@c

The tab completion above will show you all the @command nodes in effect for 
the present outline, no matter where defined.

In particular, myLeoSettings.leo can define *common @command* nodes that 
apply to all outlines.  Finding/remembering those nodes becomes a stretch 
over time.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: 75b9c9: New Themes menu

2018-03-12 Thread Edward K. Ream


On Monday, March 12, 2018 at 9:54:19 AM UTC-5, k-hen wrote:
>
> This is great :-D A really nice simple enhancement (I think) would be if 
> we could just apply/reload the *current* file as well rather than having to 
> save, re-select the file, etc. Or maybe there's a scripting trick that 
> could do this?
>

There's *always* a scripting trick ;-)  See this reply 
 in 
another thread, about two minutes old. 

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: ENB: Simple design principles for style sheets

2018-03-12 Thread Edward K. Ream
On Mon, Mar 12, 2018 at 7:43 AM, Chris George  wrote:

So I guess I am really just looking for the easiest way to close and
> reopen a Leo file programmatically.
>
> An @button would save a lot of time.
>

​On Windows I use the following @command node to open a test file. Change
it to @button if you like:

@command F5-open-test @key=F5

@language python
import os
c.saveAll()
os.system("start  cmd /c t")
# Open ~/test.leo in a separate console.
# t.bat ends with exit so the console closes when I close Leo.
leo_dir = g.os_path_finalize_join(g.app.loadDir, '..', '..')
os.chdir(leo_dir)
# print(g.os_path_abspath(os.curdir))

Imo this is even better than closing and opening your dev .leo file.

F5 saves any work in your dev .leo file and opens the *small* test file in
a console.  The console closes automatically when you close the test file.

Your big dev .leo file never needs to be reloaded.  os.curdir remains
unchanged.

Note: the call to os.system happens after c.saveAll completes fully, so you
are always testing the latest code.  If, say, there is a syntax error in
your python code, loading the test file would fail, but your dev .leo file
remains running.

On Linux, use something like this:

os.system('x-terminal-emulator -e python launchLeo.py
test.leo')

HTH.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: 75b9c9: New Themes menu

2018-03-12 Thread k-hen
This is great :-D A really nice simple enhancement (I think) would be if we 
could just apply/reload the *current* file as well rather than having to 
save, re-select the file, etc. Or maybe there's a scripting trick that 
could do this?

Kevin


On Monday, March 12, 2018 at 7:00:37 AM UTC-4, Edward K. Ream wrote:
>
> This top-level menu has two items: Apply Theme and Open Theme File.
>
> Both commands prompt for a theme file, starting in leo\themes, then open 
> the file which automatically applies the theme.
>
> The Open Theme File command leaves the theme file open.  The Apply Theme 
> file command closes the theme file.
>
> I'm not sure these two commands are worth a separate top-level menu.  It's 
> probably more logical to put these commands in the Settings menu.  What do 
> you think?
>
> There is more work to be done regarding themes. See #766 
> .
>
> 1.  Allow themes that affect only settings.
> 2.  Allow themes that *add* to stylesheets.  For example, a big-text 
> theme.
> 3.  Support @string initial-theme =  and/or @data 
> initial-themes. See #790 
> .
> 4. Migrate more themes into leo/themes.  This will likely take the most 
> work.
>
> Edward
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Styling Plugins

2018-03-12 Thread Edward K. Ream
On Mon, Mar 12, 2018 at 7:56 AM, Chris George  wrote:

>
> I was more envisioning having Leo itself support 5.10, not as a
> requirement, but as generalized support for all versions of PyQt.
>

​Feel free to file an enhancement request if you like.  Make sure to
explain what this entails as fully as possible, so that people reading the
issue won't have to digest lengthy previous discussions.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Styling Plugins

2018-03-12 Thread Chris George
I guess that is a project in itself. I will look at the changelogs for
PyQt and see if I can suss out what changed and why it breaks the
stylesheet.

I suppose I could include the caveat that the stylesheets only support
certain versions and combinations of Python and PyQt, assuming I can
find an easy way to test for that.

I was more envisioning having Leo itself support 5.10, not as a
requirement, but as generalized support for all versions of PyQt.
Users who are not programmers will not be equipped to set-up python
environments (like virtualenv or anaconda) in order to change their OS
to support Leo. For example, I use Chakra Linux, a partially rolling
KDE distribution that installs python2 and PyQt 5.10 as the default.
Some users may know enough to preface launchLeo.py with python3 if
python3 is desired, but that will still give them PyQt 5.10. So anyone
running Leo on a distribution that defaults to PyQt 5.10 will suffer
broken themes.

I use Qt Designer to validate my stylesheets when I have problems. The
current stylesheet for Breeze Dark passes. It loads correctly under
PyQt 5.6.2. It does not load correctly under PyQt 5.10 and I do not
know why (yet).

Chris

On Sun, Mar 11, 2018 at 4:02 PM, Edward K. Ream  wrote:
> On Sun, Mar 11, 2018 at 3:44 PM, Chris George  wrote:
>
>> GammaRay requires PyQt 5.10 to work. I can build it and use it to load Leo
>> and it works great. Very useful.
>
>
> Thanks for this info.
>
>>
>> But PyQt 5.10 breaks my stylesheet. Qt Designer validates the stylesheet
>> just fine. Drop back to PyQt 5.6.2 and the stylesheet renders correctly in
>> Leo. All things considered, I blame PyQt. :-)
>
>
> Reasonable, imo.
>
>
>>
>> Is there anything we can do to have Leo support 5.10? This is the second
>> time that I have had an app *require* PyQt 5.10.
>
>
> We can't require anyone to use PyQ6 5.10, or Python 3.   But you are free to
> use those, and to create themes that require them.  Just please document the
> requirements.
>
> Edward
>
> --
> You received this message because you are subscribed to the Google Groups
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to leo-editor+unsubscr...@googlegroups.com.
> To post to this group, send email to leo-editor@googlegroups.com.
> Visit this group at https://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: ENB: Simple design principles for style sheets

2018-03-12 Thread Chris George
This is how my current workflow goes.

1. Change stylesheet.
2. reload-style-sheets (which I now realize does most of the work by
also saving the file if it is dirty)
3. Closing and reopening the file to see the changes. (verifies that I
haven't broken the css)

So I guess I am really just looking for the easiest way to close and
reopen a Leo file programmatically.

An @button would save a lot of time.

Chris


On Sun, Mar 11, 2018 at 3:59 PM, Edward K. Ream  wrote:
>
>
> On Sun, Mar 11, 2018 at 4:05 PM, Chris George  wrote:
>
>> Would it be possible to program a button to "Reload Stylesheets",
>> close the current file, and then reopen it? I must do this a hundred
>> times a day manually. :-)
>
>
> Why do you want to reload Leo if you reload stylesheets?
>
> Edward
>
> --
> You received this message because you are subscribed to the Google Groups
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to leo-editor+unsubscr...@googlegroups.com.
> To post to this group, send email to leo-editor@googlegroups.com.
> Visit this group at https://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


75b9c9: New Themes menu

2018-03-12 Thread Edward K. Ream
This top-level menu has two items: Apply Theme and Open Theme File.

Both commands prompt for a theme file, starting in leo\themes, then open 
the file which automatically applies the theme.

The Open Theme File command leaves the theme file open.  The Apply Theme 
file command closes the theme file.

I'm not sure these two commands are worth a separate top-level menu.  It's 
probably more logical to put these commands in the Settings menu.  What do 
you think?

There is more work to be done regarding themes. See #766 
.

1.  Allow themes that affect only settings.
2.  Allow themes that *add* to stylesheets.  For example, a big-text theme.
3.  Support @string initial-theme =  and/or @data 
initial-themes. See #790 
.
4. Migrate more themes into leo/themes.  This will likely take the most 
work.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.