| Summary: | Creating a new .odt file from Win Explorer does not use default template | ||
|---|---|---|---|
| Product: | LibreOffice | Reporter: | Orwel <orwel01> |
| Component: | Writer | Assignee: | Laurent Balland <jumbo4444> |
| Status: | VERIFIED FIXED | ||
| Severity: | normal | CC: | bernhard2016, dgp-mail, himajin100000, jumbo4444, mentoring, mikekaganski, nucleorion, sdc.blanco, taltamirh |
| Priority: | medium | Keywords: | difficultyBeginner, easyHack, skillCpp |
| Version: | Inherited From OOo | ||
| Hardware: | All | ||
| OS: | Windows (All) | ||
| See Also: |
https://bugs.documentfoundation.org/show_bug.cgi?id=133661 https://bugs.documentfoundation.org/show_bug.cgi?id=139991 https://bugs.documentfoundation.org/show_bug.cgi?id=122190 https://bugs.documentfoundation.org/show_bug.cgi?id=150377 |
||
| Whiteboard: | target:7.5.0 | ||
| Crash report or crash signature: | Regression By: | ||
| Bug Depends on: | |||
| Bug Blocks: | 103303, 103314 | ||
|
Description
Orwel
2021-01-28 09:39:34 UTC
I confirm it with Version: 7.1.0.3 (x64) / LibreOffice Community Build ID: f6099ecf3d29644b5008cc8f48f42f4a40986e4c CPU threads: 4; OS: Windows 10.0 Build 19042; UI render: Skia/Raster; VCL: win Locale: de-DE (de_DE); UI: en-GB Calc: threaded I'm pretty sure, that a similar bug has been reported before, but I couldn't find it At least related to bug 133661, that should be fixed in LO 7.1 Mike, I think, you might be interested in this *** Bug 148067 has been marked as a duplicate of this bug. *** So now, after tdf#139991 is implemented, it allows to fix this trivially: make the shell's New command to create an *empty* (0-byte) file. LibreOffice would open such a file as a new document of type detected from extension only, using default template (if any) set for respective component. For Windows, it implies: 1. Search for all occurrences of "shellnew" in the codebase; 2. In the SCP files found, replace respective "Name" from "FileName" to "NullFile", and "Value" from "<progpath>\share\template\shellnew\soffice.*" to "" (empty string); 3. Drop extras/source/shellnew/*. There should be some similar way for Linux integrations (or, if unavailable, we would need to still provide 0-byte files under extras/source/shellnew/, instead of dropping them at #3 above). As maybe simple solution, just making all those files under extras/source/shellnew/ 0-byte would be enough, without a need to modify anything else. That would automatically work for any Linux integration making use of the files, too. The caveat is that the new way relies on special-processing the 0-based files, which are *not* proper ODF packages. MS Office uses the same technique; but if you open those files using a different application before editing and saving in LibreOffice, the results would be unexpected (just the same way as they were in LibreOffice before implementation of tdf#123476). FTR: This is *not* "skillCpp"; I do not see a matching "skillAny" in the possible values ;) - so I'll keep what is set now :-D *** Bug 150226 has been marked as a duplicate of this bug. *** *** Bug 120141 has been marked as a duplicate of this bug. *** Laurent Balland committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/567b4281b96f56ce48d3feb57522255b06816f9b tdf#139962 make shellnew files 0-bytes It will be available in 7.5.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback. (In reply to Commit Notification from comment #8) > Affected users are encouraged to test the fix and report feedback. Don't know a way how to create a LODev file from desktop. So I think, have to wait for a RC of LO 7.5. (In reply to Dieter from comment #9) By default, dev (non-release) builds differ by WRITE_REGISTRY property value (they have it 0, while releases use value of 1). That means that installation doesn't write anything to registry, including the New shell registration. You *could* use a command like > msiexec.exe /i LODevDailySomething.msi WRITE_REGISTRY=1 to install it with all the registry data, but note that that would also conflict with the installed release version, which is why it isn't done by default. Thank you for quick reply, but since I'm not familiar with registry entries, I don't want to change anything here. VERIFIED with Version: 7.5.0.1 (X86_64) / LibreOffice Community Build ID: 77cd3d7ad4445740a0c6cf977992dafd8ebad8df CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win Locale: de-DE (de_DE); UI: en-GB Calc: CL threaded Laurent, thank you for fixing it! |