Sublime Forum

MarkdownTableFormatter

#1

Hello, here’s a new plugin to easily format your markdown tables. It’s not on package control yet but there’s no dependencies. Hope you’ll enjoy !

6 Likes

#2

Thank you! How is this different from the very robust and featureful SublimeTableEditor? (STE isn’t actively developed any more but still works great for me.) Do you plan to support other types of tables (Simple, EmacsOrgMode, Pandoc, MultiMarkdown, reStructuredText, Textile) or non-monospace fonts?

0 Likes

#3

Hello, thank you for your reply. I didn’t know SublimeTableEditor, that’s a really nice plugin. I don’t know very well STE but it seems to me MTF bring some features :

  • it can format all tables at once (with shortcut or on save)
  • it tries to fix wrong tables
  • configurable cell margin/padding
  • configurable default justification
  • shortcut is always active on md files (it seems to me STE needs to be activated)
  • license is MIT
  • it’s very very light

It’s a very minimalist plugin and it should stay focused on md so I expect it to be really easy to maintain. Of course it might evolve in the future… I may add the STE’s tab feature which I think is the nicest one.

1 Like

#4

At this point, i’ll be then using your plugin instead of Table Editor. :slightly_smiling:

Matt

0 Likes

#5

How about forking STE and maintaining the new package? Could that be a possibility?

0 Likes

#6

I didn’t take a closer look, but TE uses the GPL and looks to be way heavier than this package. These are some warranted reason for working on a new package.

0 Likes

#7

I don’t mind if we start a new package. but I basically need STE and all its features with a maintainer :wink:

Here are my feature requests:

  • It should be configurable to work on all filetypes. cause ascii tables can be helpful in different places.
  • It should support multiple table formats
  • It should give me commands to help me write and manipulate these tables in an easy way (just look how it’s implemented in STE at the moment)
0 Likes

#8

Just wondering since MTF is intended for markdown, does it work/align for proportional fonts?

0 Likes

#9

It seems to me that using proportional fonts with markdown would make the table only good looking with a specific font. Do you need this feature to export tables to office document or something ?

@ everyone
Thank you for those ideas !

0 Likes

#10

I tend to edit my markdown using a proportional font; if I then want to edit a table, I need to go into my ST3 config file, change the font to monospace, etc.

I don’t even know if it’s possible (probably not), but I always thought it’d be neat if a table editor was smart enough to force tables to use a monospace font even if the rest of the syntax is proportional.

0 Likes

#11

Sublime Text cannot do that (use different fonts for different sections in a file/view), but you could make a key binding that toggles the font setting between a monospace and a proportional font, using a simple plugin.

That, or MTE could auto-toggle the font setting for you when it detects that you are within a table.

0 Likes

#12

I have tried to use FontCycler to do this, but there’s some problems with cycling between fonts in a markdown file versus a Python file, for example. Oh well!

0 Likes

#13

Hello, I am author of Sublime Table Editor, btw license is not the problem, I changed license from GPL to Apache 2.0.

1 Like