tool-bar icon indicating copy to clipboard operation
tool-bar copied to clipboard

how to add a formatting menu bar to Atom-“cut", "copy", "paste".

Open egor230 opened this issue 4 years ago • 3 comments

I study HTML, chose the atom editor. Please tell me how to add a formatting menu bar to Atom-“cut", "copy", "paste". It is uncomfortable to work without them.

egor230 avatar Nov 05 '19 14:11 egor230

Hi @egor230 can you provide a bit more detail on how you're using tool-bar? In general what you want to do is add a snippet like the one below to your toolbar configuration, but how to do that depends on how you use tool-bar.

Based on the examples in this repositories README and the fact that Atom's "cut", "copy", and "paste" commands are core:cut, core:copy, and core:paste respectively.

toolBar.addButton({
  callback: 'core:cut',
  tooltip: 'Cut', 

  /* This just gives it an appropriate icon */
  icon: 'cut',
  iconset: 'fa'
});
toolBar.addButton({
  callback: 'core:copy',
  tooltip: 'Cut', 

  /* This just gives it an appropriate icon */
  icon: 'copy',
  iconset: 'fa'
});
toolBar.addButton({
  callback: 'core:paste',
  tooltip: 'Paste', 

  /* This just gives it an appropriate icon */
  icon: 'paste',
  iconset: 'fa'
});

Hope that helps :smile:

ericcornelissen avatar Nov 05 '19 16:11 ericcornelissen

thank you very much for the quick and complete answer. thank you very much. I used to work with C++ in the Studio. there is a formatting panel, which is very convenient when only one hand can work. then decided to study web. hot keys to press through the nose difficult, began to search for how to add a menu bar with the option of adding buttons. tell me, please, where to insert it? in the json?,

egor230 avatar Nov 05 '19 17:11 egor230

@egor230 you can use Ryo's flex-tool-bar that allows you to add arbitrarily buttons 😊

suda avatar Nov 10 '19 15:11 suda