css rgba透明_rgba()函数以及CSS中的示例

css rgba透明

Introduction:

介绍:

Functions are used regularly while we are developing a web page or website. Therefore, to be a good developer you need to master as many functions as you can. This way your coding knowledge will increase as well and you will not have to bother to write long codes. Using functions optimizes your codes as that long coding is replaced by abstract functions. So, whenever you are free just go through some functions which you have not heard about and start learning them and implement them in your code. This article is not any different, this article also focuses on one such function that would prove to be very useful for you in your web development. So, without much adieu let us take this discussion forward.

我们在开发网页或网站时会定期使用功能。 因此,要成为一名优秀的开发人员,您需要掌握尽可能多的功能。 这样,您的编码知识也将增加,并且您不必费心编写长代码。 使用函数可以优化代码,因为长编码已被抽象函数取代。 因此,每当有空时,只需浏览一些您从未听说过的功能,然后开始学习它们并在代码中实现它们。 本文没有什么不同,本文还重点介绍了一种对您的Web开发非常有用的功能。 因此,让我们继续进行讨论。

Definition:

定义:

rgba() function is a very popular function, you will see this function in almost every web page or website. It seems like an important function too right? Indeed it is, let us understand this function with the help of its definition and syntax.

rgba()函数是一个非常流行的函数,几乎在每个网页或网站上都会看到此函数。 似乎重要功能太正确了吗? 的确如此,让我们借助其定义和语法来了解此功能。

rgba() function is a very easy-to-understand function and it is used almost regularly, so what does it actually do? Keep reading for the answer.
RGBA stands for Red, Blue, Green and Alpha. These four values together make up the rgba() function. You must be familiar with red, blue and green colors but what does alpha do? Well, alpha is used for transparency or opacity. If you set the value of alpha to 0, then your element would be transparent and if you set it to 1, then it would be nothing but opaque. Well, that is all for the rgba() function. So, let us move forward and have a look at the syntax of this function,

rgba()函数是一个非常易于理解的函数,几乎经常使用,所以它实际上是做什么的? 继续阅读答案。
RGBA代表红色,蓝色,绿色和Alpha 。 这四个值共同构成了rgba()函数 。 您必须熟悉红色,蓝色和绿色,但是alpha的作用是什么? 好吧,alpha用于透明度或不透明度。 如果将alpha的值设置为0,则元素将是透明的;如果将其设置为1,则元素将是不透明的。 好了,这就是rgba()函数的全部 。 因此,让我们继续前进,看看该函数的语法,

Syntax:

句法:

    element{
color:rgba(red,blue,green,alpha);
}

Example:

例:

<!DOCTYPE html>
<html>
<head>
<style>
p {
background-color: rgba(24, 253, 0, 1);
font-size: 50px;
color: rgba(234, 0, 0, 1);
}
</style>
</head>
<body>
<p>My name is Anjali Singh.</p>
</body>
</html>

Output

输出量

CSS | rgba() function

In the above example, both the font and the background color are set through the rgba() function.

在上面的示例中,字体和背景色都是通过rgba()函数设置的

You would be amazed by this function when you put it to use. This function will present to you about thousands of colors and with different shades for you to use. By making use of these colors you can make your website or web page attractive and stylish. So, don't miss the chance to play around with this function and explore as many colors as you can.

当您使用此功能时,您会感到惊讶。 此功能将为您呈现大约数千种颜色和不同阴影以供您使用。 通过使用这些颜色,可以使您的网站或网页更具吸引力和时尚感。 因此,不要错过尝试使用此功能并探索尽可能多的颜色的机会。

Conclusion:

结论:

To make the right use of this function, first select a theme for your website or web page, whether you want your website or web page to be dark or bluish or reddish. Once you have decided that then you are all set to select colors for your elements that go with the overall theme of your web page or website.

要正确使用此功能,请先为您的网站或网页选择一个主题,无论您希望网站或网页是深色还是蓝色或红色。 一旦确定,就可以为网页或网站的整体主题选择元素的颜色。

翻译自: https://www.includehelp.com/code-snippets/rgba-function-with-example-in-css.aspx

css rgba透明

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/378258.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

第十七章 扩展Python

第十七章 Python什么都能做&#xff0c;真的是这样。这门语言功能强大&#xff0c;但有时候速度有点慢。 鱼和熊掌兼得 本章讨论确实需要进一步提升速度的情形。在这种情况下&#xff0c;最佳的解决方案可能不是完全转向C语言&#xff08;或其他中低级语言&#xff09;&…

android studio资源二进制,无法自动检测ADB二进制文件 – Android Studio

我尝试在Android Studio上测试我的应用程序,但我遇到了困难"waiting for AVD to come online..."我读过Android设备监视器重置adb会做到这一点,它确实……对于1次测试,当我第二天重新启动电脑时,我不仅仅是&#xff1a;"waiting for AVD to come online..."…

犀牛脚本:仿迅雷的增强批量下载

迅雷的批量下载满好用。但是有两点我不太中意。在这个脚本里会有所增强 1、不能设置保存的文件名。2、不能单独设置这批下载的线程限制。 使用方法 // 下载从编号001到编号020的图片&#xff0c;保存名为猫咪写真*.jpg 使用6个线程 jdlp http://bizhi.zhuoku.com/bizhi/200804/…

为什么使用1 * 1 的卷积核

为什么使用 1* 1卷积核&#xff1f; 作用&#xff1a; 1、实现跨通道的交互和信息整合 2、 进行卷积核通道数的降维和升维 3、 在保持feature map尺度不变的&#xff08;即不损失分辨率&#xff09;的前提下大幅增加非线性特性 跨通道的交互和信息整合 使用1 * 1卷积核&a…

KingPaper初探ThinkPHP3.1.2之扩展函数库和类库的使用(四)

在我们做项目的时候TP的系统函数或系统类库满足不了我们的需要 所以有些东西需要我们自己去定义&#xff0c;在TP中我们怎么使用自己的函数库和类库呢&#xff1f;在TP系统中提供了三个系统函数库 common.php是全局必须加载的基础函数库&#xff0c;在任何时候都可以直接调用&a…

isfinite函数_isfinite()函数以及C ++中的示例

isfinite函数C isfinite()函数 (C isfinite() function) isfinite() function is a library function of cmath header, it is used to check whether the given value is a finite value or not? It accepts a value (float, double or long double) and returns 1 if the v…

android 服务端 漏洞,安卓漏洞 CVE 2017-13287 复现详解-

2018年4月&#xff0c;Android安全公告公布了CVE-2017-13287漏洞。与同期披露的其他漏洞一起&#xff0c;同属于框架中Parcelable对象的写入(序列化)与读出(反序列化)的不一致所造成的漏洞。在刚看到谷歌对于漏洞给出的补丁时一头雾水&#xff0c;在这里要感谢heeeeenMS509Team…

某公司面试题

一、基础题 1&#xff0c;冯诺依曼结构的计算机硬件逻辑组成中&#xff0c;不包含以下哪个模块&#xff1f; A&#xff0c;编译器 B&#xff0c;控制器 C&#xff0c;输入设备 D&#xff0c;输出设备 解释&#xff1a;冯诺依曼由五个模块组成&#xff1a;输入设备 输出设备 存…

GAP(全局平均池化层)操作

转载的文章链接&#xff1a; 为什么使用全局平均池化层&#xff1f; 关于 global average pooling https://blog.csdn.net/qq_23304241/article/details/80292859 在卷积神经网络的初期&#xff0c;卷积层通过池化层&#xff08;一般是 最大池化&#xff09;后总是要一个或n个全…

zoj1245 Triangles(DP)

/* 动态三角形&#xff1a;每次DP时考虑的是两个子三角形的高度即可 注意&#xff1a; 三角形可以是倒置的。 */ View Code 1 #include <iostream> 2 #include <cstdlib> 3 #include <cstring> 4 #include <stdio.h> 5 6 using namespace std; 7 8…

第十八章 程序打包

第十八章 程序打包 Setuptools和较旧的Distutils都是用于发布Python包的工具包&#xff0c;能够使用Python轻松地编写安装脚本。这些脚本可用于生成可发布的归档文档&#xff0c;供用户用来编译和安装编写库。 Setuptools并非只能用于创建基于脚本的Python安装程序&#xff0…

如何在Java中检查对象是否为空?

With the help of "" operator is useful for reference comparison and it compares two objects. 借助“ ”运算符&#xff0c;对于参考比较非常有用&#xff0c;它可以比较两个对象。 "" operator returns true if both references (objects) points to…

android编程从零开始,从零开始学习android开发

博主最近开通了Android栏目&#xff0c;现在正在从零开始学习android&#xff0c;遇到的所有值得分享的知识点以及遇到的问题将发布在这个博客的android栏目下。因为我有着深厚的java底子&#xff0c;所以学习起来得心应手&#xff0c;十分的简单&#xff0c;当然也只能算是入门…

CNN基本步骤以及经典卷积(LeNet、AlexNet、VGGNet、InceptionNet 和 ResNet)网络讲解以及tensorflow代码实现

课程来源&#xff1a;人工智能实践:Tensorflow笔记2 文章目录前言1、卷积神经网络的基本步骤1、卷积神经网络计算convolution2、感受野以及卷积核的选取3、全零填充Padding4、tf描述卷积层5、批标准化(BN操作)6、池化Pooling7、舍弃Dropout8、卷积神经网络搭建以及参数分析2、经…

String.valueOf()

1. 由 基本数据型态转换成 String String 类别中已经提供了将基本数据型态转换成 String 的 static 方法 也就是 String.valueOf() 这个参数多载的方法 有下列几种 String.valueOf(boolean b) : 将 boolean 变量 b 转换成字符串 String.valueOf(char c) : 将 char 变量 c 转换成…

emacs gdb 调试

写下linux下用emacs调用dgb调试的方法 emacs中使用gdb 说明C等价于ctrl M等价于alt 1,编写 .c函数 test.c 2&#xff0c;gcc一把 看看对不对 带上-g gcc -g -o test .debug test.c 如果要用gdb调试器&#xff0c;必须使用g选项。 3&#xff0c;#ema…

第十九章 趣味编程

第十九章 趣味编程 本章将介绍一些通用的Python编程指南。 为何要有趣 Python有趣的地方之一就是让用户的编程效率非常高效。 极限编程是一种软件开发方法 编程柔术 python的灵活性描述原型设计Python的优点之一是让你能够快速地编写程序。要更深入地了解面临的问题&#…

android按钮在容器下方,使用flex布局解决安卓手机上固定在底部的按钮,在键盘弹起后挡住input输入框的问题...

移动端经常会出现&#xff0c;一个表单里面&#xff0c;确定按钮固定在底部这样的布局&#xff0c;一般会让按钮absolute或者fixed&#xff0c;这样在ios上没有问题&#xff0c;但是在安卓手机上&#xff0c;当表单里面的input输入框获得焦点的时候&#xff0c;按钮会挡在表单上…

dbms支持哪几种数据模型_DBMS中不同类型的数据模型

dbms支持哪几种数据模型资料模型 (Data Model) A data model is a model that defines in which format the data are represented and accessed. Data model mainly defines some of the data elements and relationships that exist between them. 数据模型是定义数据以哪种格…

JS 数组迭代方法

var arr [3,4,5,6,7,"a"]; var isNum function(elem,index,AAA){ return !isNaN(elem);} var toUpperCase function(elem){ return String.prototype.toUpperCase.apply(elem);} var print function(elem,index){ console.log(index"."elem);} /*对数组…