@@ -124,6 +124,26 @@ Fallback to list all workspaces if no project root is found."
124
124
:type 'boolean
125
125
:group 'lsp-treemacs )
126
126
127
+ (defcustom lsp-treemacs-error-list-expand-depth nil
128
+ " Automatic expansion depth for `lsp-treemacs-error-list' "
129
+ :type 'number
130
+ :group 'lsp-treemacs )
131
+
132
+ (defcustom lsp-treemacs-call-hierarchy-expand-depth nil
133
+ " Automatic expansion depth for `lsp-treemacs-call-hierarchy' "
134
+ :type 'number
135
+ :group 'lsp-treemacs )
136
+
137
+ (defcustom lsp-treemacs-type-hierarchy-expand-depth nil
138
+ " Automatic expansion depth for `lsp-treemacs-type-hierarchy' "
139
+ :type 'number
140
+ :group 'lsp-treemacs )
141
+
142
+ (defcustom lsp-treemacs-java-deps-list-expand-depth nil
143
+ " Automatic expansion depth for `lsp-treemacs-java-deps-list' "
144
+ :type 'number
145
+ :group 'lsp-treemacs )
146
+
127
147
(defun lsp-treemacs--open-file-in-mru (file )
128
148
(select-window (get-mru-window (selected-frame ) nil :not-selected ))
129
149
(find-file file))
@@ -482,7 +502,7 @@ will be rendered an empty line between them."
482
502
(display-buffer-in-side-window
483
503
(lsp-treemacs-render
484
504
(-map 'lsp-treemacs-deps--process-dep (lsp-treemacs-deps--root-folders))
485
- " *Java Deps*" nil )
505
+ " *Java Deps*" lsp-treemacs-java-deps-list-expand-depth )
486
506
lsp-treemacs-deps-position-params)))
487
507
488
508
(defun lsp-treemacs--deps-find-children-for-key (node key )
@@ -816,7 +836,7 @@ With a prefix argument, show the outgoing call hierarchy."
816
836
(lsp-request " textDocument/prepareCallHierarchy"
817
837
(lsp--text-document-position-params)))
818
838
(concat (if outgoing " Outgoing" " Incoming" ) " Call Hierarchy" )
819
- nil " *Call Hierarchy*" nil t ) nil ))))
839
+ lsp-treemacs-call-hierarchy-expand-depth " *Call Hierarchy*" nil t ) nil ))))
820
840
821
841
822
842
@@ -887,7 +907,7 @@ With prefix 2 show both."
887
907
((eq lsp-treemacs--hierarchy-super direction) " Super" )
888
908
((eq lsp-treemacs--hierarchy-both direction) " Sub/Super" ))
889
909
" Type Hierarchy" )
890
- nil
910
+ lsp-treemacs-type-hierarchy-expand-depth
891
911
" *lsp-treemacs-call-hierarchy*" ))
892
912
(user-error " No class under point." ))
893
913
(setq lsp--buffer-workspaces workspaces)))
@@ -1022,7 +1042,7 @@ With prefix 2 show both."
1022
1042
(lsp-session-folders)
1023
1043
(-keep #'lsp-treemacs--build-error-list )))
1024
1044
" Errors List"
1025
- nil
1045
+ lsp-treemacs-error-list-expand-depth
1026
1046
lsp-treemacs-errors-buffer-name
1027
1047
`([" Cycle Severity" lsp-treemacs-cycle-severity])))
1028
1048
0 commit comments