> On Jan 26, 2022, at 2:07 PM, Neil C Smith <[email protected]> wrote: > > On Wed, 26 Jan 2022 at 18:59, Scott Palmer <[email protected]> wrote: >>> On Jan 26, 2022, at 12:19 PM, Neil C Smith <[email protected]> wrote: >>> >>> On Wed, 26 Jan 2022 at 16:54, Michael Bien <[email protected]> wrote: >>>> ctrl+click the hyperlink, empty the template, save. >>> >>> It's funny how that change has made it both far easier to change and >>> yet somehow far more confusing for people. >> >> If all that is needed is to tell them "ctrl+click the hyperlink, change the >> template >> (or clear it completely if you don’t want one), save” then just put that >> text in the >> initial value for the default template as well. ... There is no way I would >> have found >> where to change it without some google searches. > > That is almost exactly what it was changed to, and why! Check > https://github.com/apache/netbeans/pull/2960 and maybe suggest an > improved text in a follow up PR?
The text in that PR says: Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template Yes, that could be confusing. Is it a “template” or a “license”? Why are there two different links to do the same thing? Why does it say “click” if according to Michael) a ctrl-click is required? Does it require a command-click on a Mac? To a new user that isn’t a template or a license - it’s a comment. How about: This comment is added automatically to the top of new source files. It comes from the default license template. You should change the template to something more suitable, which can be having no license comment at all. To change this default license template ctrl-click (command-click on macOS) the following link: nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java For template editing help refer to https://netbeans.apache.org/some/parth/to/template/help I always change mine to insert a copyright statement with the current year… it is not as straight-forward as one might expect. The ${date?date?string("yyyy”)} part is not something that is easily discoverable. <#if licenseFirst??> ${licenseFirst} </#if> ${licensePrefix}Copyright (C) ${date?date?string("yyyy")} Me <#if licenseLast??> ${licenseLast} </#if> The templates can be quite powerful, but all that macro stuff can be confusing for inexperienced programmers (e.g. students), so having a link to some documentation or a template tutorial in the default template would be helpful, I think. Interesting side note… I just noticed a UI oddity. Generally when a menu item causes a new dialog to appear (i.e. the action requires further input from the user), the menu item text ends with an ellipsis “…’. E.,g “Save” as no ellipsis, but “Save As…” does. Shouldn’t the Tools -> Templates menu item also follow this pattern? I.e. not “Templates” but “Templates…” ? Scott
