Nifty Corners Cube

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Rounded corners the javascript way
Nifty Corners Cube

StackOverflow.com

VN:F [1.9.22_1171]
Rating: 8.5/10 (13 votes cast)

Random snippets of all sorts of code, mixed with a selection of help and advice.

Solving a multiple-choice multi-dimensional knapsack problem with OR-Tools

8 April 2026 @ 9:18 pm

I'm trying to solve a multiple-choice multi-dimensional knapsack problem with OR-Tools. Examples of solving multi-dimensional KPs can be found on the repository, but not the multiple-choice KP in any dimension. I assume the best solver for MMKP would be the Knapsack Solver or CP-SAT. I would appreciate it if anyone could provide example code that, ideally, does not require classes be of equal size.

LLM-based approach to fix incorrect PDF field coordinates for form rendering — is this reliable?

8 April 2026 @ 9:03 pm

I am working on a system that renders input fields on top of PDF forms using coordinates extracted from a document analysis tool. Current Setup For each form, we receive coordinates (X, Y, width, height) for fields from a document extraction system. These coordinates are used directly to render fields on the PDF. Rendering logic is consistent across all forms. Problem Some fields render correctly using the provided coordinates. However, others are visibly misaligned when compared to the actual PDF layout. -- Can anyone suggest how should we fix this issue using AI? Manually doing this would take a lot of time as there are 70k forms

Can not log-in to my Azure portal admin account after changed MFA setting

8 April 2026 @ 8:53 pm

I need urgently support from Azure team to get access to our Azure portal. My admin login got error message "can not go from here to there..." Any help will be highly appreciated. thx. Guenter

Replicating a particular plot

8 April 2026 @ 8:47 pm

I have this code that produces a nice plot library(forecast) fit <- auto.arima(WWWusage) fc <- forecast(fit, h=20, level=95) qf <- matrix(0, nrow=99, ncol=20) m <- fc$mean s <- (fc$upper-fc$lower)/1.96/2 for(h in 1:20) qf[,h] <- qnorm((1:99)/100, m[h], s[h]) plot(fc) matlines(101:120, t(qf), col=rainbow(120), lty=1) Now, I want to create this graph using the following code that calculates the quantiles for another data set but I am not sure how to produce the above graph library(fpp3) library(distributional) fc <- aus_production |> model(ARIMA(Beer)) |> forecast(h = 20) pc <- seq(99) fc |> as_tibble() |> group_by(Quarter) |> reframe(percentile = quantile(Beer, pc / 100)) |> unnest(percentile) |> mutate(pc = rep(pc, 20))

XmlSerializer - Different Order of Namespaces in .NET Framework and in .NET 10.0

8 April 2026 @ 8:16 pm

Here is a serialize implementation using XmlSerializer: public static string Serialize(object obj) { var xmlSerializer = new XmlSerializer(obj.GetType()); using var stringWriter = new StringWriter(); using var xmlWriter = XmlWriter.Create(stringWriter, new XmlWriterSettings { OmitXmlDeclaration = true }); xmlSerializer.Serialize(xmlWriter, obj); return stringWriter.ToString(); } Using the same serializer produces different strings in .NET Framework and in .NET 10. In .NET Framework, I get: <item xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="7"><name>hello</name></item> But in .NET 10, the result is: <item xmlns:xsi="http://ww

Expected biome behavior when setting it as the default in settings.json?

8 April 2026 @ 7:59 pm

I'm experimenting with biome and I have the following in .vscode/settings.json : { "editor.defaultFormatter": "biomejs.biome", "editor.formatOnSave": true, "editor.codeActionsOnSave": { "source.fixAll.biome": "explicit", "source.organizeImports": "explicit" } } And I'm expecting the biomejs.biome vscode extension to be the extension that VSCode will now use ensure that running: npx @biomejs/biome check --write Will produce results consistent with whatever biomeproduces when files are saved.  And so for the current sample project I created when I run npx @biomejs/biome check --write It changes 3 files.  And if I go to save any of these files in vscode, it changes the files again to something that is different than what running npx @biomejs/

How do i make this if statement?

8 April 2026 @ 4:42 pm

I'm trying to learn python in khan academy & I'm stuck on this challenge. the goal is to create an error message when the user inputs the day 31 for April, June, September, and November because they only go up to 30 days. Here's my code: day = int(input("Enter a day (1-31): ")) if day < 1 or day > 31: print("Error. Day must be between 1 and 31.") month = int(input("Enter a month (1-12): ")) if month < 1 or month > 12: print("Error. Month must be between 1 and 12.") not_31_days = 4, 6, 9, 11, if day == 31 and month == not_31_days: print("Error. Day must be within the month.") The error message says "April only has 30 days! If the month is 4 and the day is 31, it should print: Error. Day must be within the month."

Large heat map with multiple legends in ggplot

8 April 2026 @ 3:14 pm

I need to make a large heat map (>10-15 columns) with many different legends (different units, data types, etc). I've used the palmer penguin dataset below to show an example of how I am currently doing it. Essentially making individual heat map strips using geom_tile and then using patchwork to link them together. It always requires a lot of .svg editing in inkscape or affinity, so I'm looking for ways to streamline it and get it as close to the final desired product (copied at end). # set up library(tidyverse) library(patchwork) library(palmerpenguins) # Format penguins_formatted <- penguins %>% group_by(species, sex) %>% summarise(MEAN_BILL_LENGTH = mean(bill_length_mm), MEAN_BILL_DEPTH = mean(bill_depth_mm), MEAN_FLIPPER_LENGTH = mean(flipper_length_mm), MEAN_MASS = mean(body_mass_g)) %>% drop_na() %>% rownames_to_column(var = "uniqueID") #

Incompatibility in RRDs::graph regarding TICK boxes overlapping label

8 April 2026 @ 9:34 am

Many years ago I wrote some monitoring tool that collects data using RRD (actually using perl module RRDs. The OS at that time was SLES 10 (rrdtool 1.2012 and rrdtool 1.3007). Since upgrading to SLES 15 SP6 (perl-rrdtool-1.8.0-150600.1.4.x86_64) I see that my TICK boxes overlap its label. The bottom of the graphs look like this: Screenshot showing bottom of incorrect RRD graph The purpose of the TICKs is just a kind of "color legend" for a bar graph (green/yellow/orange/red) classifying a status not shown. The part responsible to draw that bottom part looks like this (the @graph_args array from RRDs::graph($fname, @settings, @graph_args);): ... 51 'COMMENT: Last\\t Minimum\\t Average\\t Maximum\\t Sample\\n' 52 'GPRINT:S_A:LAST: %6.2lf\\t\\g' 53 'GPRIN

Curl C/C++ library based application produces erroneous response for HTTP POST request

7 April 2026 @ 10:31 pm

I use the following block of code to download some data from a server: #include <stdio.h> #include <stdlib.h> #include <string.h> #include <curl/curl.h> #include "../persistent/settings.h" #include "network-helper.h" #define HTTP_REQUEST_MAX_LENGTH 2048 struct MemoryStruct { char *memory; size_t size; }; static size_t writeCb(void *contents, size_t size, size_t nmemb, void *userp) { size_t realsize = size * nmemb; struct MemoryStruct *mem = (struct MemoryStruct *)userp; char *ptr = (char *)realloc(mem->memory, mem->size + realsize + 1); if(!ptr) { /* out of memory! */ printf("not enough memory (realloc returned NULL)\n"); return 0; } mem->memory = ptr; memcpy(&(mem->memory[mem->size]), contents, realsize); mem->size += realsize; mem->memory[mem->size] = 0; printf("Curl callback:\r\n") for (

960.gs

VN:F [1.9.22_1171]
Rating: 8.0/10 (1 vote cast)

CSS Grid System layout guide
960.gs

IconPot .com

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Totally free icons

Interface.eyecon.ro

VN:F [1.9.22_1171]
Rating: 6.0/10 (1 vote cast)

Interface elements for jQuery
Interface.eyecon.ro

ThemeForest.net

VN:F [1.9.22_1171]
Rating: 7.0/10 (2 votes cast)

WordPress Themes, HTML Templates.

kuler.adobe.com

VN:F [1.9.22_1171]
Rating: 8.0/10 (1 vote cast)

color / colour themes by design

webanalyticssolutionprofiler.com

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)

Web Analytics::Free Resources from Immeria
webanalyticssolutionprofiler.com

WebAIM.org

VN:F [1.9.22_1171]
Rating: 4.0/10 (1 vote cast)

Web Accessibility In Mind

Ask AIMee: An accessible accessibility-focused AI chatbot

31 March 2026 @ 4:49 pm

We’re happy to introduce AIMee – an easy-to-use, AI-powered conversational chatbot focused on accessibility. AIMee has been designed to be highly accessible to users with disabilities. Ask her accessibility questions to get quick answers and guidance. The name “AIMee” plays off of the “AIM” (Accessibility In Mind) from “WebAIM” and also “AI”. Here are some […]

A New Path for Digital Accessibility?

27 February 2026 @ 7:02 pm

Please note This post will explore how an adaptive, intelligent system could empower users with disabilities to optimize their experience in digital environments. Even were such a system available tomorrow, developers of digital content, services, and products would still be responsible for providing equal access to ALL users. Consider a few of the many exciting […]

2026 Predictions: The Next Big Shifts in Web Accessibility

22 December 2025 @ 11:22 pm

I’ve lived long enough, and worked in accessibility long enough, to have honed a healthy skepticism when I hear about the Next Big Thing. I’ve seen lush website launches that look great, until I activate a screen reader. Yet, in spite of it all, accessibility does evolve, but quietly rather than dramatically. As I gaze […]

Word and PowerPoint Alt Text Roundup

31 October 2025 @ 7:14 pm

Introduction In Microsoft Word and PowerPoint, there are many types of non-text content that can be given alternative text. We tested the alternative text of everything that we could think of in Word and PowerPoint and then converted these files to PDFs using Adobe’s Acrobat PDFMaker (the Acrobat Tab on Windows), Adobe’s Create PDF cloud […]

Accessibility by Design: Preparing K–12 Schools for What’s Next

30 July 2025 @ 5:51 pm

Delivering web and digital accessibility in any environment requires strategic planning and cross-organizational commitment. While the goal (ensuring that websites and digital platforms do not present barriers to individuals with disabilities) and the standards (the Web Content Accessibility Guidelines) remain constant, implementation must be tailored to each organization’s needs and context.   For K–12 educational agencies, […]

Up and Coming ARIA 

30 May 2025 @ 6:19 pm

If you work in web accessibility, you’ve probably spent a lot of time explaining and implementing the ARIA roles and attributes that have been around for years—things like aria-label, aria-labelledby, and role="dialog". But the ARIA landscape isn’t static. In fact, recent ARIA specifications (especially ARIA 1.3) include a number of emerging and lesser-known features that […]

Global Digital Accessibility Salary Survey Results

27 February 2025 @ 8:45 pm

In December 2024 WebAIM conducted a survey to collect salary and job-related data from professionals whose job responsibilities primarily focus on making technology and digital products accessible and usable to people with disabilities. 656 responses were collected. The full survey results are now available. This survey was conducted in conjunction with the GAAD Foundation. The GAAD […]

Join the Discussion—From Your Inbox

31 January 2025 @ 9:01 pm

Which WebAIM resource had its 25th birthday on November 1, 2024? The answer is our Web Accessibility Email Discussion List! From the halcyon days when Hotmail had over 35 million users, to our modern era where Gmail has 2.5 billion users, the amount of emails in most inboxes has gone from a trickle to a […]

Using Severity Ratings to Prioritize Web Accessibility Remediation

22 November 2024 @ 6:30 pm

So, you’ve found your website’s accessibility issues using WAVE or other testing tools, and by completing manual testing using a keyboard, a screen reader, and zooming the browser window. Now what? When it comes to prioritizing web accessibility fixes, ranking the severity of each issue is an effective way to prioritize and make impactful improvements. […]

25 Accessibility Tips to Celebrate 25 Years

31 October 2024 @ 4:38 pm

As WebAIM celebrates our 25 year anniversary this month, we’ve shared 25 accessibility tips on our LinkedIn and Twitter/X social media channels. All 25 quick tips are compiled below. Tip #1: When to Use Links and Buttons Links are about navigation. Buttons are about function. To eliminate confusion for screen reader users, use a <button> […]

CatsWhoCode.com

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Titbits for web designers and alike

Unable to load the feed. Please try again later.