R都是红色;都报错
TypedArray ta = context.obtainStyledAttributes(attrs,R.styleable.Topbar);
leftTextColor = ta.getColor(R.styleable.Topbar_leftTextColor,0);
leftTextBackground = ta.getDrawable(R.styleable.Topbar_leftTextBackground);
leftText = ta.getString(R.styleable.Topbar_leftText);
rightTextColor = ta.getColor(R.styleable.Topbar_rightTextColor, 0);
rightTextBackground = ta.getDrawable(R.styleable.Topbar_rightTextBackground);
rightText = ta.getString(R.styleable.Topbar_rightText);
titleText = ta.getString(R.styleable.Topbar_title);
titleTextColor = ta.getColor(R.styleable.Topbar_titleTxtColor, 0);
titleTextSize = ta.getDimension(R.styleable.Topbar_titleTextSize, 0);
为什么所有的R都是红色;都报错