在我的android studio的图形布局中,我看到了图像按钮上的图像,但是当我在模拟器上运行我的应用程序时,imagebutton上的图像没有得到displayed.I'm安装的什么我看到在我的Android工作室,什么时候我在模拟器上运行我的应用程序,我得到的截图。 来自ImageButton的图像没有在Android Studio的模拟器上显示

我还附上我的XML布局文件

xmlns:app="http://schemas.android.com/apk/res-auto"

xmlns:tools="http://schemas.android.com/tools"

android:id="@+id/activity_calc"

android:layout_width="match_parent"

android:layout_height="match_parent"

tools:context="com.example.sameer.coolcalc.CalcActivity"

tools:background="@android:color/background_light">

android:orientation="vertical"

android:layout_height="match_parent"

android:weightSum="6"

android:layout_width="wrap_content">

android:orientation="vertical"

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:layout_weight="2"

android:background="@android:color/holo_blue_bright"

android:weightSum="1">

android:layout_width="match_parent"

android:layout_height="match_parent"

android:inputType="numberDecimal"

android:ems="10"

android:id="@+id/editText4"

android:text="567"

android:textSize="60sp"

android:gravity="center_vertical|end" />

android:orientation="horizontal"

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:layout_weight="1"

android:weightSum="4">

android:text="7"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button14"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:text="8"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button13"

android:layout_weight="1"

android:textSize="36sp"

android:textColor="@android:color/black"

android:background="@android:color/background_light" />

android:text="9"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button12"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:layout_height="match_parent"

app:srcCompat="@drawable/divide"

android:id="@+id/imageButton6"

android:layout_weight="1"

android:layout_width="match_parent"

android:background="@android:color/background_light" />

android:orientation="horizontal"

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:layout_weight="1">

android:text="4"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button3"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:text="5"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button2"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:text="6"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:layout_width="match_parent"

android:layout_height="match_parent"

app:srcCompat="@drawable/multiply"

android:id="@+id/imageButton"

android:layout_weight="1"

android:background="@android:color/background_light" />

android:orientation="horizontal"

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:layout_weight="1"

android:weightSum="4">

android:text="1"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button6"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:text="2"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button5"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:text="3"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:id="@+id/button4"

android:layout_weight="1"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:layout_width="match_parent"

android:layout_height="match_parent"

app:srcCompat="@drawable/subtract"

android:id="@+id/imageButton3"

android:layout_weight="1"

android:background="@android:color/background_light" />

android:orientation="horizontal"

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:layout_weight="1">

android:orientation="horizontal"

android:layout_height="match_parent"

android:background="@android:color/background_light"

android:layout_width="205dp"

android:gravity="center">

android:text="clear"

android:id="@+id/button15"

android:background="@android:color/holo_blue_bright"

android:layout_width="170dp"

android:layout_height="50dp"

android:textSize="30sp" />

android:text="0"

android:layout_height="match_parent"

android:id="@+id/button11"

android:layout_width="103dp"

android:background="@android:color/background_light"

android:textColor="@android:color/black"

android:textSize="36sp" />

android:layout_width="103dp"

android:layout_height="match_parent"

app:srcCompat="@drawable/add"

android:id="@+id/imageButton5"

android:background="@android:color/background_light" />

android:layout_width="wrap_content"

android:layout_height="wrap_content"

app:srcCompat="@drawable/equal"

android:id="@+id/imageButton7"

android:background="@android:color/transparent"

android:layout_alignParentEnd="true"

android:layout_marginTop="140dp" />

+0

使用Android:SRC,而不是应用程序:srcCompat –

+0

@AgustinSivoplás是啊,是工作,但我没有得到机器人之间的区别:src和应用程序:你srcCompat.Can plzz解释一下吗? –

android imagebutton 动画,来自ImageButton的图像没有在Android Studio的模拟器上显示相关推荐

  1. android开机动画和图片在那个目录下,Android开机动画bootanimation.zip是怎么制作和使用的?...

    很多玩安卓手机的朋友都喜欢对自己的手机进行个性化的美化,下下主题,换换开机动画什么的,可是网上下载的开机动画千篇一律没有什么个性,是不是很想自己制作一个属于你的独一无二的开机动画呢? 制作安卓开通动画 ...

  2. Android 开机动画启动、播放、退出流程(android 10)

    Android 开机动画启动流程 (android 10) 1 开机动画启动流程 我们先来看一下开机动画是如何启动,并开始播放的. 通过系统启动流程分析可以得知,在系统内核启动后,会启动第一个init ...

  3. android 开机动画 渐变,[Parallax Animation]实现知乎 Android 客户端启动页视差滚动效果...

    前言 Parallax Scrolling (视差滚动),是一种常见的动画效果.视差一词来源于天文学,但在日常生活中也有它的身影.在疾驰的动车上看风景时,会发现越是离得近的,相对运动速度越快,而远处的 ...

  4. android属性动画 呼吸,【MIUI动效】Android:会呼吸的悬浮气泡

    原标题:[MIUI动效]Android:会呼吸的悬浮气泡 写在前面 这个标题看起来玄乎玄乎的,其实一张图就明白了: 悬浮气泡演示图 最早看到这个效果是 MIUI6系统升级界面,有很多五颜六色的气泡悬浮 ...

  5. android涟漪动画,如何添加涟漪效果并在android中的按钮上有自定义背景?

    请告诉我如何实现这两个目标,我已经解决了很多已经存在的问题,但他们并没有专门处理我的问题. 我想在我的按钮上产生涟漪效果,并且它应该是圆形的并且具有背景颜色.此外,我应该能够控制涟漪效果的颜色. 我尝 ...

  6. Android 【信号格的客制化】Part 3:手机上显示的信号强度dbm值不正确

    前言          欢迎大家我分享和推荐好用的代码段~~ 声明          欢迎转载,但请保留文章原始出处:          CSDN:http://www.csdn.net        ...

  7. android 刷机动画,Android开机动画修改方法

    该楼层疑似违规已被系统折叠 隐藏此楼查看此楼 Android开机动画有两种修改方法,android 2.0及之后,使用bootanimation程序显示开机画面,如需修改开机画面,不用修改代码,只需按 ...

  8. android 动画设计,Android loading动画设计分析

    Android loading动画设计分析 时间:2017-04-20     来源:Android开发学习网 android6.0上有了很炫酷的开机动画,实现原理是什么呢?今天我们就从Loading ...

  9. android scaleanimation 动画方向,Animation 动画详解(一)——alpha、scale、translate、rotate、set的xml属性及用法...

    一.概述 Android的animation由四种类型组成:alpha.scale.translate.rotate,对应android官方文档地址:<Animation Resources&g ...

  10. android rotate 动画,Android 动画使用 scale、alpha、translate、rotate、set

    scale:尺寸伸缩动画 alpha:渐变透明动画 translate:位移动画 rotate:旋转动画 调用动画文件 给View执行动画 动画文件可以存放在res下的anim目录 Android S ...

最新文章

  1. 7-19 支票面额 (C语言)
  2. 探索Android中的Parcel机制(上) .
  3. 三菱plc 与 计算机 通讯,PC与三菱PLC之间的RS232通讯协议
  4. 接口返回的类型是html页面_1.10 PhalApi 2.x 接口文档
  5. RHEL6入门系列之二十六,利用rpm进行软件包管理
  6. 数行代码训练视频模型,PyTorch视频理解利器出炉
  7. OpenGL学习(二)第一个OpenGL程序,绘制三角形
  8. 程序员必备网页前端设计网站
  9. 音频知识之OGG格式分析
  10. python是一门胶水语言_Python是唯一被称为“胶水语言”的编程语言?事实并非如此!...
  11. win10电脑怎么将html网页做成壁纸,手把手教你win10动态桌面怎么设置
  12. Nature communications
  13. 家谱编修制作软件修十大优势
  14. 你应该知道的八款国产操作系统
  15. 详解!适合女生做的互联网项目
  16. html动态工艺流程,化工工艺动态流程图制作软件
  17. Git 常用提交操作步骤
  18. 宇视阿宇摄像机夜间效果好吗?画面可以看清楚吗?
  19. 自定义串口通信协议,如何实现?
  20. datastage dsjob命令

热门文章

  1. jsp购物车和mysql_用jsp和数据库做的购物车的源程序
  2. Nsight Visual Studio 调试
  3. 【数据库】sql2008卸载和默认实例的删除
  4. TS封装格式介绍及解析
  5. 【南卡樱桃|读书笔记《学习高手》】
  6. 深夜不睡的我爬取一下美女照片!!!哈哈!!来吧,刺激磁刺激!!!
  7. 大一c语言程序考试常考程序题,C语言程序常考题
  8. Latex英文论文模板汇总(elsevier、arXiv、IEEE Access)
  9. ITIL 4知识系列之ITIL4的设计框架解析
  10. webpack-开发服务器-配置