Im using fancybox popup for images. I want to check if a loaded image is svg then assign custome width height for overwirte actual size of a image.pls advice
Simply use this demo https://codepen.io/fancyapps/pen/rYQogO?editors=1010 (from the docs) as an example. This is how you can check current source - current.src
Related
i need an example of launch_background.xml file in android folder that contains and image and (text)...basically my main problem is that i can't place text in this splash screen..so to be specific...i want to achieve splash screen that contains and image and under it there is some text...
i achieved the image preview with bitmap tag inside of an item tag
but no Textview tag can be placed inside layer-list tag :( (not showing)
i know that i can make the text as an svg file and place it in item tag..but i want to do it with TextView tag...so i can control it
any help would be much appreciated...thanks in advance.
Ok to give a solution to my own problem... at first I didn't like to place my text inside a separate .png file for the purpose of reducing the apk file size. I placed it inside an svg file for the size purpose but I couldn't place that text in svg beneath the centered image... unless by hardcoding values with the attributes: "android:gravity=center" "android:top=200dp" ...and I don't feel comfortable with hardcoded values... so I searched and found this package "flutter_native_splash" Flutter Native Splash.
Placed the desired image and beneath it the desired text and the package generated the appropriate image densities for the various screens containing the image and text...
I'm using http://blueimp.github.io/Gallery/ in a bootstrap environment.
It works with my images but the modal window which shows the full size image is not large enough for me. It takes only one-third of my screen width.
You can see a live-example here:
http://www.randspringer.de/mannschaftsaufstellungen/1.html
How can I customize the size of the displayed full image?
You could either add
data-use-bootstrap-modal="false"
to the lightbox container, which displays the images borderless and fullscreen
or adjust the size of the modal according to the bootstrap documentation:
http://getbootstrap.com/javascript/#modals-sizes
I am showing the image which is uploaded by user in a modal dialog. On this image I am initializing JCrop for cropping the image.
The problem is that I am not able to set the image properly in the dialog, it works ok for images whose size (dimensions) is less than dialog size but for images bigger than dialog size, the image is going out of the dialog.
I tried using boxHeight and boxWidth but this make image non responsive and for smaller size screen the image is going out the dialog.
Basically I am looking for generic solution of showing image in a dialog no matter the image size so that it is displayed properly inside the dialog.
Use this may help :
<div class="modal-body" style="overflow: auto; >
......preview here ....
</div>
The easiest solution is to initialize jcrop in a fixed size div using jcrop option as follows:
boxWidth: 500,
boxHeight: 500,
Is it possible to make a carousel with text?? like this http://amazingcarousel.com/
Yeah you got carousel with text but the image there is set as background, I need the images to be set in img
Yeah for sure.
You can place everything in slide. You can define content slide as follows,
<div><!-- Any HTML Content Here --></div>
Reference: Define Slides Html Code
I want to have a static footer image with 5 buttons for navigation in my mobile phone website. The image is here http://www.pintum.com.au/jm/footer3a.jpg. The blue icons should be the default, the yellow icon should only be visible for the hover or active state.
I want to know how can I make this image scale to the correct width on all mobile devices (landscape and portrait) and have links to other pages and make the current/active pages icon the yellow color?
What I have tried so far
I first tried to make a CSS Sprite but that go ugly (complex) quickly. Painful working with widths everywhere so the image scales correctly as I had no way of knowing the height in pixels since the width is dynamic. I could use JS to find the width and calculate height on the fly. But this sounds like overkill.
Next I tried to have a single image with a width of 100% then place div overlays on top of the image. But with this solution I could not figure out how to navigate pages using JavaScript click event, or figure out how I would be able to change the image icon on the selected page http://jsbin.com/uraya5/3/ . And detrmining the correct height for the div
Last I tried to make each button a seperate image. These seems like the easist soultion. But jQuery Mobile adds a bunch of extra styles to the button I do not know how to remove. See http://jsbin.com/uraya5/4
So whats the best/easiest way to do this?
How can I remove the style around
links?
Or can I use a single image CSS sliding door method? To reduce HTTP request.
Ok I figured it out
See soultion here http://jsbin.com/uraya5/10/
I had to:
Set width to 19% of each button for
some reason there is spacing between
each button so 20% does not work.
Set ui-bar-a background to black so
it hides the spaces between my
images
Use this JS code to navigate pages $.mobile.changePage($("#about"),
"flip", true, true);
I would still like to use a single image instead of having 5 different images to reduce http calls. So if anyone finds a eligant soultion for this please let me know.