programming

My ToDo List for 2024 (daily updates)

waffarx cash back

How to create a Sliding Notification in Your Android App?

This guide will walk you through creating a custom notification that slides up from the bottom of the screen in your Android application. 1. Designing the Notification Layout (XML) πŸ”— We’ll define a background drawable for the notification using an XML file named popup_background.xml. The code creates a rectangular shape with rounded corners, a solid color fill, and a black border. <shape xmlns:android="http://schemas.android.com/apk/res/android"> <solid android:color="#C999" /> <corners android:topLeftRadius="10sp" android:topRightRadius="10sp"/> <stroke android:color="#000000" android:width="1sp"/> </shape> Next, we’ll create the layout for the notification itself (e.

How to put a Button at the bottom of the screen ? - Android Development

the whole gravity / layout_gravity is a bit confusing, so here is a snippet: <LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="horizontal" android:gravity="center_horizontal|bottom"> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:text=" Back " android:id="@+id/btn_back"/> </LinearLayout> The line of code that makes the button at the bottom is android:gravity="center_horizontal|bottom".

How to change text size in Android app development : Kotlin & Flutter

Text size plays a crucial role in user experience, especially on mobile devices. This tutorial will guide you on implementing text size adjustments in both Android (using Kotlin) and Flutter applications. Understanding Text Size Options πŸ”— Default System Settings: Both Android and iOS allow users to adjust the overall font size in their system settings. Your app should respect these settings by default. In-App Adjustments: You can provide additional control within your app for users to further personalize the text size.

Android Emulator Avd Notes

to create a test project πŸ”— android update test-project -m ./path/main_project/ -p ./path/test_project/ to launch emulator πŸ”— emulator -avd ADB server & list attached devices πŸ”— adb devices adb start-server

How Do I Reduce a PDFs Size Manually?

Adobe Acrobat Pro πŸ”— If you have Adobe Acrobat installed on your computer, there’s a tool within the application called PDF Optimizer. This is one of the best and easiest ways to reduce a PDF document size. Open your PDF file in Acrobat, click Tools > Optimize PDF. A toolbar with a few options will appear just above the PDF. Click Reduce File Size, and choose to reduce a single or multiple files.

How Do I Compress a .JPEG File ?

Use A Web App πŸ”— Navigate to compressor.io or squoosh.app and upload the image to compress it for free. Then downlad the compressed / optimized version of the image. Use FFMpeg on Terminal / CLI πŸ”— Open terminal in Mac OS or Any Linux distribution (Ubuntu, Elementary, ..) and use this command. ffmpeg -i input-image.jpeg -q:v 10 output-image.jpg -y make sure to replace input-image.jpeg with your image. And rename output-image.

Does a Zip File Reduce File Size?

In most cases packing or archiving with zip / arj / rar / 7zip / bzip / gzip reduces the space used by the file. Actual file size (after decompression) stays the same. But according to Pigeonhole principle there should be files when compressed you won’t get any space reduction. Photos represented in JPEG format and most video formats are also pretty well compressed to start with. However, making a zip (or other type of archiving) archive out of a number of files still has the virtue of giving you a single file to move your stuff.

Laravel Commands Cheatsheet

laravel new project-name πŸ”— create a new folder named “project-name” in the current directory. Then create all necessary Laravel project files inside it. composer require vendor/package πŸ”— update composer.json with the necessary details of the package you are choosing to install, then install the package in your project. composer update πŸ”— update the installed packages. composer dump-autoload πŸ”— updates your vendor/composer/autoload_classmap.php file. You have to run this command if you have a new class in your project that has not yet been loaded.

rsnapshot HOWTOs Docs

rsnapshot is a filesystem backup utility based on rsync . Using rsnapshot , it is possible to take snapshots of your filesystems at different points in time. Using hard links, rsnapshot creates the illusion of multiple full backups, while only taking up the space of one full backup plus differences. When coupled with ssh , it is possible to take snapshots of remote filesystems as well. rsnapshot is written in Perl , and depends on rsync .

How to Free up Disk Space on Mac OS ?

We all panic when we see the message your startup disk is almost full, or your disk is almost full. save space by optimizing storage. So let me tell you how to free up a good space in your mac, starting from obvious ways reaching to advanced methods to gain more storage space. Empty the trash can πŸ”— Empty the general trash manually. Then you can use this command to delete the trash of the current user.