Is it a way how to set the size of dialog boxes in Awesome WM? Like "add torrent" in transmission torrent client or "select entry to auto-type" in keepassx. E.g. make them bigger every time they appear.
You need to create rules that match the dialog and set the geometry property. See https://awesomewm.org/apidoc/libraries/awful.rules.html
I am a bit rusty with Awesome WM, but you can append your rc.lua to detect those kinds of windows with the Awful library. Custom linux desktops always require a bit of trial and error. Have a look at these links, too:
https://awesomewm.org/apidoc/libraries/awful.placement.html
https://awesomewm.org/apidoc/classes/client.html
That second one is a bit more general, but I'm certain the dialog-type pop-up box is detectable, and resizable.
Related
How do I create a global overlay of all tags?
Pressing a shortcut should make all tags appear in seperate boxes in one screen. It should look something like this:
How can I make something like this? How can I seperate tags in boxes?
My collision module or the bling module has something close enough. Getting the exact layout you ask for is non-trivial because AwesomeWM is not a compositing window manager. This means it cannot really take screenshots (let alone live-views) of invisible clients/windows. Usually, the only "safe" thing is to display the outline and client icon.
If you really, really want this, you need:
A compositing manager such as picom
Either these patches or use gears.surface(client.content) to take a screenshot
Lot of code to properly render a wibox with the right screenshots. You can read the bling or collision code to know how to get the size and position.
I have a web page with text and an image. I want to place the text very precisely over the image.
I have discovered that with the font I am using, when viewing the page on windows, everything gets shifted down by about 4px. On Mac, iphone and android, it is placed correctly.
This does not happen if I use Courier New as the font, so I know that the problem is the font, however I have no choice but to use this font.
Is there a way to compensate for this purely in CSS, or do I need a javascript callback to detect windows and add a class so I can deal with it?
first of all, I would try tuning ling height, if that did not work, then I think you need to edit the font itself, you can do that using this site: https://transfonter.org/, uploading your font file and convert it to the formats you use and the important point is to check this toggle button, it adjusts some properties in the font so it has similar experience on different operating systems
if that did not work, there is a program called fontforge it gives you the ability to change font metrics, for more info you could check this question
Font Rendering / Line-Height Issue on Mac/PC (outside of element)
On my MacbookPro, I can hold the command button down, then hit the +/= button and the fontsize increases in each and every panel, making it easier to read from a distance for my students viewing on our Smartboard.
How is this same thing performed on a PC Windows machine?
Ctrl++, and
Ctrl+-
More keys might be necessary to generate +/- (for instance, for me Zoom In is Ctrl+Shift+=).
Other notes:
You can also zoom in using the View menu
See a list of keyboard shortcuts with Alt+Shift+K (recent versions of RStudio only)
Tool --> Global Options --> Appearance --> Then you can adjust the font size at the right panel
I know trying for fixed-display is usually a web design no-no, but please hear me out!
I'm developing a whiteboard-like addition to the forum I run. Long-story-short, the idea is that a user can type up their posts with text and bbcode like normal, then instatiate a managed canvas on top of their text, doodle on it with their mouse, hit submit, and then the doodle will show up on top of their post. The server processes the image into a transparent-background png and then aligns it properly into the text.
So I actually have the backend processing and the front-end interface all working well together. The only part left to do is the display, in which the processed doodle is aligned on top of the text. And, for this to work, the alignment of the image on the text needs to be pretty precise. If the user, say, circles or crosses-out a word, and the text isnt rendered in the same way for another user, the end-result is gonna be wrong. So, I figure that I need to get the text-display locked down. This is kind of annoying, because right now everything is pretty fluid, but hey, this will be a pretty cool feature, right? So, I've fixed the width of the post-display box, but I'm stumped as to what to do about the font - how to set the size, face, letter-spacing, line-spacing, etc so the display is as fixed as possible for different users on different monitors on different computers.
Does anyone have any ideas? If it helps, I'm not at all concerned with IE or mobile displays...
Kerning is going to be your biggest issue,but it should be easy enough by looking at the monospaced fonts available for font-face on fontsquirrel, something like this should do it
http://www.fontsquirrel.com/fonts/CPMono_v07
monospaced fonts should have equal letterspacing.
You can get finer control using letter-spacing:, line-height: and font-size: css classes
hope that's some help.
A customer has asked us to a add a feature to his website allowing visitors to colour in panels in a simple line drawing.
The website visitor will have a limited palette to choose from and will select a colour and click in a shape within the line drawing to colour it in as in:
There will only be four or five of these line drawings. The drawings themselves are not required to be interactive or flexible, only the colouring.
The line drawings will be super simple and we don't need to save the visitor's selections although the visitor will want to print or email the result.
Simple simple stuff. Most of the time where you see this done on sophisticated websites I assume it's done with Flash.
But is Flash the only way to go? Or can it be done with JQuery/Javascript or Silverlight or something else? Our team's knowledge covers ASP.NET, HTML, CSS, Javascript. No experience of Flash.
If you have a finite number of line drawings, and a limited number of colours, you could just pre-generate every possible colour/section combination - isolate each area as a transparent GIF/PNG and composite them using position:absolute to create an "onion skin" / animation cel effect. Use some old-school HTML image-map code (or server-side parsing of the myimage.X / myimage.Y parameters, or jQuery) to work out where they clicked, identify the image section under the mouse click location, and replace that image only with the corresponding version in their selected colour.
You can't draw these kinds of shape without using canvas or SVG. And I am not sure about the support provided by browsers for these.
If you can go for canvas then you ca ntake a look at
Processing js library
or for SVG
Raphaël—JavaScript Library
There are only two ways i can think of atm:
Split the line drawings into the colourable elements and show each image absolutly positioned to merge the images into one on the website.
Use Javascript to load a pre-coloured image of that part with "onclick" (or generate a coloured version with asp/php/whatever server-side.
Not sure if it's possible to print absolute positioned elements cleanly.
Use flash, it's simple there so even without experience you should be able to do it in 1-2 workdays.
My guess is that you could use the new HTML 5 canvas element to achieve this goal in an open, standards compliant manner.
Note: canvas is a new feature and is only supported in recent browser releases (latest Safari, Firefox or Chrome for example).