From 1a91c0ff836ef3e438e6c83a40271d4ebcc648f0 Mon Sep 17 00:00:00 2001 From: Rahix Date: Wed, 4 Aug 2021 14:42:35 +0200 Subject: docs: Improve --depth documentation Make it clear that --depth behaves the same for balance and register reports now. Fixes: #1952 --- doc/ledger.1 | 17 ++++++++--------- doc/ledger3.texi | 13 ++++++------- 2 files changed, 14 insertions(+), 16 deletions(-) (limited to 'doc') diff --git a/doc/ledger.1 b/doc/ledger.1 index f1fad3f6..f7f94a35 100644 --- a/doc/ledger.1 +++ b/doc/ledger.1 @@ -506,17 +506,16 @@ Direct to parse journals using the European standard comma as decimal separator, vice a period. .It Fl \-depth Ar INT -Limit the depth of the account tree. In a balance report, for example, +Limit the depth of displayed accounts in balance and register reports. Any +accounts of greater depth are folded into their parent at the specified +level. For example with .Fl \-depth Ar 2 -will print balances only for accounts with two levels, i.e. +the account +.Sy Expenses:Entertainment:Dining +would be folded into .Sy Expenses:Entertainment -but not -.Sy Expenses:Entertainment:Dining . -This is a display predicate, which means it only affects display, -not the total calculations. In register reports, -.Fl \-depth -will collapse postings of child accounts beyond the given level and add -their balances to the parent account. +for display. Importantly, this is a display predicate, which means it only +affects display, not the total calculations. .It Fl \-detail Related to .Ic convert diff --git a/doc/ledger3.texi b/doc/ledger3.texi index d8f1859a..20b3fe74 100644 --- a/doc/ledger3.texi +++ b/doc/ledger3.texi @@ -6473,13 +6473,12 @@ And with @option{--dc} it becomes this: @end smallexample @item --depth @var{INT} -Limit the depth of the account tree. In a balance report, for example, -a @samp{--depth 2} statement will print balances only for accounts with -two levels, i.e. @samp{Expenses:Entertainment} but not -@samp{Expenses:Entertainment:Dining}. This is a display predicate, which -means it only affects display, not the total calculations. In register -reports, @samp{--depth} will collapse postings of child accounts beyond -the given level and add their balances to the parent account. +Limit the depth of displayed accounts in balance and register reports. Any +accounts of greater depth are folded into their parent at the specified level. +For example with @samp{--depth 2} the account @samp{Expenses:Entertainment} +would be folded into @samp{Expenses:Entertainment:Dining} for display. +Importantly, this is a display predicate, which means it only +affects display, not the total calculations. @item --deviation Report each posting’s deviation from the average. It is only meaningful -- cgit v1.2.3