Jump to content

Request: Add a 'Float Block' Button to the Editor


Recommended Posts

It would be really excellent if at some point we could have a 'Float Block' button in the editor, where we could use it to mimic the BBCode functionality of encapsulating a bit of text/images/code inside [floatleft] and [floatright] blocks and have the rest of the text of the main post 'flow' around it cleanly. Would either need separate buttons for floatleft and floatright, or some other way to choose which side it 'floats' to. (Bonus points if there's a couple pixels of 'padding' around the block so the text inside the block doesn't run into the text outside the block).

Thank you!

An example shot of how a floating-left block (image plus text caption) might look (though this one doesn't have the padding, as you can see with the "Wi: 1" and the "He looked" bit at the bottom-right corner. Padding on the bottom is just fine though, it's just the sides that get a bit close):

spacer.png

Link to comment
Share on other sites

Button gfx look good, if a little stylized.

@BlueTrillium Question for you, since I already do what you're asking. When you post, do you copy & paste / clone your previous posts, so you can repurpose them? I do that and it seems to work as you're requesting with the margin (see attachment).

I have to double check, but I just put the image (and text if you want) in a separate p tag which is floated.

EDIT: nope, I also put a margin-right:30px; in there. I didn't remember if it was automatic or not. Guess not.


image.png.dd61dd3c72480cbd27a829eaa0a159fb.png
Character-related text can go here, too.

Test text.

Test text.

Test text.

Test text.

Test text.

Link to comment
Share on other sites

  • 2 weeks later...

@Malkavian Grin I'm still getting used to Baldr, but yes what I'm accustomed to doing (and hope to be able to do going forward eventually) is quote previous posts for the formatting and then change the text for the new post.

In this case however I was trying to write a brand new post (but making it look as much as reasonably possible like it used to look on MW). And I wanted to float an entire block -- I agree, floating a picture alone is simple, but I often want to have some kind of text (e.g. think of it like a 'caption' or 'title' to the pic) also floating in that block with the picture, often with its own alignment within the floating block (e.g. centered under or above the pic), and I also sometimes just want to float a block of text, and that's what I was having trouble with. (I'm not HTML-savvy in the slightest currently so I don't know what's available or the correct syntax, lol).

And then, yes, once I did get it floating, it didn't have a margin between the floating block and the main text so stuff kinda ran together. It does look like the 'margin' parameter like you're doing would accomplish that (though 30px is wider than I was thinking xD) So yeah, just like Neopopulas said, in general I thought that if we had a button for it to shortcut needing to figure out all the HTML, it would be greatly helpful. (Also Eric from my original help thread asked me to post a feature request here so I did. ^_^)

Link to comment
Share on other sites

@BlueTrillium If you check the OOC thread for the Middle-Earth game we're in, I crafted what you're looking for.

I'm not exactly sure how the editor would pull off floating whole chunks of things; I guess you could highlight and hit a button, but in order to look right, I think it'd need to add a <div> around whatever you're floating.

Long story short; if you don't mind a little HTML, you want to put (it'll float a "chunk" and center to itself):

<div style="float: left; text-align:center; margin-right:1%;">
   <image stuff here><br>
   Maybe some text here
</div>

Alternatively, just turn the margin-right into a set distance like 10px or 15px or something.

Link to comment
Share on other sites

8 minutes ago, BlueTrillium said:

Just wanted to quickly add - thank you @Malkavian Grin for the margin-right html, I've finally gotten to try it out after being away a few days, and it looks perfect for what I was trying to do there. I am definitely using it for this particular character layout.

Wonderful! I'm glad I could help :) 

Now just imagine what we could do with negative margins mwahahaha

Link to comment
Share on other sites

So I was curious and played around with MG's lovely bit of code, getting this as a possible example of how it all works. I'm sure people with real talent could create something much prettier and functional!


  

Anatasia Qazeen


https://tv-fanatic-res.cloudinary.com/iu/s--SJK7R1vy--/t_full/cs_srgb,f_auto,fl_strip_profile.lossy,q_auto:420/v1563149496/gina-torres-stars-as-jessica-pearson.jpg
UPP: 777777

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam rhoncus volutpat dolor vitae vulputate. Pellentesque mollis lacus nec nunc sagittis laoreet. Quisque sed tellus eget quam posuere feugiat ut ac elit. Praesent posuere sollicitudin dui, quis interdum urna facilisis pharetra. Fusce sollicitudin tortor quis purus auctor, nec sodales eros viverra. Proin luctus blandit neque vitae vehicula. Proin finibus, augue vitae dictum venenatis, nulla justo dictum ante, at dignissim purus urna et mauris. Duis sodales dictum ipsum in mollis. Nunc luctus lorem in orci rutrum ultrices. Nullam vehicula augue ut aliquam pellentesque.

Nunc sit amet nunc id felis luctus interdum in ac neque. Suspendisse molestie nulla tellus, maximus pharetra odio laoreet sed. Curabitur vulputate gravida est, sagittis pulvinar eros ultrices vel. Sed finibus vehicula posuere. Pellentesque dui lacus, cursus et augue et, euismod efficitur dui. Phasellus sed leo mollis, vestibulum nisl id, convallis arcu. Nullam eget maximus tortor.

 

Edited by TiffanyKorta (see edit history)
Link to comment
Share on other sites

@TiffanyKorta Thank you for the compliment ❤️ As a gift for your kindness, here's your template with tighter layout (I removed/changed some margins and stuff. EDIT: Well, only SOME of my changes managed to save). Something I personally like to to is link the name/pic back to my character sheet for more convenient clicking.

If you have a request for something, I'm happy to look into it!


 

Anatasia Qazeen

https://tv-fanatic-res.cloudinary.com/iu/s--SJK7R1vy--/t_full/cs_srgb,f_auto,fl_strip_profile.lossy,q_auto:420/v1563149496/gina-torres-stars-as-jessica-pearson.jpg
UPP: 777777

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam rhoncus volutpat dolor vitae vulputate. Pellentesque mollis lacus nec nunc sagittis laoreet. Quisque sed tellus eget quam posuere feugiat ut ac elit. Praesent posuere sollicitudin dui, quis interdum urna facilisis pharetra. Fusce sollicitudin tortor quis purus auctor, nec sodales eros viverra. Proin luctus blandit neque vitae vehicula. Proin finibus, augue vitae dictum venenatis, nulla justo dictum ante, at dignissim purus urna et mauris. Duis sodales dictum ipsum in mollis. Nunc luctus lorem in orci rutrum ultrices. Nullam vehicula augue ut aliquam pellentesque.

Nunc sit amet nunc id felis luctus interdum in ac neque. Suspendisse molestie nulla tellus, maximus pharetra odio laoreet sed. Curabitur vulputate gravida est, sagittis pulvinar eros ultrices vel. Sed finibus vehicula posuere. Pellentesque dui lacus, cursus et augue et, euismod efficitur dui. Phasellus sed leo mollis, vestibulum nisl id, convallis arcu. Nullam eget maximus tortor.

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...