I met a limit with quite typical operation. Simple document:
http://i.stack.imgur.com/JNI9v.png
As you can see, image has right and bottom margins. But... CKEditor image dialogue provides VSpace and HSpace parameters which influence together to Top-Bottom or Left-Right twin values and adds unnecessary top and left margins:
http://i.stack.imgur.com/vo3oC.png
Of course, users won't use pure code to define this in style="..." attribute. So, how to allow users insert images as shown on the first image? Maybe exists CKEditor plugin or patch... and i just can't find it.
Another, maybe even a simpler way, to achieve what you want would be to use a predefined set of styles for images and use the "Styles" combo to apply one of preselected classes. This way the styles used for images could be more consistent.
To see what I mean you can check the "Standard" demo - click on an Image and in the "Styles" combo select "Object styles -> Styled image (right)"
Related
I have an OpenCart store where each product has multiple sizes, they also have different colors but each color is a different product.
Now I want to be able to filter the products by size and color too using Brainy Filter.
However that would mean that I have to add Color option to products. The problem is that this color option will have only one item (white for example, or blue, or green, etc.), so it is not necessary to show this option to the customer [see image].
I'm guessing that I can count how many items an option has and if it's less than 2, then apply a class to hide the it, however the option is still visible in cart/checkout/order history and other pages.
My question is - is there any better way to do color filtering than to create a Color option (not using Tags)? If not, is there a clever way (except hiding it with CSS on every page that it's visible) to hide this option from the customer since they don't really need to see it.
I am developing a win32 application and I want to use my own images instead of default + and - signs in tree view.
I also found here that I can use images in four cases-
1)An image, such as an open folder, displayed when the item is selected.
2)An image, such as a closed folder, displayed when the item is not selected.
3)An overlay image that is drawn transparently over the selected or nonselected image.
4)A state image, which is an additional image displayed to the left of the selected or nonselected image. You can use state images, such as checked and cleared check boxes, to indicate application-defined item states.
I found some examples like this one(uses state images) but it seems it is not related to my query.
But I can't find how to replace default + and - signs of tree view with my images.
Please help me out of it. Thanks in advance.
The "expansion" buttons are not drawn using an assigned image list; instead they come from the current theme (or in XP/non-themed, are hard-coded glyphs).
The only way to customize them is to use Custom Draw and draw the tree items yourself.
Using GWT I am trying to create a row of images with text centered below them. There isn't much detail on GWT online so I'm having a difficult time. The image should also be a hyperlink.
You can achieve this layout using standard HTML and CSS. The most obvious solution is to use floating divs which contain an image and its text, with "text-align: center" rule applied to the div.
In GWT you can achieve this either through a Ui:Binder, or, if the images are dynamic, by creating a custom widget to represent each image with its text.
The alternative solution is to use a HorizontalPanel widget and add images and text inside, which is an equivalent of using a table to achieve your desired layout. This solution is not responsive, though.
I'm new to the site, but I'm looking into creating a very simple code which from a small collection of images, changes the photo by clicking on the right hand side of the image for "next" and left side for "previous". Ideally allowing space underneath to include text and an option of an independent text link to change the image. Best way to describe what I'm searching for is something exactly the same as this http://rowingprojects.com/cabinet/florian-roithmayr-the-y
Can anyone help? I would very much appreciate it. Thank you.
You need for this: HTML, CSS and Javascript.
In HTML:
You put down all images which you want to slide, and give them an id. Hide all, in HTML code with style's display attribute.
You need to add 2 transparent block which is always above the image left and right side. You can do this, with using CSS position, z-index, top, and left attributes. Give this elements onmouseclick and the correct JS function (nextimage, previousimage).
In JS:
You need a var, which contains the actual picture number in the array.
You need an array, with image ID's.
You need a nextimage and previousimage, which show and hide the images with styile's display attribute, these using that array and var.
If you want a title or/and description for the image, you only need to put that image in a div and formating whatever you want. But in this case you need to add id to the div not to the image. Or you can change the title/description with using JS.
I have a whole bunch of very narrow columns in a DevExpress GridView and I want to save on column header width by making the caption text (which is too wide even at 3-4 letter abbreviations) slanted / diagonal. Well, so I guess I could get rid of text captions and replace them with pictures of diagonal text, at least if GridView will allow sufficient height for the header.
Is there any built-in way to just display the rotated text without going the image way? I don't think I am the first programmer out there trying to squeeze out horizontal space like that, so this doesn't sound like an outlandish thing to support in a popular grid component :-)
If not, and so I do have to use an image for column header, any relevant suggestions or warnings?
XtraGrid does not provide a built in functionality to show column header captions this way. However, this can be done within the CustomDrawColumnHeader event handler. We have posted a tutorial showing how this can be done. By default, it should be located at:
C:\Users\Public\Documents\DevExpress 2010.2 Demos\Components\WinForms\XtraGrid\CS\GridTutorials\GridVerticalHeaders
NOTE, as this feature is implemented using custom draw. It means that this text is only painted this way. Custom drawn text won't be exported or printed.