dopetalk
Technology => SMF Forum Code Modifications => Topic started by: Chip on October 21, 2019, 02:21:42 PM
-
see: https://www.simplemachines.org/community/index.php?topic=570184.msg4035152#msg4035152
In ./Sources/Subs-Editor.php
array(
'image' => 'li',
'code' => 'li',
'before' => '[li]',
'after' => '[/li]',
'description' => $txt['bbc_li']
),
array(
'image' => 'li_padded',
'code' => 'li_padded',
'before' => '[li style="padding-bottom:1em"]',
'after' => '[/li]',
'description' => $txt['bbc_li_padded']
),
array(
'image' => 'list',
'code' => 'list',
'before' => '[list]',
'after' => '[/list]',
'description' => $txt['list_unordered']
),
array(
'image' => 'orderlist',
'code' => 'orderlist',
'before' => '[list type=decimal]',
'after' => '[/list]',
'description' => $txt['list_ordered']
),
The "li.gif" and the "li_padded.gif" icons need to be copied to ./Themes/default/images/bbc
and maybe implement this:
Might be a good idea to use margin instead of padding. Just in case some nutter decides to throw extra styling at .bbc_list and ends up with something that looks weird with a padded li.
Thanks for the feedback - done!
In ./Sources/Subs-Editor.php
array(
'image' => 'list_padded',
'code' => 'list',
'before' => '[list]\n[li style="margin-bottom:1em"]',
'after' => '[/li]\n[li style="margin-bottom:1em"][/li]\n[/list]',
'description' => $txt['list_unordered_padded']
),
array(
'image' => 'orderlist_padded',
'code' => 'orderlist',
'before' => '[list type=decimal]\n[li style="margin-bottom:1em"]',
'after' => '[/li]\n[li style="margin-bottom:1em"][/li]\n[/list]',
'description' => $txt['list_ordered_padded']
),
Surprised that works, the bbc fixer-upper in preparsecode doesn’t like that kind of thing.
-
... whoops, I forgot - to see the button hover functions:
in ./Themes/default/languages/Post.english.php:
after:
$txt['bbc_quote'] = 'Insert Quote';
add:
$txt['bbc_li'] = 'Insert List Item';
$txt['bbc_li_padded'] = 'Insert List Item with Padding';