Re: [GNC] How to bulk import about 130 Securities entries?

2022-08-17 Thread john


> On Aug 16, 2022, at 8:18 PM, list+gnuc...@jdlh.com wrote:
> 
> On 2022-08-16 19:54, john wrote:
> 
>> OTOH I'm pretty sure that gnc_commodity is fully exposed to the Python 
>> bindings so you should
>> be able to write a python script using them to do the same thing without 
>> voiding your warranty
>> or needing to unzip the file or, for that matter, caring which backend is 
>> used.
> 
> Ah! Thank you for this nudge, John. I like using Python. Doing my import via 
> Python would likely be very comfortable for me.
> 
> This question may end up leading me to learn not just how to automate my mac 
> UI, but also how to use the Python bindings in GnuCash.
> 
> I have been using the macOS GnuCash app downloaded via GnuCash.org, which I 
> understand does not include Python bindings. However, I use MacPorts all the 
> time, and it looks like MacPorts will be happy to provide me GnuCash with the 
> Python bindings enabled.
> 
> I appreciate the pointer. (Well, not pointer exactly, because it is Python 
> after all, but… reference?)
> 

Jim,

It's python wrapped around C, so you may well bump into pointers. ;-)

I don't include the python bindings in the macOS app bundle because every 
release of macOS has a different version of Python, and the bindings have to be 
linked against the same libpython as the interpreter. MacPorts custom builds 
everything on your machine so it's easier.

If you wanted you could also build GnuCash the way I do and include the python 
bindings. The instructions are at https://wiki.gnucash.org/wiki/MacOS/Quartz.

You didn't mention Homebrew, but I'm going to as a warning to others who might 
read this thread later: Homebrew's GnuCash is just a cask with my macOS bundle 
in it. It doesn't use any of the Homebrew infrastructure and so can't use the 
python bindings.

Regards,
John Ralls


___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] Change GnuCash scrollbar color in CSS?

2022-08-17 Thread Glenn Fowler
Thanks Adrien for the tip. I dug through some themes and figured it out.
Just leaving this here for someone in the future:

/* Scollbar */
scrollbar slider {
  /* Size of the scrollbar */
  min-width: 22px;
  min-height: 22px;
  border-radius: 0px;

  /* Padding around the slider */
  border: 7px solid transparent;

  /* scrollbar slider color */
  background-color: cornflowerblue;
}

/* scrollbar slider color on hover */
scrollbar slider:hover {
  background-color: royalblue;
}

/* scrollbar slider color when clicked */
scrollbar slider:hover:active {
  background-color: navy;
}

/* minimum slider height for large register entries */
scrollbar.vertical slider {
  min-height: 70px;
}

On Wed, Aug 17, 2022 at 1:55 AM Adrien Monteleone <
adrien.montele...@lusfiber.net> wrote:

> It has been some time since I dealt with the topic, but I vaguely seem
> to recall that someone reported that the Inspector can run under
> Windows, though I didn't think that possible at first. Of course, I
> could be remembering wrong, and I don't have an installation on that OS
> to test it out. (maybe it has to be installed separately?)
>
> I think I once advised to spin up a Linux VM to run the Inspector, but
> then learned that the GTK versions between OSes don't always, or maybe
> even never, match. So what might work on one, might not work on an another.
>
> I'm not sure if this next idea will turn out to be more trouble or not,
> but since the desired change is controlled by GTK themes, rather than
> GnuCash, perhaps maybe investigate specifying a different theme entirely
> after finding one that more closely matches what you are looking to
> achieve. There should be instructions on the wiki for specifying an
> entire theme even on Windows.
>
> There are many sources for GTK themes, gnome-look.org being one. You
> want to at least use a GTK 3 theme. If it is v4 only or older than 3, it
> most likely will not help. (GnuCash is now using GTK3)
>
> Regards,
> Adrien
>
> On 8/16/22 10:28 PM, Glenn Fowler wrote:
> >   Hi,
> >
> > In on Windows and unfortunately there are no Windows details for GTK
> > Inspector on: https://wiki.gnucash.org/wiki/GTK3#Using_the_GTK_Inspector
> so
> > I'm not sure if it's even available on Windows.
> >
> > I did add the 'environment.local' file to 'C:\Program Files
> > (x86)\gnucash\etc' per the instructions but it didn't work.
> >
> > On Tue, Aug 16, 2022 at 8:44 PM Adrien Monteleone <
> > adrien.montele...@lusfiber.net> wrote:
> >
> >> Glenn, check the wiki with respect to the GTKInspector which might be
> >> able to help you find the proper id/class/object to target.
> >>
> >>   From the Inspector you can also make changes in real time to
> experiment.
> >>
> >> I'm pretty sure that GnuCash doesn't expose this element to styling, but
> >> customizing the GTK theme should work. (but will apply to all of your
> >> GTK apps)
> >>
> >> What OS?
> >>
> >> Regards,
> >> Adrien
> >>
> >> On 8/16/22 11:35 AM, Glenn Fowler wrote:
> >>> Hi,
> >>>
> >>> Does anyone know how to change the scrollbar and scrollbar button color
> >> in
> >>> gtk-3.0.css?
> >>>
> >>> I have tried:
> >>>
> >>> scrollbar slider {
> >>>   color: blue;
> >>> }
> >>>
> >>> and...
> >>>
> >>> scrollbar button {
> >>>   color: blue;
> >>> }
> >>>
> >>> Both have no effect. I didn't find anything in the mailing list
> archives
> >>> and the above I got from generic GTK CSS.
> >>
> >>
> >> ___
> >> gnucash-user mailing list
> >> gnucash-user@gnucash.org
> >> To update your subscription preferences or to unsubscribe:
> >> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> >> -
> >> Please remember to CC this list on all your replies.
> >> You can do this by using Reply-To-List or Reply-All.
> >>
> > ___
> > gnucash-user mailing list
> > gnucash-user@gnucash.org
> > To update your subscription preferences or to unsubscribe:
> > https://lists.gnucash.org/mailman/listinfo/gnucash-user
> > -
> > Please remember to CC this list on all your replies.
> > You can do this by using Reply-To-List or Reply-All.
> >
>
>
> ___
> gnucash-user mailing list
> gnucash-user@gnucash.org
> To update your subscription preferences or to unsubscribe:
> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> -
> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.
>
___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] Confusing and inconsistent headers in transaction entry and report forms

2022-08-17 Thread Peter S. Shenkin
Thank you. That is helpful!

-P.


On Wed, Aug 17, 2022 at 1:47 AM Adrien Monteleone <
adrien.montele...@lusfiber.net> wrote:

> Peter,
>
> I think the problem stems from your choice of report options.
>
> Namely, by default, 'Account Name' under the Display tab is *not*
> selected, while the 'other account' is.
>
> This is because by default the Sort options are:
>
> Primary: account
> Secondary: register order
>
> So by default, the transactions for each chosen account are grouped
> together, and then those are listed by date. Subtotals are for the
> account. Since the primary sorting key is the account, it is shown like
> in my screenshot on 8/3 circled in yellow. (and also what you indicated
> in your 'I wish it has said' example.) Thus, there is no need to check
> off the option to show 'Account Name' in the Display tab as that would
> be superfluous.
>
> But,
>
> Changing the primary sort to Date (or other similar option) now sets
> that grouping label to an accounting period rather than the account
> name. The account name is no longer visible, but you can of course, turn
> it on in the Display tab.
>
> I've managed to craft a report similar to the desired (3rd) example you
> gave and have attached it.
>
> I've also attached the Options used to achieve it.
>
> It might not be the only or best way to see the info, but it closely
> matches what you indicated you were looking for. Note, I only selected
> the Checking account, there is little need by your example to select
> both it and the Income account as those splits will be represented
> already since the other important preference change was switching the
> Detail Level to 'One Split Per Line' in the Display tab. You can of
> course turn on other info labels in Display, but I turned them off to
> match your example.
>
> Note, the attached example uses Date, rather than the default Account
> Name, as the primary sort key.
>
> Regards,
> Adrien
>
> On 8/16/22 10:44 PM, Peter S. Shenkin wrote:
> > I think at last I see what you all are saying.
> >
> > When I have not displayed account totals, the only account shown on a
> debit
> > or credit line is the *counterpart* of the current leg of the
> transaction;
> > so the line in the last of my four attachments that says "Checking
> Account"
> > and lists $100 as a Credit is actually showing that "Other income"
> received
> > a credit and received it from the Checking Account. The problem is that
> the
> > partner in the account is not named in the display.
> >
> > I find this very confusing, but I do understand it now. I think it would
> > have helped if, without turning on Account totals, the label of each leg
> of
> > the transaction could have maintained the name of the parent account for
> > each line.
> >
> > For instance, instead of just :
> >
> > *Date   Num Description Memo/Notes Transfer from/to  Debit
> > (USD) Credit*
> > 08/16/2022 saleChecking Account
> >   $100.00
> >
> >   I wish it had said:
> >
> > *Date   Num Description Memo/Notes Transfer from/to   Debit (USD)
> > Credit*
> > Other Income:
> > 08/16/2022 saleChecking Account
> > $100.00
> >
> > Still, what I would really like to see is something compact that shows,
> for
> > each transaction, in date order, the date and description of the
> > transaction and then a single line for each leg, the amount involved and
> > whether it is a debit or a credit. For instance:
> >
> > 08/16/2022 sale
> >  *Account Debit Credit*
> >  Checking Account:   $100
> >  Other Income: $100
> >
> > It's the compactness and clarity of the representation, not the exact
> > format, that I'm concerned with.
> >
> > Thanks for all your help. I'll play with the options to see how close I
> can
> > get.___
> gnucash-user mailing list
> gnucash-user@gnucash.org
> To update your subscription preferences or to unsubscribe:
> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> -
> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.
>
___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] Saving a New Book doesn't allow format selection

2022-08-17 Thread David T. via gnucash-user
Phyllis,

I was referring to a particular corner case, in which a user is creating a new 
file but wants to store it in a format other than the default xml. The Save 
dialog doesn't provide the user with that option.

The workaround is to save the file (as xml) and then perform a Save As in the 
preferred format (e.g., SQLite3).

But thank you for offering suggestions.

Best,
David T.

On Aug 17, 2022, 15:09, at 15:09, Phyllis Bruce  wrote:
>Thanks, John.  I have heard all those terms many times.  Two sets of
>books and cooking the books describe separate if not unique files to
>me.  You put it in better words - a book is a single GnuCash file and
>it’s accounts.  Therefore, if you have a GnuCash file saved as xml but
>you want it in another format you should be able to simply save it in
>the new format.  That is simply done by “saving as” and choosing the
>new format from the pull down list.
>
>Is there something I’m missing?  Ex…You edit a word file and “save as”
>a pdf or other type before publishing.
>
>> On Aug 16, 2022, at 9:46 PM, john  wrote:
>> 
>> Please remember to copy the list on all replies. Reply-all (often a
>double arrow pointing left) does it. Some mail programs also have a
>reply-list button or menu item.
>> 
>> We generally mean "the book" to refer to a single GnuCash file and
>its accounts. That comes from the name an internal data structure, but
>it's also a bit of accounting jargon. You've no doubt heard phrases
>like "book value", "booking an invoice", and of course the infamous
>"two sets of books" and "cooking the books".
>> 
>> Regards,
>> John Ralls
>> 
>> 
>> 
>>> On Aug 16, 2022, at 5:35 PM, Phyllis Bruce 
>wrote:
>>> 
>>> I’m new to GnuCash and prolly don’t know what you are talking about
>when you say book?  I might use that term book to describe a different
>file altogether, like my GnuCash file and my playgnucash file.  When I
>created the play file I just saved my GnuCash file with a new name so I
>could test scenarios.
>>> 
> On Aug 16, 2022, at 3:16 PM, John Ralls 
>wrote:
 
 
 
> On Aug 16, 2022, at 11:56 AM, David T. via gnucash-user
> wrote:
> 
> Hello,
> 
> I was just testing something out with a new book, and when I went
>to save this new book, I was unable to select the storage format for
>the new book. I would have imagined that I would be able to tell
>GnuCash to use a specific format (like SQLite3) when I save a new book,
>but this option only appears on the Save As dialog. Should this be
>changed?
 
 Yeah. PR welcome.
 
 Regards,
 John Ralls
 
 ___
 gnucash-user mailing list
 gnucash-user@gnucash.org
 To update your subscription preferences or to unsubscribe:
 https://lists.gnucash.org/mailman/listinfo/gnucash-user
 -
 Please remember to CC this list on all your replies.
 You can do this by using Reply-To-List or Reply-All.
>> 
>___
>gnucash-user mailing list
>gnucash-user@gnucash.org
>To update your subscription preferences or to unsubscribe:
>https://lists.gnucash.org/mailman/listinfo/gnucash-user
>-
>Please remember to CC this list on all your replies.
>You can do this by using Reply-To-List or Reply-All.
___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] Saving a New Book doesn't allow format selection

2022-08-17 Thread Derek Atkins
Hi,

On Wed, August 17, 2022 8:08 am, Phyllis Bruce wrote:
> Thanks, John.  I have heard all those terms many times.  Two sets of books
> and cooking the books describe separate if not unique files to me.  You
> put it in better words - a book is a single GnuCash file and it’s
> accounts.  Therefore, if you have a GnuCash file saved as xml but you want
> it in another format you should be able to simply save it in the new
> format.  That is simply done by “saving as” and choosing the new format
> from the pull down list.
>
> Is there something I’m missing?  Ex…You edit a word file and “save as” a
> pdf or other type before publishing.

And this is exactly how you do it in GnuCash.  File -> Save As
and there is a pull-down for available backend formats.
If there is nothing in the pull-down, that implies you don't have the
correct backend support on your system.  On Linux, for example, you need
to install the correct DBD Drivers.

> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.

-derek

-- 
   Derek Atkins 617-623-3745
   de...@ihtfp.com www.ihtfp.com
   Computer and Internet Security Consultant

___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] Saving a New Book doesn't allow format selection

2022-08-17 Thread Phyllis Bruce
Thanks, John.  I have heard all those terms many times.  Two sets of books and 
cooking the books describe separate if not unique files to me.  You put it in 
better words - a book is a single GnuCash file and it’s accounts.  Therefore, 
if you have a GnuCash file saved as xml but you want it in another format you 
should be able to simply save it in the new format.  That is simply done by 
“saving as” and choosing the new format from the pull down list.

Is there something I’m missing?  Ex…You edit a word file and “save as” a pdf or 
other type before publishing.

> On Aug 16, 2022, at 9:46 PM, john  wrote:
> 
> Please remember to copy the list on all replies. Reply-all (often a double 
> arrow pointing left) does it. Some mail programs also have a reply-list 
> button or menu item.
> 
> We generally mean "the book" to refer to a single GnuCash file and its 
> accounts. That comes from the name an internal data structure, but it's also 
> a bit of accounting jargon. You've no doubt heard phrases like "book value", 
> "booking an invoice", and of course the infamous "two sets of books" and 
> "cooking the books".
> 
> Regards,
> John Ralls
> 
> 
> 
>> On Aug 16, 2022, at 5:35 PM, Phyllis Bruce  wrote:
>> 
>> I’m new to GnuCash and prolly don’t know what you are talking about when you 
>> say book?  I might use that term book to describe a different file 
>> altogether, like my GnuCash file and my playgnucash file.  When I created 
>> the play file I just saved my GnuCash file with a new name so I could test 
>> scenarios.
>> 
 On Aug 16, 2022, at 3:16 PM, John Ralls  wrote:
>>> 
>>> 
>>> 
 On Aug 16, 2022, at 11:56 AM, David T. via gnucash-user 
  wrote:
 
 Hello,
 
 I was just testing something out with a new book, and when I went to save 
 this new book, I was unable to select the storage format for the new book. 
 I would have imagined that I would be able to tell GnuCash to use a 
 specific format (like SQLite3) when I save a new book, but this option 
 only appears on the Save As dialog. Should this be changed?
>>> 
>>> Yeah. PR welcome.
>>> 
>>> Regards,
>>> John Ralls
>>> 
>>> ___
>>> gnucash-user mailing list
>>> gnucash-user@gnucash.org
>>> To update your subscription preferences or to unsubscribe:
>>> https://lists.gnucash.org/mailman/listinfo/gnucash-user
>>> -
>>> Please remember to CC this list on all your replies.
>>> You can do this by using Reply-To-List or Reply-All.
> 
___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] How to bulk import about 130 Securities entries?

2022-08-17 Thread Fred Bone
On 16 August 2022 at 17:11, Robert Simmons said:

> > running the *.gnucash through gunzip, add in the text, and run it back
> through gzip
> 
> As a connoisseur of bad ideas for adding data to GnuCash myself, I have to
> point out that one should use a programming language that has a library
> with support for the structured data format that one wants to add to. You
> use the parser provided by the language to generate objects in that
> language. You then perform operations on those objects. Finally, you use
> the library function to emit well formatted structured data.

Not so much fun, though, as trying to unscramble the results of manual 
tweaking.


___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.