I've recently moved from Eclipse to Android Studio, and it looks great. However, I can't seem to find how to display variables in debugging mode as hexadecimal values instead of decimal values. Any help would be appreciated. Thanks
Asked
Active
Viewed 1.7k times
20
-
[Xcode version](http://stackoverflow.com/q/35238651/3681880) of this question. – Suragch Feb 06 '16 at 07:56
2 Answers
19
I was wondering the same thing, especially how to do this by default as @adnako asked. I finally found an answer so I will post here, too.
Manually change a single value
Right click > View as... > Hex
Display all values as hex by default
Right click > Custimize Data Views... > Show hex values for primitives > Apply
(Note: these images are from Android Studio 1.2)
-
2In AS 1.4 (and 2.0) the "customize data views" option is not visible for me when inspecting a variable. There is however a global setting under "Build, Execution, Deployment -> Debugger -> Data Views -> Java -> Show hex value for primitives". Easiest is to just open settings and type "hex" in the search box. – JHH Oct 07 '16 at 07:12
-
4
In the debug window, right click on the value you would like to view in hex and choose View as -> Hex
. This can be done in the Variables
or Watches
views.

free3dom
- 18,729
- 7
- 52
- 51
-
so in eclipse if we hover over a variable name it shows a tooltip sort of a thing with the value in it. Is there anything in android studio similar to this? Rather than adding all the variables to watches. – CodeShadow Jan 10 '15 at 11:40
-
1If you hold down Ctrl (on windows) while hovering over a variable it shows you the current value. You can even do this when not debugging and it will show you the initialization value of the variable. – free3dom Jan 11 '15 at 07:16
-
2
-
@adnako I don't know if you can, have never seen any setting to that effect. – free3dom Jan 12 '15 at 21:24
-
-
1