Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Some thoughts on doing breakpoints persistent

<< < (2/9) > >>

MortenMacFly:

--- Quote from: jens on June 16, 2009, 01:01:52 pm ---That's the same for the layout-file we have at the moment and should probably be changed in a similar way we might do for watches/bp's.

--- End quote ---
Why? I don't put the layout files under version control because that's *my* setup. So if the BP's are also in some kind of layout file it'd be OK... or not?!

killerbot:
yes, breakpoints should not be in cbp, put in a file which should not be version controlled.

ollydbg:
In the browsetracker plugin, all the "browse_Marks" will be recorded in a your_project_name.bmarks file.

It is a XML file format. For example:


--- Code: ---<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<BrowseTracker_layout_file>
<ActiveTarget name="Debug" />
<File name="LearnWX1App.cpp" open="1" top="0" tabpos="4">
<Cursor position="646" topLine="0" />
<BrowseMarks positions="472,646" />
<Book_Marks positions="" />
</File>
<File name="LearnWX1Main.cpp" open="1" top="0" tabpos="1">
<Cursor position="3467" topLine="67" />
<BrowseMarks positions="1728,2413,3467" />
<Book_Marks positions="" />
</File>
<File name="LearnWX1Main.h" open="1" top="0" tabpos="2">
<Cursor position="1476" topLine="24" />
</File>
<File name="resource.rc" open="0" top="0" tabpos="0">
<Cursor position="48" topLine="0" />
</File>
<File name="wx_pch.h" open="1" top="0" tabpos="3">
<Cursor position="396" topLine="0" />
</File>
</BrowseTracker_layout_file>

--- End code ---

Every files will be recorded, including the "tab position", the Cursor position, the "BrowseMarks positions".

Seems we can just add another entry like below

--- Code: ---<File name="LearnWX1App.cpp" open="1" top="0" tabpos="4">
<Cursor position="646" topLine="0" />
<BrowseMarks positions="472,646" />
<Book_Marks positions="" />
                <Break_Points positions= "XXXXXX, XXXXXX, XXXXXX"
</File>

--- End code ---

Edit: This will be mess up  :(, debuggerGDB plugin should have its own layout file like

your_project_name.bps


 :D

oBFusCATed:
Having 100 files in the project's directory is bad and ugly.

There should be only one file looking like:


--- Code: ---<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<cb_project_setting>
       <layout> ala bala </layout>
       <debugger_plugin> ala bala </debugger_plugin>
       <browse_tracker_plugin> </browse_tracker_plugin>
       .
       .
</cb_project_setting>

--- End code ---

And there should be an easy way to get your data:

--- Code: ---CProjData *data = some_manager->GetProjectSettings()->GetData("layout");

do something with the data....

 some_manager->GetProjectSettings()->SetData("layout", data);

--- End code ---

p.s. by the way, I don't know what is the API for dealing with xml inside C::B :)

ollydbg:
It use tinyXML related functions.

See: Source/Base/tinyXML/*.cpp

your_project_name.cbp
your_project_name.layout
your_project_name.bmarks

all the above files have the same XML format. :D

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version