You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To edit, simple click in a cell and start typing. This will 'dirty' the file and you'll have to save (doesn't auto-persist).
15
16
16
17
### Add a new resource
18
+
17
19
To add a new resource, open the resx file you want to add it to and launch the command pallette (CTRL + SHIFT + P). Choose `ResX: Add new resource` which will launch a flow to ask you for the Key, Value, and Comment (all required) and then add it to the active document.
Starting in `v0.2.32` there is an option to enable code generation. Because this extension does not actually use he resgen tool itself, it is basically a file rewrite (which the tool does also FWIW). The extension has attempted to preserve the format that VS generates to minimize diffs, including the giant unnecessary comment at the top of every resx and .Designer.cs file. To enable this check the option in the extension settings:
30
+
31
+

32
+
33
+
or manually set in your settings file:
34
+
35
+
```json copy
36
+
"resx-editor.generateCode": true
37
+
```
38
+
39
+
Feedback welcome on this area via issues and contributions to improve. It for sure will not work for everyone.
40
+
24
41
### Logging
42
+
25
43
In the settings you can enable 'verbose' logging which will create an output window category and you can see some details. Helpful for troubleshooting.
Right now this is a bulk edit -- meaning it will re-serialize the data in/out of JSON/RESX format for this editor. Tracking issue [#1](https://github.com/timheuer/resx-editor/issues/1) for improvements here, but as of now 'works on my machine' applies. The serialization also probably will not match your line endings/spacing so a first diff might be more red/green than expected. If that doesn't work, help fix or just probably not use this.
30
49
31
50
### VS Code Git diff viewing
51
+
32
52
Because this is a custom editor, if it is set as default, when viewing a diff it will render both editor views and you won't be able to see the actual diff. You'll want to switch to the Text Editor to see it. This is a known limitation of the VS Code custom editor extensbility points [microsoft/vscode#138525](https://github.com/microsoft/vscode/issues/138525) right now. Maybe there is a better way of doing this even in this mode, if you can think of one, please contribute to [#3](https://github.com/timheuer/resx-editor/issues/3).
33
53
34
54
### Disabling the editor
55
+
35
56
To disable this right click on a `resx` or `resw` file and choose `Open with...` and change options:
This is not an original idea of course. ResX/ResW/XML editors exist. None of them use the VS Code WebView UI toolkit and why I did this one. Again, selfish reasons, and a learning point. There are a few others out there that are similar and inspiration was absolutely from those. Also the editing was contributed by @worksofliam as we wait to see if the `vscode-data-grid` itself can get default edibility.
0 commit comments