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.

How do I use HTML / CSS to have items span a grid if there are fewer items in the row than there are columns?

28 February 2026 @ 3:55 am

I'm trying to create a grid with three columns, but if there are fewer than three items in a given row, I want the items to span the width of the grid. I'm including a screenshot of my current layout, an edit showing what I would like, and snippets of my HTML and CSS: Current Layout (Note: the title at the top is done with a separate grid than the one with pictures. If there is a better way to do this, any help would be appreciated.): A grid layout showing a title bar at the top, three items in the first row, and two items in the second row. The second row has an empty space below the third item in the first row. Desired Layout:

How do I weight certain array comparisons more heavily than others when matching input across an answer key?

28 February 2026 @ 3:49 am

I'm making a quiz-type program and I have 8 preset answer keys that each have an array of 15 binary values. User answers the same 15 questions, I compare their array against all 8 and then return the closest match. My main concern is that some of the presets only differ on like 2-3 values so the "winner" is essentially arbitrary. The 2 questions where they disagree should matter more than the 13 where they don't. Is there a way to detect which values actually differentiate between presets and weight those higher automatically, or is there some sort of algorithm for this? I could hardcode weights for every question I guess but that feels inherently wrong due to me somehow gaming what should be somewhat objective results, ideally the weights would be computed through the presets themselves. For context I've made sure to add a code snippet, the presets represent historical philosophers and the questions themselves are specific trolley problems. I've made sure to

How to add a source file using Raspberry Pi Pico SDK?

28 February 2026 @ 3:43 am

I am trying to create a Raspberry Pi Pico project using C and I am trying to set it up such that I separate functionality into separate c files. However I can't for the life of me figure out how to get my other source files to be included. I work in embedded C all day but I DO NOT understand CMake AT ALL so I assume it is that (or the VS Code plugin method of compiling). I have my main file (torch.c) that I can get to compile, cool. I then add my separate c and h file for i2c functions, then include that file from the main file and it can't seem to find it even though it's right there. I don't get why I can't get this to be included in the build? VS Code shows squiggles under the GPIO_FUNC_I2C for some reason even though I'm including all the same headers as when it was in the main c file. I don't know if that's related. enter image description here I just want to organize my code into separate files and

How can I estimate or count input tokens for a PDF before sending it to AWS Bedrock, since CountTokens API doesn't support document input?

28 February 2026 @ 3:41 am

I'm building a system that processes PDF files which my clients upload and sends them to AWS Bedrock using Anthropic Claude models (possiblyclaude-4.5-haiku, claude-4-sonnet). My concern is input token usage. A 3.5 MB PDF I tested consumed ~100K tokens, so I want to protect against excessive token consumption. I want to cut off the token usage per PDF at around 20k tokens AWS provides a CountTokens API: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_CountTokens.html However: CountTokens does not support document inputs (PDF). I get: ValidationException: Document input not supported for token counting I need a way to: Estimate token usage

Why does SteamGifts return a 403 response when I access SteamGifts in Python code?

28 February 2026 @ 3:39 am

Here's the Python code import httpx url = "https://www.steamgifts.com/" headers = { "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:147.0) Gecko/20100101 Firefox/147.0", "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8", "Accept-Language": "zh-CN,zh;q=0.9,zh-TW;q=0.8,zh-HK;q=0.7,en-US;q=0.6,en;q=0.5", "Accept-Encoding": "gzip, deflate, br, zstd", "DNT": "1", "Sec-GPC": "1", "Connection": "keep-alive", "Upgrade-Insecure-Requests": "1", "Sec-Fetch-Dest": "document", "Sec-Fetch-Mode": "navigate", "Host": "www.steamgifts.com", "Sec-Fetch-Site": "none", "Priority": "u=0, i", &qu

can mongodb use in memory sort if a field is part of the index but is also an array of subdocuments?

28 February 2026 @ 3:36 am

compound index: { 'tar.ilk.goal': 1, lli_bin: 1, 'tar.max_me': -1, 'tar.min_tar': -1 } `tar` is an array of subdocuments. sort stage immediately following the $match stage that uses the compound index above: { '$sort': { 'tar.ilk.goal': 1, lli_bin: 1, 'tar.max_me': -1, 'tar.min_tar': -1 } } will this $sort stage be in memory, ie blocking, or covered by the index?

javax.swing does not exist

28 February 2026 @ 3:20 am

I'm doing a java OOP assignment and ran across a syntax error that shows JOptionPane does not exist on the import statement. How to fix that?

How to use Sony Camera Remote SDK in android

28 February 2026 @ 3:09 am

i am working on a android project using the latest sony camera remote sdk to control sony camera,but i don't know how to use it and cannot find an example using java in android studio.Any one can give me any advice to run my code on the sdk? I just put .so files from sony linux32-armv7-sdk's remotecli/external/srsdk folder to app/libs/armeabi-v7a in android studio project,copy .h .cpp files to app/src/main/cpp from sony sdk's remotecli/app. When i try to type SCRSDK::Init(0) as some other code language does,after type SCRSDK::I,android studio can give a suggestion of SCRSDK::Init,but when i try to run the project,there's an error "ld.lld: error: undefined symbol: Init ".Referenced by... CmakeFiles...(Is there any problem with cmakefile?I have not change anything of the project cmakefiles because i don't know how to set it T_T) The Init function comes from CameraRemote_SDK.h which i have included in my codes,the brief code is put below and maybe helpful

Latex Glossaries Error: Ausarbeitung.sls: Fehler: 2: Missing { inserted. \begin{theglossary}\glossaryheader

28 February 2026 @ 3:08 am

writing my master thesis and came across some really annoying problems which I can't solve with AI. I hope that someone experienced can help me with that because I don't really know what to do anymore. This is my config.tex: % ---------------------------------------------------- % ---------------------------------------------------- % Konfigurationsdatei mit Pakten % ---------------------------------------------------- % ---------------------------------------------------- % ---------------------------------------------------- % 1. Grundlegende Fixes & Klassen-Hacks % ---------------------------------------------------- \usepackage[listings=false]{scrhack} % Verhindert Konflikt zwischen KOMA-Script und minted/listings % ---------------------------------------------------- % 2. Sprache, Schrift & Kodierung % ---------------------------------------------------- \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} % für Umlaute, Sonderzeichen und Anfüh

RHEL 9 ReaR vs grub2-efi-x64

28 February 2026 @ 1:32 am

I cant figure out an issue with a RHEL 9 system trying to utilize ReaR. On RHEL 8, I found that in order to do a network style backup with ReaR that I needed to install several additional packages (specifically grub2-efi-x64 + nfs-utils and their dependencies). I am now working with RHEL 9 and out of force of habit I downloaded ReaR + the two non-dependency packages. Once I did this, and rebooted the machine later on, the attached screenshot is what I saw Screenshot . This has happened multiple times. I was able to boil it down to NOT ReaR itself, or nfs-utils- it was the grub2-efi-x64 package that once I installed this, the system broke. Now, this initially happened on a system that was using the DISA-STIG profile for hardening so I attempted it on a fresh build that was unhardened- same thing. Including the system information and the packages I am concerned about. Before downloading this package, I made sur

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

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> […]

Celebrating WebAIM’s 25th Anniversary

30 September 2024 @ 10:25 pm

25 years ago, in October of 1999, the Web Accessibility In Mind (WebAIM) project began at Utah State University. In the years previous, Dr. Cyndi Rowland had formed a vision for how impactful the web could be on individuals with disabilities, and she learned how inaccessible web content would pose significant barriers to them. Knowing […]

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.